loudspeaker.go 309 B

123456789101112131415161718192021222324
  1. package lc
  2. import (
  3. "fmt"
  4. )
  5. // Loudspeaker 扬声器接口
  6. type Loudspeaker interface {
  7. Speak()
  8. }
  9. type IpCast struct {
  10. }
  11. func NewIpCast() *IpCast {
  12. return &IpCast{}
  13. }
  14. func (ip IpCast) Speak() {
  15. fmt.Println("来车了来车了!")
  16. }
  17. //func (ip IpCast) CorrectTime() {}
  18. //func (ip IpCast)Reconnect(){}