Documentation
¶
Index ¶
- Constants
- Variables
- func RegisterKrkStopsServer(s grpc.ServiceRegistrar, srv KrkStopsServer)
- type Departure
- func (*Departure) Descriptor() ([]byte, []int)deprecated
- func (x *Departure) GetColor() uint32
- func (x *Departure) GetDirection() string
- func (x *Departure) GetPatternText() string
- func (x *Departure) GetPlannedTime() string
- func (x *Departure) GetPredicted() bool
- func (x *Departure) GetRelativeTime() int32
- func (x *Departure) GetRelativeTimeParsed() string
- func (x *Departure) GetType() Transit
- func (*Departure) ProtoMessage()
- func (x *Departure) ProtoReflect() protoreflect.Message
- func (x *Departure) Reset()
- func (x *Departure) String() string
- type GetAirlyInstallationRequest
- func (*GetAirlyInstallationRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetAirlyInstallationRequest) GetId() int32
- func (*GetAirlyInstallationRequest) ProtoMessage()
- func (x *GetAirlyInstallationRequest) ProtoReflect() protoreflect.Message
- func (x *GetAirlyInstallationRequest) Reset()
- func (x *GetAirlyInstallationRequest) String() string
- type GetDepartures2Request
- func (*GetDepartures2Request) Descriptor() ([]byte, []int)deprecated
- func (x *GetDepartures2Request) GetId() uint32
- func (*GetDepartures2Request) ProtoMessage()
- func (x *GetDepartures2Request) ProtoReflect() protoreflect.Message
- func (x *GetDepartures2Request) Reset()
- func (x *GetDepartures2Request) String() string
- type GetDepartures2Response
- func (*GetDepartures2Response) Descriptor() ([]byte, []int)deprecated
- func (x *GetDepartures2Response) GetDepartures() []*Departure
- func (*GetDepartures2Response) ProtoMessage()
- func (x *GetDepartures2Response) ProtoReflect() protoreflect.Message
- func (x *GetDepartures2Response) Reset()
- func (x *GetDepartures2Response) String() string
- type GetMeasurementRequest
- func (*GetMeasurementRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetMeasurementRequest) GetId() int32
- func (*GetMeasurementRequest) ProtoMessage()
- func (x *GetMeasurementRequest) ProtoReflect() protoreflect.Message
- func (x *GetMeasurementRequest) Reset()
- func (x *GetMeasurementRequest) String() string
- type Installation
- func (*Installation) Descriptor() ([]byte, []int)deprecated
- func (x *Installation) GetId() int32
- func (x *Installation) GetLatitude() float32
- func (x *Installation) GetLongitude() float32
- func (*Installation) ProtoMessage()
- func (x *Installation) ProtoReflect() protoreflect.Message
- func (x *Installation) Reset()
- func (x *Installation) String() string
- type KrkStopsClient
- type KrkStopsServer
- type Location
- type Measurement
- func (*Measurement) Descriptor() ([]byte, []int)deprecated
- func (x *Measurement) GetCaqi() int32
- func (x *Measurement) GetColor() uint32
- func (x *Measurement) GetColorStr() string
- func (x *Measurement) GetHumidity() int32
- func (x *Measurement) GetTemperature() float32
- func (*Measurement) ProtoMessage()
- func (x *Measurement) ProtoReflect() protoreflect.Message
- func (x *Measurement) Reset()
- func (x *Measurement) String() string
- type SearchStops2Request
- func (*SearchStops2Request) Descriptor() ([]byte, []int)deprecated
- func (x *SearchStops2Request) GetQuery() string
- func (*SearchStops2Request) ProtoMessage()
- func (x *SearchStops2Request) ProtoReflect() protoreflect.Message
- func (x *SearchStops2Request) Reset()
- func (x *SearchStops2Request) String() string
- type SearchStops2Response
- func (*SearchStops2Response) Descriptor() ([]byte, []int)deprecated
- func (x *SearchStops2Response) GetStops() []*Stop
- func (*SearchStops2Response) ProtoMessage()
- func (x *SearchStops2Response) ProtoReflect() protoreflect.Message
- func (x *SearchStops2Response) Reset()
- func (x *SearchStops2Response) String() string
- type Stop
- type Transit
- type UnimplementedKrkStopsServer
- func (UnimplementedKrkStopsServer) FindNearestAirlyInstallation(context.Context, *Location) (*Installation, error)
- func (UnimplementedKrkStopsServer) GetAirly(context.Context, *GetMeasurementRequest) (*Measurement, error)
- func (UnimplementedKrkStopsServer) GetAirlyInstallation(context.Context, *GetAirlyInstallationRequest) (*Installation, error)
- func (UnimplementedKrkStopsServer) GetDepartures2(context.Context, *GetDepartures2Request) (*GetDepartures2Response, error)
- func (UnimplementedKrkStopsServer) SearchStops2(context.Context, *SearchStops2Request) (*SearchStops2Response, error)
- type UnsafeKrkStopsServer
Constants ¶
const ( KrkStops_GetAirly_FullMethodName = "/KrkStops/GetAirly" KrkStops_FindNearestAirlyInstallation_FullMethodName = "/KrkStops/FindNearestAirlyInstallation" KrkStops_GetAirlyInstallation_FullMethodName = "/KrkStops/GetAirlyInstallation" KrkStops_GetDepartures2_FullMethodName = "/KrkStops/GetDepartures2" KrkStops_SearchStops2_FullMethodName = "/KrkStops/SearchStops2" )
Variables ¶
var ( Transit_name = map[int32]string{ 0: "BUS", 1: "TRAM", 2: "ALL", } Transit_value = map[string]int32{ "BUS": 0, "TRAM": 1, "ALL": 2, } )
Enum value maps for Transit.
var File_pb_krk_stops_proto protoreflect.FileDescriptor
var KrkStops_ServiceDesc = grpc.ServiceDesc{ ServiceName: "KrkStops", HandlerType: (*KrkStopsServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetAirly", Handler: _KrkStops_GetAirly_Handler, }, { MethodName: "FindNearestAirlyInstallation", Handler: _KrkStops_FindNearestAirlyInstallation_Handler, }, { MethodName: "GetAirlyInstallation", Handler: _KrkStops_GetAirlyInstallation_Handler, }, { MethodName: "GetDepartures2", Handler: _KrkStops_GetDepartures2_Handler, }, { MethodName: "SearchStops2", Handler: _KrkStops_SearchStops2_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "pb/krk-stops.proto", }
KrkStops_ServiceDesc is the grpc.ServiceDesc for KrkStops service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterKrkStopsServer ¶
func RegisterKrkStopsServer(s grpc.ServiceRegistrar, srv KrkStopsServer)
Types ¶
type Departure ¶
type Departure struct { RelativeTime int32 `protobuf:"varint,1,opt,name=relativeTime,proto3" json:"relativeTime,omitempty"` PlannedTime string `protobuf:"bytes,2,opt,name=plannedTime,proto3" json:"plannedTime,omitempty"` Direction string `protobuf:"bytes,3,opt,name=direction,proto3" json:"direction,omitempty"` PatternText string `protobuf:"bytes,4,opt,name=patternText,proto3" json:"patternText,omitempty"` Color uint32 `protobuf:"varint,5,opt,name=color,proto3" json:"color,omitempty"` RelativeTimeParsed string `protobuf:"bytes,6,opt,name=relativeTimeParsed,proto3" json:"relativeTimeParsed,omitempty"` Predicted bool `protobuf:"varint,7,opt,name=predicted,proto3" json:"predicted,omitempty"` Type Transit `protobuf:"varint,8,opt,name=type,proto3,enum=Transit" json:"type,omitempty"` // contains filtered or unexported fields }
func (*Departure) Descriptor
deprecated
func (*Departure) GetDirection ¶
func (*Departure) GetPatternText ¶
func (*Departure) GetPlannedTime ¶
func (*Departure) GetPredicted ¶
func (*Departure) GetRelativeTime ¶
func (*Departure) GetRelativeTimeParsed ¶
func (*Departure) ProtoMessage ¶
func (*Departure) ProtoMessage()
func (*Departure) ProtoReflect ¶
func (x *Departure) ProtoReflect() protoreflect.Message
type GetAirlyInstallationRequest ¶ added in v0.16.0
type GetAirlyInstallationRequest struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*GetAirlyInstallationRequest) Descriptor
deprecated
added in
v0.16.0
func (*GetAirlyInstallationRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetAirlyInstallationRequest.ProtoReflect.Descriptor instead.
func (*GetAirlyInstallationRequest) GetId ¶ added in v0.16.0
func (x *GetAirlyInstallationRequest) GetId() int32
func (*GetAirlyInstallationRequest) ProtoMessage ¶ added in v0.16.0
func (*GetAirlyInstallationRequest) ProtoMessage()
func (*GetAirlyInstallationRequest) ProtoReflect ¶ added in v0.16.0
func (x *GetAirlyInstallationRequest) ProtoReflect() protoreflect.Message
func (*GetAirlyInstallationRequest) Reset ¶ added in v0.16.0
func (x *GetAirlyInstallationRequest) Reset()
func (*GetAirlyInstallationRequest) String ¶ added in v0.16.0
func (x *GetAirlyInstallationRequest) String() string
type GetDepartures2Request ¶ added in v0.16.0
type GetDepartures2Request struct { Id uint32 `protobuf:"varint,3,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*GetDepartures2Request) Descriptor
deprecated
added in
v0.16.0
func (*GetDepartures2Request) Descriptor() ([]byte, []int)
Deprecated: Use GetDepartures2Request.ProtoReflect.Descriptor instead.
func (*GetDepartures2Request) GetId ¶ added in v0.16.0
func (x *GetDepartures2Request) GetId() uint32
func (*GetDepartures2Request) ProtoMessage ¶ added in v0.16.0
func (*GetDepartures2Request) ProtoMessage()
func (*GetDepartures2Request) ProtoReflect ¶ added in v0.16.0
func (x *GetDepartures2Request) ProtoReflect() protoreflect.Message
func (*GetDepartures2Request) Reset ¶ added in v0.16.0
func (x *GetDepartures2Request) Reset()
func (*GetDepartures2Request) String ¶ added in v0.16.0
func (x *GetDepartures2Request) String() string
type GetDepartures2Response ¶ added in v0.16.0
type GetDepartures2Response struct { Departures []*Departure `protobuf:"bytes,1,rep,name=departures,proto3" json:"departures,omitempty"` // contains filtered or unexported fields }
func (*GetDepartures2Response) Descriptor
deprecated
added in
v0.16.0
func (*GetDepartures2Response) Descriptor() ([]byte, []int)
Deprecated: Use GetDepartures2Response.ProtoReflect.Descriptor instead.
func (*GetDepartures2Response) GetDepartures ¶ added in v0.16.0
func (x *GetDepartures2Response) GetDepartures() []*Departure
func (*GetDepartures2Response) ProtoMessage ¶ added in v0.16.0
func (*GetDepartures2Response) ProtoMessage()
func (*GetDepartures2Response) ProtoReflect ¶ added in v0.16.0
func (x *GetDepartures2Response) ProtoReflect() protoreflect.Message
func (*GetDepartures2Response) Reset ¶ added in v0.16.0
func (x *GetDepartures2Response) Reset()
func (*GetDepartures2Response) String ¶ added in v0.16.0
func (x *GetDepartures2Response) String() string
type GetMeasurementRequest ¶ added in v0.16.0
type GetMeasurementRequest struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*GetMeasurementRequest) Descriptor
deprecated
added in
v0.16.0
func (*GetMeasurementRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetMeasurementRequest.ProtoReflect.Descriptor instead.
func (*GetMeasurementRequest) GetId ¶ added in v0.16.0
func (x *GetMeasurementRequest) GetId() int32
func (*GetMeasurementRequest) ProtoMessage ¶ added in v0.16.0
func (*GetMeasurementRequest) ProtoMessage()
func (*GetMeasurementRequest) ProtoReflect ¶ added in v0.16.0
func (x *GetMeasurementRequest) ProtoReflect() protoreflect.Message
func (*GetMeasurementRequest) Reset ¶ added in v0.16.0
func (x *GetMeasurementRequest) Reset()
func (*GetMeasurementRequest) String ¶ added in v0.16.0
func (x *GetMeasurementRequest) String() string
type Installation ¶
type Installation struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` Latitude float32 `protobuf:"fixed32,2,opt,name=latitude,proto3" json:"latitude,omitempty"` Longitude float32 `protobuf:"fixed32,3,opt,name=longitude,proto3" json:"longitude,omitempty"` // contains filtered or unexported fields }
func (*Installation) Descriptor
deprecated
func (*Installation) Descriptor() ([]byte, []int)
Deprecated: Use Installation.ProtoReflect.Descriptor instead.
func (*Installation) GetId ¶
func (x *Installation) GetId() int32
func (*Installation) GetLatitude ¶
func (x *Installation) GetLatitude() float32
func (*Installation) GetLongitude ¶
func (x *Installation) GetLongitude() float32
func (*Installation) ProtoMessage ¶
func (*Installation) ProtoMessage()
func (*Installation) ProtoReflect ¶
func (x *Installation) ProtoReflect() protoreflect.Message
func (*Installation) Reset ¶
func (x *Installation) Reset()
func (*Installation) String ¶
func (x *Installation) String() string
type KrkStopsClient ¶
type KrkStopsClient interface { GetAirly(ctx context.Context, in *GetMeasurementRequest, opts ...grpc.CallOption) (*Measurement, error) FindNearestAirlyInstallation(ctx context.Context, in *Location, opts ...grpc.CallOption) (*Installation, error) GetAirlyInstallation(ctx context.Context, in *GetAirlyInstallationRequest, opts ...grpc.CallOption) (*Installation, error) GetDepartures2(ctx context.Context, in *GetDepartures2Request, opts ...grpc.CallOption) (*GetDepartures2Response, error) SearchStops2(ctx context.Context, in *SearchStops2Request, opts ...grpc.CallOption) (*SearchStops2Response, error) }
KrkStopsClient is the client API for KrkStops service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewKrkStopsClient ¶
func NewKrkStopsClient(cc grpc.ClientConnInterface) KrkStopsClient
type KrkStopsServer ¶
type KrkStopsServer interface { GetAirly(context.Context, *GetMeasurementRequest) (*Measurement, error) FindNearestAirlyInstallation(context.Context, *Location) (*Installation, error) GetAirlyInstallation(context.Context, *GetAirlyInstallationRequest) (*Installation, error) GetDepartures2(context.Context, *GetDepartures2Request) (*GetDepartures2Response, error) SearchStops2(context.Context, *SearchStops2Request) (*SearchStops2Response, error) // contains filtered or unexported methods }
KrkStopsServer is the server API for KrkStops service. All implementations must embed UnimplementedKrkStopsServer for forward compatibility
type Location ¶ added in v0.16.0
type Location struct { Latitude float32 `protobuf:"fixed32,1,opt,name=latitude,proto3" json:"latitude,omitempty"` Longitude float32 `protobuf:"fixed32,2,opt,name=longitude,proto3" json:"longitude,omitempty"` // contains filtered or unexported fields }
func (*Location) Descriptor
deprecated
added in
v0.16.0
func (*Location) GetLatitude ¶ added in v0.16.0
func (*Location) GetLongitude ¶ added in v0.16.0
func (*Location) ProtoMessage ¶ added in v0.16.0
func (*Location) ProtoMessage()
func (*Location) ProtoReflect ¶ added in v0.16.0
func (x *Location) ProtoReflect() protoreflect.Message
type Measurement ¶ added in v0.16.0
type Measurement struct { Caqi int32 `protobuf:"varint,1,opt,name=caqi,proto3" json:"caqi,omitempty"` ColorStr string `protobuf:"bytes,2,opt,name=colorStr,proto3" json:"colorStr,omitempty"` Humidity int32 `protobuf:"varint,3,opt,name=humidity,proto3" json:"humidity,omitempty"` Temperature float32 `protobuf:"fixed32,4,opt,name=temperature,proto3" json:"temperature,omitempty"` Color uint32 `protobuf:"varint,5,opt,name=color,proto3" json:"color,omitempty"` // contains filtered or unexported fields }
func (*Measurement) Descriptor
deprecated
added in
v0.16.0
func (*Measurement) Descriptor() ([]byte, []int)
Deprecated: Use Measurement.ProtoReflect.Descriptor instead.
func (*Measurement) GetCaqi ¶ added in v0.16.0
func (x *Measurement) GetCaqi() int32
func (*Measurement) GetColor ¶ added in v0.16.0
func (x *Measurement) GetColor() uint32
func (*Measurement) GetColorStr ¶ added in v0.16.0
func (x *Measurement) GetColorStr() string
func (*Measurement) GetHumidity ¶ added in v0.16.0
func (x *Measurement) GetHumidity() int32
func (*Measurement) GetTemperature ¶ added in v0.16.0
func (x *Measurement) GetTemperature() float32
func (*Measurement) ProtoMessage ¶ added in v0.16.0
func (*Measurement) ProtoMessage()
func (*Measurement) ProtoReflect ¶ added in v0.16.0
func (x *Measurement) ProtoReflect() protoreflect.Message
func (*Measurement) Reset ¶ added in v0.16.0
func (x *Measurement) Reset()
func (*Measurement) String ¶ added in v0.16.0
func (x *Measurement) String() string
type SearchStops2Request ¶ added in v0.16.0
type SearchStops2Request struct { Query string `protobuf:"bytes,1,opt,name=query,proto3" json:"query,omitempty"` // contains filtered or unexported fields }
func (*SearchStops2Request) Descriptor
deprecated
added in
v0.16.0
func (*SearchStops2Request) Descriptor() ([]byte, []int)
Deprecated: Use SearchStops2Request.ProtoReflect.Descriptor instead.
func (*SearchStops2Request) GetQuery ¶ added in v0.16.0
func (x *SearchStops2Request) GetQuery() string
func (*SearchStops2Request) ProtoMessage ¶ added in v0.16.0
func (*SearchStops2Request) ProtoMessage()
func (*SearchStops2Request) ProtoReflect ¶ added in v0.16.0
func (x *SearchStops2Request) ProtoReflect() protoreflect.Message
func (*SearchStops2Request) Reset ¶ added in v0.16.0
func (x *SearchStops2Request) Reset()
func (*SearchStops2Request) String ¶ added in v0.16.0
func (x *SearchStops2Request) String() string
type SearchStops2Response ¶ added in v0.16.0
type SearchStops2Response struct { Stops []*Stop `protobuf:"bytes,1,rep,name=stops,proto3" json:"stops,omitempty"` // contains filtered or unexported fields }
func (*SearchStops2Response) Descriptor
deprecated
added in
v0.16.0
func (*SearchStops2Response) Descriptor() ([]byte, []int)
Deprecated: Use SearchStops2Response.ProtoReflect.Descriptor instead.
func (*SearchStops2Response) GetStops ¶ added in v0.16.0
func (x *SearchStops2Response) GetStops() []*Stop
func (*SearchStops2Response) ProtoMessage ¶ added in v0.16.0
func (*SearchStops2Response) ProtoMessage()
func (*SearchStops2Response) ProtoReflect ¶ added in v0.16.0
func (x *SearchStops2Response) ProtoReflect() protoreflect.Message
func (*SearchStops2Response) Reset ¶ added in v0.16.0
func (x *SearchStops2Response) Reset()
func (*SearchStops2Response) String ¶ added in v0.16.0
func (x *SearchStops2Response) String() string
type Stop ¶
type Stop struct { Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` Id uint32 `protobuf:"varint,3,opt,name=id,proto3" json:"id,omitempty"` Type Transit `protobuf:"varint,4,opt,name=type,proto3,enum=Transit" json:"type,omitempty"` // contains filtered or unexported fields }
func (*Stop) Descriptor
deprecated
func (*Stop) ProtoMessage ¶
func (*Stop) ProtoMessage()
func (*Stop) ProtoReflect ¶
func (x *Stop) ProtoReflect() protoreflect.Message
type Transit ¶ added in v0.16.0
type Transit int32
func (Transit) Descriptor ¶ added in v0.16.0
func (Transit) Descriptor() protoreflect.EnumDescriptor
func (Transit) EnumDescriptor
deprecated
added in
v0.16.0
func (Transit) Number ¶ added in v0.16.0
func (x Transit) Number() protoreflect.EnumNumber
func (Transit) Type ¶ added in v0.16.0
func (Transit) Type() protoreflect.EnumType
type UnimplementedKrkStopsServer ¶
type UnimplementedKrkStopsServer struct { }
UnimplementedKrkStopsServer must be embedded to have forward compatible implementations.
func (UnimplementedKrkStopsServer) FindNearestAirlyInstallation ¶
func (UnimplementedKrkStopsServer) FindNearestAirlyInstallation(context.Context, *Location) (*Installation, error)
func (UnimplementedKrkStopsServer) GetAirly ¶
func (UnimplementedKrkStopsServer) GetAirly(context.Context, *GetMeasurementRequest) (*Measurement, error)
func (UnimplementedKrkStopsServer) GetAirlyInstallation ¶
func (UnimplementedKrkStopsServer) GetAirlyInstallation(context.Context, *GetAirlyInstallationRequest) (*Installation, error)
func (UnimplementedKrkStopsServer) GetDepartures2 ¶ added in v0.5.0
func (UnimplementedKrkStopsServer) GetDepartures2(context.Context, *GetDepartures2Request) (*GetDepartures2Response, error)
func (UnimplementedKrkStopsServer) SearchStops2 ¶ added in v0.5.0
func (UnimplementedKrkStopsServer) SearchStops2(context.Context, *SearchStops2Request) (*SearchStops2Response, error)
type UnsafeKrkStopsServer ¶
type UnsafeKrkStopsServer interface {
// contains filtered or unexported methods
}
UnsafeKrkStopsServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to KrkStopsServer will result in compilation errors.