Documentation ¶
Index ¶
- Constants
- type GRPCServer
- func (s *GRPCServer) GetInitialPeerList(connectingPeerID uint32) ([]*controllerv1.Peer, error)
- func (s *GRPCServer) LoginPeer(ctx context.Context, req *controllerv1.LoginRequest) (*controllerv1.LoginResponse, error)
- func (s *GRPCServer) Punch(ctx context.Context, req *controllerv1.PunchRequest) (*controllerv1.Empty, error)
- func (s *GRPCServer) RegisterPeer(ctx context.Context, req *controllerv1.RegisterRequest) (*controllerv1.RegisterResponse, error)
- func (s *GRPCServer) SetPeerEndpoint(ctx context.Context, endpoint *controllerv1.Endpoint) (*controllerv1.Empty, error)
- func (s *GRPCServer) Update(req *controllerv1.UpdateRequest, ...) error
Constants ¶
View Source
const (
TempRegisterKey = "registermeplz!"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GRPCServer ¶
type GRPCServer struct { controllerv1.UnimplementedControllerServiceServer // contains filtered or unexported fields }
func NewGRPCServer ¶
func NewGRPCServer(controller *controller.Controller) *GRPCServer
func (*GRPCServer) GetInitialPeerList ¶
func (s *GRPCServer) GetInitialPeerList(connectingPeerID uint32) ([]*controllerv1.Peer, error)
func (*GRPCServer) LoginPeer ¶
func (s *GRPCServer) LoginPeer( ctx context.Context, req *controllerv1.LoginRequest, ) (*controllerv1.LoginResponse, error)
func (*GRPCServer) Punch ¶
func (s *GRPCServer) Punch( ctx context.Context, req *controllerv1.PunchRequest, ) (*controllerv1.Empty, error)
func (*GRPCServer) RegisterPeer ¶
func (s *GRPCServer) RegisterPeer( ctx context.Context, req *controllerv1.RegisterRequest, ) (*controllerv1.RegisterResponse, error)
func (*GRPCServer) SetPeerEndpoint ¶
func (s *GRPCServer) SetPeerEndpoint( ctx context.Context, endpoint *controllerv1.Endpoint, ) (*controllerv1.Empty, error)
TODO Authentication/encryption for messages
func (*GRPCServer) Update ¶
func (s *GRPCServer) Update( req *controllerv1.UpdateRequest, stream controllerv1.ControllerService_UpdateServer, ) error
Click to show internal directories.
Click to hide internal directories.