Documentation
¶
Index ¶
- type Duration
- type Event
- type ServiceRecord
- func (this *ServiceRecord) AppendIP4(rr *dns.A)
- func (this *ServiceRecord) AppendIP6(rr *dns.AAAA)
- func (this *ServiceRecord) Expired() bool
- func (this *ServiceRecord) Host() string
- func (this *ServiceRecord) IP4() []net.IP
- func (this *ServiceRecord) IP6() []net.IP
- func (this *ServiceRecord) Key() string
- func (this *ServiceRecord) Name() string
- func (this *ServiceRecord) Port() uint
- func (this *ServiceRecord) Service() string
- func (this *ServiceRecord) SetPTR(zone string, rr *dns.PTR)
- func (this *ServiceRecord) SetSRV(rr *dns.SRV)
- func (this *ServiceRecord) SetTXT(rr *dns.TXT)
- func (s *ServiceRecord) String() string
- func (this *ServiceRecord) TTL() time.Duration
- func (this *ServiceRecord) Text() []string
- func (this *ServiceRecord) Timestamp() time.Time
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Duration ¶ added in v1.0.5
Duration type to read and write JSON better
func (*Duration) MarshalJSON ¶ added in v1.0.5
func (*Duration) UnmarshalJSON ¶ added in v1.0.5
type Event ¶ added in v1.0.5
type Event struct {
// contains filtered or unexported fields
}
RPCEvent implementation
func NewEvent ¶ added in v1.0.5
func NewEvent(source gopi.Driver, type_ gopi.RPCEventType, service gopi.RPCServiceRecord) *Event
func (*Event) ServiceRecord ¶ added in v1.0.5
func (this *Event) ServiceRecord() gopi.RPCServiceRecord
Return the service record
func (*Event) Type ¶ added in v1.0.5
func (this *Event) Type() gopi.RPCEventType
Return the type of event
type ServiceRecord ¶
type ServiceRecord struct {
Key_ string `json:"key"`
Name_ string `json:"name"`
Host_ string `json:"host"`
Service_ string `json:"service"`
Port_ uint `json:"port"`
Txt_ []string `json:"txt"`
Ipv4_ []net.IP `json:"ipv4"`
Ipv6_ []net.IP `json:"ipv6"`
Ts_ time.Time `json:"ts"`
Ttl_ *Duration `json:"ttl"`
}
RPCServiceRecord implementation
func NewServiceRecord ¶ added in v1.0.5
func NewServiceRecord() *ServiceRecord
func NewServiceRecordWithAddr ¶ added in v1.0.5
func NewServiceRecordWithAddr(name, addr string) *ServiceRecord
func (*ServiceRecord) AppendIP4 ¶ added in v1.0.5
func (this *ServiceRecord) AppendIP4(rr *dns.A)
func (*ServiceRecord) AppendIP6 ¶ added in v1.0.5
func (this *ServiceRecord) AppendIP6(rr *dns.AAAA)
func (*ServiceRecord) Expired ¶ added in v1.0.5
func (this *ServiceRecord) Expired() bool
func (*ServiceRecord) Host ¶ added in v1.0.5
func (this *ServiceRecord) Host() string
func (*ServiceRecord) IP4 ¶ added in v1.0.5
func (this *ServiceRecord) IP4() []net.IP
func (*ServiceRecord) IP6 ¶ added in v1.0.5
func (this *ServiceRecord) IP6() []net.IP
func (*ServiceRecord) Key ¶ added in v1.0.5
func (this *ServiceRecord) Key() string
func (*ServiceRecord) Name ¶
func (this *ServiceRecord) Name() string
func (*ServiceRecord) Port ¶
func (this *ServiceRecord) Port() uint
func (*ServiceRecord) Service ¶
func (this *ServiceRecord) Service() string
func (*ServiceRecord) SetPTR ¶ added in v1.0.5
func (this *ServiceRecord) SetPTR(zone string, rr *dns.PTR)
func (*ServiceRecord) SetSRV ¶ added in v1.0.5
func (this *ServiceRecord) SetSRV(rr *dns.SRV)
func (*ServiceRecord) SetTXT ¶ added in v1.0.5
func (this *ServiceRecord) SetTXT(rr *dns.TXT)
func (*ServiceRecord) String ¶
func (s *ServiceRecord) String() string
func (*ServiceRecord) TTL ¶
func (this *ServiceRecord) TTL() time.Duration
func (*ServiceRecord) Text ¶ added in v1.0.5
func (this *ServiceRecord) Text() []string
func (*ServiceRecord) Timestamp ¶
func (this *ServiceRecord) Timestamp() time.Time
Directories
¶
| Path | Synopsis |
|---|---|
|
cmd
|
|
|
dns-discovery
command
|
|
|
helloworld-client
command
An example RPC Client tool
|
An example RPC Client tool |
|
helloworld-service
command
An RPC Server tool, import the services as modules
|
An RPC Server tool, import the services as modules |
|
rpc
|
|
|
sys
|
|
Click to show internal directories.
Click to hide internal directories.