Documentation ¶
Overview ¶
Package service is a generated protocol buffer package.
It is generated from these files:
service/service.proto
It has these top-level messages:
Meta AllActions Targets SlotRange Slot Slots ErrorMessage
Index ¶
- Variables
- func GenerateHeaderBuf(length uint16, route uint8) []byte
- func ReadOne(r io.Reader) ([]byte, uint8, error)
- func Start(port uint16, dbFolder string)
- func WriteErrorMessage(err error, w io.Writer)
- type AllActions
- type AllActions_Act
- type ErrorMessage
- type Meta
- func (*Meta) Descriptor() ([]byte, []int)
- func (m *Meta) GetArch() string
- func (m *Meta) GetCreateAt() uint32
- func (m *Meta) GetHost() string
- func (m *Meta) GetOs() string
- func (m *Meta) GetTag() string
- func (m *Meta) GetUsername() string
- func (m *Meta) GetVersion() uint32
- func (m *Meta) GetZoneOffset() int32
- func (*Meta) ProtoMessage()
- func (m *Meta) Reset()
- func (m *Meta) String() string
- type RouteFunc
- type Slot
- type SlotRange
- type Slots
- type TCPServer
- type Targets
- type UDPServer
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrDataLength the data length wrong ErrDataLength = errors.New("read data length wrong") )
Functions ¶
func GenerateHeaderBuf ¶
GenerateHeaderBuf to generate a header buf
func WriteErrorMessage ¶
WriteErrorMessage to write a message to writer
Types ¶
type AllActions ¶
type AllActions struct {
Actions []*AllActions_Act `protobuf:"bytes,1,rep,name=actions" json:"actions,omitempty"`
}
func (*AllActions) Descriptor ¶
func (*AllActions) Descriptor() ([]byte, []int)
func (*AllActions) GetActions ¶
func (m *AllActions) GetActions() []*AllActions_Act
func (*AllActions) ProtoMessage ¶
func (*AllActions) ProtoMessage()
func (*AllActions) Reset ¶
func (m *AllActions) Reset()
func (*AllActions) String ¶
func (m *AllActions) String() string
type AllActions_Act ¶
type AllActions_Act struct { Target string `protobuf:"bytes,1,opt,name=target" json:"target,omitempty"` Start uint32 `protobuf:"varint,2,opt,name=start" json:"start,omitempty"` Last uint32 `protobuf:"varint,3,opt,name=last" json:"last,omitempty"` }
func (*AllActions_Act) Descriptor ¶
func (*AllActions_Act) Descriptor() ([]byte, []int)
func (*AllActions_Act) GetLast ¶
func (m *AllActions_Act) GetLast() uint32
func (*AllActions_Act) GetStart ¶
func (m *AllActions_Act) GetStart() uint32
func (*AllActions_Act) GetTarget ¶
func (m *AllActions_Act) GetTarget() string
func (*AllActions_Act) ProtoMessage ¶
func (*AllActions_Act) ProtoMessage()
func (*AllActions_Act) Reset ¶
func (m *AllActions_Act) Reset()
func (*AllActions_Act) String ¶
func (m *AllActions_Act) String() string
type ErrorMessage ¶
type ErrorMessage struct {
Message string `protobuf:"bytes,1,opt,name=message" json:"message,omitempty"`
}
func (*ErrorMessage) Descriptor ¶
func (*ErrorMessage) Descriptor() ([]byte, []int)
func (*ErrorMessage) GetMessage ¶
func (m *ErrorMessage) GetMessage() string
func (*ErrorMessage) ProtoMessage ¶
func (*ErrorMessage) ProtoMessage()
func (*ErrorMessage) Reset ¶
func (m *ErrorMessage) Reset()
func (*ErrorMessage) String ¶
func (m *ErrorMessage) String() string
type Meta ¶
type Meta struct { Version uint32 `protobuf:"varint,1,opt,name=version" json:"version,omitempty"` Tag string `protobuf:"bytes,2,opt,name=tag" json:"tag,omitempty"` CreateAt uint32 `protobuf:"varint,3,opt,name=create_at,json=createAt" json:"create_at,omitempty"` Host string `protobuf:"bytes,4,opt,name=host" json:"host,omitempty"` Username string `protobuf:"bytes,5,opt,name=username" json:"username,omitempty"` Arch string `protobuf:"bytes,6,opt,name=arch" json:"arch,omitempty"` Os string `protobuf:"bytes,7,opt,name=os" json:"os,omitempty"` ZoneOffset int32 `protobuf:"varint,8,opt,name=zone_offset,json=zoneOffset" json:"zone_offset,omitempty"` }
func (*Meta) Descriptor ¶
func (*Meta) GetCreateAt ¶
func (*Meta) GetUsername ¶
func (*Meta) GetVersion ¶
func (*Meta) GetZoneOffset ¶
func (*Meta) ProtoMessage ¶
func (*Meta) ProtoMessage()
type Slot ¶
type Slot struct { Start uint32 `protobuf:"varint,1,opt,name=start" json:"start,omitempty"` Slot uint32 `protobuf:"varint,2,opt,name=slot" json:"slot,omitempty"` }
func (*Slot) Descriptor ¶
func (*Slot) ProtoMessage ¶
func (*Slot) ProtoMessage()
type SlotRange ¶
type SlotRange struct { Target string `protobuf:"bytes,1,opt,name=target" json:"target,omitempty"` Start uint32 `protobuf:"varint,2,opt,name=start" json:"start,omitempty"` End uint32 `protobuf:"varint,3,opt,name=end" json:"end,omitempty"` }
func (*SlotRange) Descriptor ¶
func (*SlotRange) ProtoMessage ¶
func (*SlotRange) ProtoMessage()
type Slots ¶
type Slots struct {
Slots []*Slot `protobuf:"bytes,1,rep,name=slots" json:"slots,omitempty"`
}
func (*Slots) Descriptor ¶
func (*Slots) ProtoMessage ¶
func (*Slots) ProtoMessage()
type TCPServer ¶
type TCPServer struct {
// contains filtered or unexported fields
}
TCPServer to define a TCP server
func NewTCPServer ¶
NewTCPServer to create a TCP server instance
type Targets ¶
type Targets struct {
Target []string `protobuf:"bytes,1,rep,name=target" json:"target,omitempty"`
}
func (*Targets) Descriptor ¶
func (*Targets) ProtoMessage ¶
func (*Targets) ProtoMessage()
type UDPServer ¶
type UDPServer struct {
// contains filtered or unexported fields
}
UDPServer to define a UDP server
func NewUDPServer ¶
NewUDPServer to create a server instance
Click to show internal directories.
Click to hide internal directories.