Documentation ¶
Index ¶
- Variables
- func RegisterCarsServiceServer(s *grpc.Server, srv CarsServiceServer)
- type Car
- func (*Car) Descriptor() ([]byte, []int)deprecated
- func (x *Car) GetElevation() float64
- func (x *Car) GetHeight() float64
- func (x *Car) GetLength() float64
- func (x *Car) GetName() string
- func (x *Car) GetSA() float64
- func (x *Car) GetWidth() float64
- func (*Car) ProtoMessage()
- func (x *Car) ProtoReflect() protoreflect.Message
- func (x *Car) Reset()
- func (x *Car) String() string
- type CarListRequest
- type CarRequest
- type CarResponse
- type CarsListResponse
- type CarsServiceClient
- type CarsServiceServer
- type CarsService_GetCarsListClient
- type CarsService_GetCarsListServer
- type ServerVersionRequest
- type ServerVersionResponse
- func (*ServerVersionResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ServerVersionResponse) GetTimestamp() string
- func (x *ServerVersionResponse) GetVersion() string
- func (*ServerVersionResponse) ProtoMessage()
- func (x *ServerVersionResponse) ProtoReflect() protoreflect.Message
- func (x *ServerVersionResponse) Reset()
- func (x *ServerVersionResponse) String() string
- type UnimplementedCarsServiceServer
- func (*UnimplementedCarsServiceServer) GetCar(context.Context, *CarRequest) (*CarResponse, error)
- func (*UnimplementedCarsServiceServer) GetCarsList(*CarListRequest, CarsService_GetCarsListServer) error
- func (*UnimplementedCarsServiceServer) GetServerVersion(context.Context, *ServerVersionRequest) (*ServerVersionResponse, error)
Constants ¶
This section is empty.
Variables ¶
var File_proto_cars_proto protoreflect.FileDescriptor
Functions ¶
func RegisterCarsServiceServer ¶
func RegisterCarsServiceServer(s *grpc.Server, srv CarsServiceServer)
Types ¶
type Car ¶
type Car struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Length float64 `protobuf:"fixed64,2,opt,name=length,proto3" json:"length,omitempty"` Width float64 `protobuf:"fixed64,3,opt,name=width,proto3" json:"width,omitempty"` Height float64 `protobuf:"fixed64,4,opt,name=height,proto3" json:"height,omitempty"` SA float64 `protobuf:"fixed64,5,opt,name=SA,proto3" json:"SA,omitempty"` Elevation float64 `protobuf:"fixed64,6,opt,name=elevation,proto3" json:"elevation,omitempty"` // contains filtered or unexported fields }
func (*Car) Descriptor
deprecated
func (*Car) GetElevation ¶
func (*Car) ProtoMessage ¶
func (*Car) ProtoMessage()
func (*Car) ProtoReflect ¶
func (x *Car) ProtoReflect() protoreflect.Message
type CarListRequest ¶
type CarListRequest struct {
// contains filtered or unexported fields
}
func (*CarListRequest) Descriptor
deprecated
func (*CarListRequest) Descriptor() ([]byte, []int)
Deprecated: Use CarListRequest.ProtoReflect.Descriptor instead.
func (*CarListRequest) ProtoMessage ¶
func (*CarListRequest) ProtoMessage()
func (*CarListRequest) ProtoReflect ¶
func (x *CarListRequest) ProtoReflect() protoreflect.Message
func (*CarListRequest) Reset ¶
func (x *CarListRequest) Reset()
func (*CarListRequest) String ¶
func (x *CarListRequest) String() string
type CarRequest ¶
type CarRequest struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
func (*CarRequest) Descriptor
deprecated
func (*CarRequest) Descriptor() ([]byte, []int)
Deprecated: Use CarRequest.ProtoReflect.Descriptor instead.
func (*CarRequest) GetName ¶
func (x *CarRequest) GetName() string
func (*CarRequest) ProtoMessage ¶
func (*CarRequest) ProtoMessage()
func (*CarRequest) ProtoReflect ¶
func (x *CarRequest) ProtoReflect() protoreflect.Message
func (*CarRequest) Reset ¶
func (x *CarRequest) Reset()
func (*CarRequest) String ¶
func (x *CarRequest) String() string
type CarResponse ¶
type CarResponse struct { Car *Car `protobuf:"bytes,1,opt,name=car,proto3" json:"car,omitempty"` // contains filtered or unexported fields }
func (*CarResponse) Descriptor
deprecated
func (*CarResponse) Descriptor() ([]byte, []int)
Deprecated: Use CarResponse.ProtoReflect.Descriptor instead.
func (*CarResponse) GetCar ¶
func (x *CarResponse) GetCar() *Car
func (*CarResponse) ProtoMessage ¶
func (*CarResponse) ProtoMessage()
func (*CarResponse) ProtoReflect ¶
func (x *CarResponse) ProtoReflect() protoreflect.Message
func (*CarResponse) Reset ¶
func (x *CarResponse) Reset()
func (*CarResponse) String ¶
func (x *CarResponse) String() string
type CarsListResponse ¶
type CarsListResponse struct { Cars *Car `protobuf:"bytes,1,opt,name=cars,proto3" json:"cars,omitempty"` // contains filtered or unexported fields }
func (*CarsListResponse) Descriptor
deprecated
func (*CarsListResponse) Descriptor() ([]byte, []int)
Deprecated: Use CarsListResponse.ProtoReflect.Descriptor instead.
func (*CarsListResponse) GetCars ¶
func (x *CarsListResponse) GetCars() *Car
func (*CarsListResponse) ProtoMessage ¶
func (*CarsListResponse) ProtoMessage()
func (*CarsListResponse) ProtoReflect ¶
func (x *CarsListResponse) ProtoReflect() protoreflect.Message
func (*CarsListResponse) Reset ¶
func (x *CarsListResponse) Reset()
func (*CarsListResponse) String ¶
func (x *CarsListResponse) String() string
type CarsServiceClient ¶
type CarsServiceClient interface { GetCar(ctx context.Context, in *CarRequest, opts ...grpc.CallOption) (*CarResponse, error) GetCarsList(ctx context.Context, in *CarListRequest, opts ...grpc.CallOption) (CarsService_GetCarsListClient, error) GetServerVersion(ctx context.Context, in *ServerVersionRequest, opts ...grpc.CallOption) (*ServerVersionResponse, error) }
CarsServiceClient is the client API for CarsService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewCarsServiceClient ¶
func NewCarsServiceClient(cc grpc.ClientConnInterface) CarsServiceClient
type CarsServiceServer ¶
type CarsServiceServer interface { GetCar(context.Context, *CarRequest) (*CarResponse, error) GetCarsList(*CarListRequest, CarsService_GetCarsListServer) error GetServerVersion(context.Context, *ServerVersionRequest) (*ServerVersionResponse, error) }
CarsServiceServer is the server API for CarsService service.
type CarsService_GetCarsListClient ¶
type CarsService_GetCarsListClient interface { Recv() (*CarsListResponse, error) grpc.ClientStream }
type CarsService_GetCarsListServer ¶
type CarsService_GetCarsListServer interface { Send(*CarsListResponse) error grpc.ServerStream }
type ServerVersionRequest ¶
type ServerVersionRequest struct {
// contains filtered or unexported fields
}
func (*ServerVersionRequest) Descriptor
deprecated
func (*ServerVersionRequest) Descriptor() ([]byte, []int)
Deprecated: Use ServerVersionRequest.ProtoReflect.Descriptor instead.
func (*ServerVersionRequest) ProtoMessage ¶
func (*ServerVersionRequest) ProtoMessage()
func (*ServerVersionRequest) ProtoReflect ¶
func (x *ServerVersionRequest) ProtoReflect() protoreflect.Message
func (*ServerVersionRequest) Reset ¶
func (x *ServerVersionRequest) Reset()
func (*ServerVersionRequest) String ¶
func (x *ServerVersionRequest) String() string
type ServerVersionResponse ¶
type ServerVersionResponse struct { Timestamp string `protobuf:"bytes,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` Version string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"` // contains filtered or unexported fields }
func (*ServerVersionResponse) Descriptor
deprecated
func (*ServerVersionResponse) Descriptor() ([]byte, []int)
Deprecated: Use ServerVersionResponse.ProtoReflect.Descriptor instead.
func (*ServerVersionResponse) GetTimestamp ¶
func (x *ServerVersionResponse) GetTimestamp() string
func (*ServerVersionResponse) GetVersion ¶
func (x *ServerVersionResponse) GetVersion() string
func (*ServerVersionResponse) ProtoMessage ¶
func (*ServerVersionResponse) ProtoMessage()
func (*ServerVersionResponse) ProtoReflect ¶
func (x *ServerVersionResponse) ProtoReflect() protoreflect.Message
func (*ServerVersionResponse) Reset ¶
func (x *ServerVersionResponse) Reset()
func (*ServerVersionResponse) String ¶
func (x *ServerVersionResponse) String() string
type UnimplementedCarsServiceServer ¶
type UnimplementedCarsServiceServer struct { }
UnimplementedCarsServiceServer can be embedded to have forward compatible implementations.
func (*UnimplementedCarsServiceServer) GetCar ¶
func (*UnimplementedCarsServiceServer) GetCar(context.Context, *CarRequest) (*CarResponse, error)
func (*UnimplementedCarsServiceServer) GetCarsList ¶
func (*UnimplementedCarsServiceServer) GetCarsList(*CarListRequest, CarsService_GetCarsListServer) error
func (*UnimplementedCarsServiceServer) GetServerVersion ¶
func (*UnimplementedCarsServiceServer) GetServerVersion(context.Context, *ServerVersionRequest) (*ServerVersionResponse, error)