Documentation
¶
Index ¶
- Variables
- func RegisterLocationsServer(s *grpc.Server, srv LocationsServer)
- func RegisterTempsServer(s *grpc.Server, srv TempsServer)
- type GetLocationsResponse
- func (*GetLocationsResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetLocationsResponse) GetLocations() []*Location
- func (*GetLocationsResponse) ProtoMessage()
- func (x *GetLocationsResponse) ProtoReflect() protoreflect.Message
- func (x *GetLocationsResponse) Reset()
- func (x *GetLocationsResponse) String() string
- type GetTempsRequest
- type GetTempsResponse
- type Location
- type LocationsClient
- type LocationsServer
- type Temp
- type TempsClient
- type TempsServer
- type UnimplementedLocationsServer
- type UnimplementedTempsServer
Constants ¶
This section is empty.
Variables ¶
var File_location_proto protoreflect.FileDescriptor
var File_temperature_proto protoreflect.FileDescriptor
Functions ¶
func RegisterLocationsServer ¶
func RegisterLocationsServer(s *grpc.Server, srv LocationsServer)
func RegisterTempsServer ¶
func RegisterTempsServer(s *grpc.Server, srv TempsServer)
Types ¶
type GetLocationsResponse ¶
type GetLocationsResponse struct {
Locations []*Location `protobuf:"bytes,1,rep,name=locations,proto3" json:"locations,omitempty"`
// contains filtered or unexported fields
}
func (*GetLocationsResponse) Descriptor
deprecated
func (*GetLocationsResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetLocationsResponse.ProtoReflect.Descriptor instead.
func (*GetLocationsResponse) GetLocations ¶
func (x *GetLocationsResponse) GetLocations() []*Location
func (*GetLocationsResponse) ProtoMessage ¶
func (*GetLocationsResponse) ProtoMessage()
func (*GetLocationsResponse) ProtoReflect ¶
func (x *GetLocationsResponse) ProtoReflect() protoreflect.Message
func (*GetLocationsResponse) Reset ¶
func (x *GetLocationsResponse) Reset()
func (*GetLocationsResponse) String ¶
func (x *GetLocationsResponse) String() string
type GetTempsRequest ¶
type GetTempsRequest struct {
LocationId int32 `protobuf:"varint,1,opt,name=location_id,json=locationId,proto3" json:"location_id,omitempty"`
// contains filtered or unexported fields
}
func (*GetTempsRequest) Descriptor
deprecated
func (*GetTempsRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetTempsRequest.ProtoReflect.Descriptor instead.
func (*GetTempsRequest) GetLocationId ¶
func (x *GetTempsRequest) GetLocationId() int32
func (*GetTempsRequest) ProtoMessage ¶
func (*GetTempsRequest) ProtoMessage()
func (*GetTempsRequest) ProtoReflect ¶
func (x *GetTempsRequest) ProtoReflect() protoreflect.Message
func (*GetTempsRequest) Reset ¶
func (x *GetTempsRequest) Reset()
func (*GetTempsRequest) String ¶
func (x *GetTempsRequest) String() string
type GetTempsResponse ¶
type GetTempsResponse struct {
Temps []float32 `protobuf:"fixed32,1,rep,packed,name=temps,proto3" json:"temps,omitempty"`
// contains filtered or unexported fields
}
func (*GetTempsResponse) Descriptor
deprecated
func (*GetTempsResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetTempsResponse.ProtoReflect.Descriptor instead.
func (*GetTempsResponse) GetTemps ¶
func (x *GetTempsResponse) GetTemps() []float32
func (*GetTempsResponse) ProtoMessage ¶
func (*GetTempsResponse) ProtoMessage()
func (*GetTempsResponse) ProtoReflect ¶
func (x *GetTempsResponse) ProtoReflect() protoreflect.Message
func (*GetTempsResponse) Reset ¶
func (x *GetTempsResponse) Reset()
func (*GetTempsResponse) String ¶
func (x *GetTempsResponse) String() string
type Location ¶
type Location struct {
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
Id int32 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
// contains filtered or unexported fields
}
func (*Location) Descriptor
deprecated
func (*Location) ProtoMessage ¶
func (*Location) ProtoMessage()
func (*Location) ProtoReflect ¶
func (x *Location) ProtoReflect() protoreflect.Message
type LocationsClient ¶
type LocationsClient interface {
GetLocations(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*GetLocationsResponse, error)
CreateLocation(ctx context.Context, in *Location, opts ...grpc.CallOption) (*Location, error)
}
LocationsClient is the client API for Locations service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewLocationsClient ¶
func NewLocationsClient(cc grpc.ClientConnInterface) LocationsClient
type LocationsServer ¶
type LocationsServer interface {
GetLocations(context.Context, *empty.Empty) (*GetLocationsResponse, error)
CreateLocation(context.Context, *Location) (*Location, error)
}
LocationsServer is the server API for Locations service.
type Temp ¶
type Temp struct {
Temp float32 `protobuf:"fixed32,1,opt,name=temp,proto3" json:"temp,omitempty"`
LocationId int32 `protobuf:"varint,2,opt,name=location_id,json=locationId,proto3" json:"location_id,omitempty"`
// contains filtered or unexported fields
}
func (*Temp) Descriptor
deprecated
func (*Temp) GetLocationId ¶
func (*Temp) ProtoMessage ¶
func (*Temp) ProtoMessage()
func (*Temp) ProtoReflect ¶
func (x *Temp) ProtoReflect() protoreflect.Message
type TempsClient ¶
type TempsClient interface {
GetTemps(ctx context.Context, in *GetTempsRequest, opts ...grpc.CallOption) (*GetTempsResponse, error)
CreateTemp(ctx context.Context, in *Temp, opts ...grpc.CallOption) (*empty.Empty, error)
}
TempsClient is the client API for Temps service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewTempsClient ¶
func NewTempsClient(cc grpc.ClientConnInterface) TempsClient
type TempsServer ¶
type TempsServer interface {
GetTemps(context.Context, *GetTempsRequest) (*GetTempsResponse, error)
CreateTemp(context.Context, *Temp) (*empty.Empty, error)
}
TempsServer is the server API for Temps service.
type UnimplementedLocationsServer ¶
type UnimplementedLocationsServer struct {
}
UnimplementedLocationsServer can be embedded to have forward compatible implementations.
func (*UnimplementedLocationsServer) CreateLocation ¶
func (*UnimplementedLocationsServer) GetLocations ¶
func (*UnimplementedLocationsServer) GetLocations(context.Context, *empty.Empty) (*GetLocationsResponse, error)
type UnimplementedTempsServer ¶
type UnimplementedTempsServer struct {
}
UnimplementedTempsServer can be embedded to have forward compatible implementations.
func (*UnimplementedTempsServer) CreateTemp ¶
func (*UnimplementedTempsServer) GetTemps ¶
func (*UnimplementedTempsServer) GetTemps(context.Context, *GetTempsRequest) (*GetTempsResponse, error)