Documentation ¶
Overview ¶
Package doorservice is a generated protocol buffer package.
It is generated from these files:
proto/doorservice.proto
It has these top-level messages:
UpdateStateRequest UpdateStateResponse AccessStreamRequest AccessStreamResponse
Index ¶
- Variables
- func RegisterDoorServiceServer(s *grpc.Server, srv DoorServiceServer)
- type AccessStreamRequest
- type AccessStreamResponse
- type DoorServiceClient
- type DoorServiceServer
- type DoorService_AccessStreamClient
- type DoorService_AccessStreamServer
- type DoorState
- type UpdateStateRequest
- type UpdateStateResponse
Constants ¶
This section is empty.
Variables ¶
View Source
var DoorState_name = map[int32]string{
0: "OPEN",
1: "CLOSE",
}
View Source
var DoorState_value = map[string]int32{
"OPEN": 0,
"CLOSE": 1,
}
Functions ¶
func RegisterDoorServiceServer ¶
func RegisterDoorServiceServer(s *grpc.Server, srv DoorServiceServer)
Types ¶
type AccessStreamRequest ¶
type AccessStreamRequest struct {
Serial int64 `protobuf:"varint,1,opt,name=serial" json:"serial,omitempty"`
}
func (*AccessStreamRequest) Descriptor ¶
func (*AccessStreamRequest) Descriptor() ([]byte, []int)
func (*AccessStreamRequest) ProtoMessage ¶
func (*AccessStreamRequest) ProtoMessage()
func (*AccessStreamRequest) Reset ¶
func (m *AccessStreamRequest) Reset()
func (*AccessStreamRequest) String ¶
func (m *AccessStreamRequest) String() string
type AccessStreamResponse ¶
type AccessStreamResponse struct {
OpenDoor bool `protobuf:"varint,1,opt,name=OpenDoor" json:"OpenDoor,omitempty"`
}
func (*AccessStreamResponse) Descriptor ¶
func (*AccessStreamResponse) Descriptor() ([]byte, []int)
func (*AccessStreamResponse) ProtoMessage ¶
func (*AccessStreamResponse) ProtoMessage()
func (*AccessStreamResponse) Reset ¶
func (m *AccessStreamResponse) Reset()
func (*AccessStreamResponse) String ¶
func (m *AccessStreamResponse) String() string
type DoorServiceClient ¶
type DoorServiceClient interface { UpdateState(ctx context.Context, in *UpdateStateRequest, opts ...grpc.CallOption) (*UpdateStateResponse, error) AccessStream(ctx context.Context, in *AccessStreamRequest, opts ...grpc.CallOption) (DoorService_AccessStreamClient, error) }
func NewDoorServiceClient ¶
func NewDoorServiceClient(cc *grpc.ClientConn) DoorServiceClient
type DoorServiceServer ¶
type DoorServiceServer interface { UpdateState(context.Context, *UpdateStateRequest) (*UpdateStateResponse, error) AccessStream(*AccessStreamRequest, DoorService_AccessStreamServer) error }
type DoorService_AccessStreamClient ¶
type DoorService_AccessStreamClient interface { Recv() (*AccessStreamResponse, error) grpc.ClientStream }
type DoorService_AccessStreamServer ¶
type DoorService_AccessStreamServer interface { Send(*AccessStreamResponse) error grpc.ServerStream }
type UpdateStateRequest ¶
type UpdateStateRequest struct { State DoorState `protobuf:"varint,1,opt,name=state,enum=doorservice.DoorState" json:"state,omitempty"` Serial int64 `protobuf:"varint,2,opt,name=serial" json:"serial,omitempty"` }
func (*UpdateStateRequest) Descriptor ¶
func (*UpdateStateRequest) Descriptor() ([]byte, []int)
func (*UpdateStateRequest) ProtoMessage ¶
func (*UpdateStateRequest) ProtoMessage()
func (*UpdateStateRequest) Reset ¶
func (m *UpdateStateRequest) Reset()
func (*UpdateStateRequest) String ¶
func (m *UpdateStateRequest) String() string
type UpdateStateResponse ¶
type UpdateStateResponse struct { }
func (*UpdateStateResponse) Descriptor ¶
func (*UpdateStateResponse) Descriptor() ([]byte, []int)
func (*UpdateStateResponse) ProtoMessage ¶
func (*UpdateStateResponse) ProtoMessage()
func (*UpdateStateResponse) Reset ¶
func (m *UpdateStateResponse) Reset()
func (*UpdateStateResponse) String ¶
func (m *UpdateStateResponse) String() string
Click to show internal directories.
Click to hide internal directories.