server

package
v0.0.0-...-410a399 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 1, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

type Server struct {
	pb.UnimplementedServiceServer
	// contains filtered or unexported fields
}

Server is used to implement your Service.

func NewServer

func NewServer(name, version, environment string) (*Server, error)

func (*Server) GetCounter

func (s *Server) GetCounter() int64

func (*Server) GetEnvironment

func (s *Server) GetEnvironment() string

func (*Server) GetName

func (s *Server) GetName() string

func (*Server) GetVersion

func (s *Server) GetVersion() string

func (*Server) Scalar

func (s *Server) Scalar(_ context.Context, in *pb.Request) (*pb.Response, error)

Scalar implements the single method of the Service.

func (*Server) Start

func (s *Server) Start(ctx context.Context, address string) error

func (*Server) Stop

func (s *Server) Stop()

func (*Server) Stream

func (s *Server) Stream(stream pb.Service_StreamServer) error

Stream implements the Stream method of the Service.

func (*Server) String

func (s *Server) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL