Documentation
¶
Index ¶
- Variables
- func RegisterShippingServiceServer(s *grpc.Server, srv ShippingServiceServer)
- type Consignment
- func (*Consignment) Descriptor() ([]byte, []int)deprecated
- func (x *Consignment) GetContainers() []*Container
- func (x *Consignment) GetDescription() string
- func (x *Consignment) GetId() string
- func (x *Consignment) GetVesselId() string
- func (x *Consignment) GetWeight() int32
- func (*Consignment) ProtoMessage()
- func (x *Consignment) ProtoReflect() protoreflect.Message
- func (x *Consignment) Reset()
- func (x *Consignment) String() string
- type Container
- func (*Container) Descriptor() ([]byte, []int)deprecated
- func (x *Container) GetCustomerId() string
- func (x *Container) GetId() string
- func (x *Container) GetOrigin() string
- func (x *Container) GetUserId() string
- func (*Container) ProtoMessage()
- func (x *Container) ProtoReflect() protoreflect.Message
- func (x *Container) Reset()
- func (x *Container) String() string
- type Response
- type ShippingServiceClient
- type ShippingServiceServer
- type UnimplementedShippingServiceServer
Constants ¶
This section is empty.
Variables ¶
View Source
var File_consignment_proto protoreflect.FileDescriptor
Functions ¶
func RegisterShippingServiceServer ¶
func RegisterShippingServiceServer(s *grpc.Server, srv ShippingServiceServer)
Types ¶
type Consignment ¶
type Consignment struct {
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"`
Weight int32 `protobuf:"varint,3,opt,name=weight,proto3" json:"weight,omitempty"`
Containers []*Container `protobuf:"bytes,4,rep,name=containers,proto3" json:"containers,omitempty"`
VesselId string `protobuf:"bytes,5,opt,name=vessel_id,json=vesselId,proto3" json:"vessel_id,omitempty"`
// contains filtered or unexported fields
}
func (*Consignment) Descriptor
deprecated
func (*Consignment) Descriptor() ([]byte, []int)
Deprecated: Use Consignment.ProtoReflect.Descriptor instead.
func (*Consignment) GetContainers ¶
func (x *Consignment) GetContainers() []*Container
func (*Consignment) GetDescription ¶
func (x *Consignment) GetDescription() string
func (*Consignment) GetId ¶
func (x *Consignment) GetId() string
func (*Consignment) GetVesselId ¶
func (x *Consignment) GetVesselId() string
func (*Consignment) GetWeight ¶
func (x *Consignment) GetWeight() int32
func (*Consignment) ProtoMessage ¶
func (*Consignment) ProtoMessage()
func (*Consignment) ProtoReflect ¶
func (x *Consignment) ProtoReflect() protoreflect.Message
func (*Consignment) Reset ¶
func (x *Consignment) Reset()
func (*Consignment) String ¶
func (x *Consignment) String() string
type Container ¶
type Container struct {
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
CustomerId string `protobuf:"bytes,2,opt,name=customer_id,json=customerId,proto3" json:"customer_id,omitempty"`
Origin string `protobuf:"bytes,3,opt,name=origin,proto3" json:"origin,omitempty"`
UserId string `protobuf:"bytes,4,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
// contains filtered or unexported fields
}
func (*Container) Descriptor
deprecated
func (*Container) GetCustomerId ¶
func (*Container) ProtoMessage ¶
func (*Container) ProtoMessage()
func (*Container) ProtoReflect ¶
func (x *Container) ProtoReflect() protoreflect.Message
type Response ¶
type Response struct {
Created bool `protobuf:"varint,1,opt,name=created,proto3" json:"created,omitempty"`
Consignment *Consignment `protobuf:"bytes,2,opt,name=consignment,proto3" json:"consignment,omitempty"`
// contains filtered or unexported fields
}
func (*Response) Descriptor
deprecated
func (*Response) GetConsignment ¶
func (x *Response) GetConsignment() *Consignment
func (*Response) GetCreated ¶
func (*Response) ProtoMessage ¶
func (*Response) ProtoMessage()
func (*Response) ProtoReflect ¶
func (x *Response) ProtoReflect() protoreflect.Message
type ShippingServiceClient ¶
type ShippingServiceClient interface {
CreateConsignment(ctx context.Context, in *Consignment, opts ...grpc.CallOption) (*Response, error)
}
ShippingServiceClient is the client API for ShippingService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewShippingServiceClient ¶
func NewShippingServiceClient(cc grpc.ClientConnInterface) ShippingServiceClient
type ShippingServiceServer ¶
type ShippingServiceServer interface {
CreateConsignment(context.Context, *Consignment) (*Response, error)
}
ShippingServiceServer is the server API for ShippingService service.
type UnimplementedShippingServiceServer ¶
type UnimplementedShippingServiceServer struct {
}
UnimplementedShippingServiceServer can be embedded to have forward compatible implementations.
func (*UnimplementedShippingServiceServer) CreateConsignment ¶
func (*UnimplementedShippingServiceServer) CreateConsignment(context.Context, *Consignment) (*Response, error)
Click to show internal directories.
Click to hide internal directories.