gen

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2022 License: MIT Imports: 18 Imported by: 0

Documentation

Overview

Package gen is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Package gen is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

This section is empty.

Variables

View Source
var (
	OrderSource_name = map[int32]string{
		0: "COUNTER",
		1: "WEB",
	}
	OrderSource_value = map[string]int32{
		"COUNTER": 0,
		"WEB":     1,
	}
)

Enum value maps for OrderSource.

View Source
var (
	Status_name = map[int32]string{
		0: "PLACED",
		1: "IN_PROGRESS",
		2: "FULFILLED",
	}
	Status_value = map[string]int32{
		"PLACED":      0,
		"IN_PROGRESS": 1,
		"FULFILLED":   2,
	}
)

Enum value maps for Status.

View Source
var (
	Location_name = map[int32]string{
		0: "ATLANTA",
		1: "CHARLOTTE",
		2: "RALEIGH",
	}
	Location_value = map[string]int32{
		"ATLANTA":   0,
		"CHARLOTTE": 1,
		"RALEIGH":   2,
	}
)

Enum value maps for Location.

View Source
var (
	ItemType_name = map[int32]string{
		0: "CAPPUCCINO",
		1: "COFFEE_BLACK",
		2: "COFFEE_WITH_ROOM",
		3: "ESPRESSO",
		4: "ESPRESSO_DOUBLE",
		5: "LATTE",
		6: "CAKEPOP",
		7: "CROISSANT",
		8: "MUFFIN",
		9: "CROISSANT_CHOCOLATE",
	}
	ItemType_value = map[string]int32{
		"CAPPUCCINO":          0,
		"COFFEE_BLACK":        1,
		"COFFEE_WITH_ROOM":    2,
		"ESPRESSO":            3,
		"ESPRESSO_DOUBLE":     4,
		"LATTE":               5,
		"CAKEPOP":             6,
		"CROISSANT":           7,
		"MUFFIN":              8,
		"CROISSANT_CHOCOLATE": 9,
	}
)

Enum value maps for ItemType.

View Source
var (
	CommandType_name = map[int32]string{
		0: "PLACE_ORDER",
	}
	CommandType_value = map[string]int32{
		"PLACE_ORDER": 0,
	}
)

Enum value maps for CommandType.

View Source
var CounterService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "go.coffeeshop.proto.counterapi.CounterService",
	HandlerType: (*CounterServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "GetListOrderFulfillment",
			Handler:    _CounterService_GetListOrderFulfillment_Handler,
		},
		{
			MethodName: "PlaceOrder",
			Handler:    _CounterService_PlaceOrder_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "counter.proto",
}

CounterService_ServiceDesc is the grpc.ServiceDesc for CounterService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_common_proto protoreflect.FileDescriptor
View Source
var File_counter_proto protoreflect.FileDescriptor
View Source
var File_product_proto protoreflect.FileDescriptor
View Source
var ProductService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "go.coffeeshop.proto.productapi.ProductService",
	HandlerType: (*ProductServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "GetItemTypes",
			Handler:    _ProductService_GetItemTypes_Handler,
		},
		{
			MethodName: "GetItemsByType",
			Handler:    _ProductService_GetItemsByType_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "product.proto",
}

ProductService_ServiceDesc is the grpc.ServiceDesc for ProductService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterCounterServiceHandler

func RegisterCounterServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterCounterServiceHandler registers the http handlers for service CounterService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterCounterServiceHandlerClient

func RegisterCounterServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client CounterServiceClient) error

RegisterCounterServiceHandlerClient registers the http handlers for service CounterService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "CounterServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "CounterServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "CounterServiceClient" to call the correct interceptors.

func RegisterCounterServiceHandlerFromEndpoint

func RegisterCounterServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterCounterServiceHandlerFromEndpoint is same as RegisterCounterServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterCounterServiceHandlerServer

func RegisterCounterServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server CounterServiceServer) error

RegisterCounterServiceHandlerServer registers the http handlers for service CounterService to "mux". UnaryRPC :call CounterServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterCounterServiceHandlerFromEndpoint instead.

func RegisterCounterServiceServer

func RegisterCounterServiceServer(s grpc.ServiceRegistrar, srv CounterServiceServer)

func RegisterProductServiceHandler

func RegisterProductServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterProductServiceHandler registers the http handlers for service ProductService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterProductServiceHandlerClient

func RegisterProductServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ProductServiceClient) error

RegisterProductServiceHandlerClient registers the http handlers for service ProductService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "ProductServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "ProductServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "ProductServiceClient" to call the correct interceptors.

func RegisterProductServiceHandlerFromEndpoint

func RegisterProductServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterProductServiceHandlerFromEndpoint is same as RegisterProductServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterProductServiceHandlerServer

func RegisterProductServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ProductServiceServer) error

RegisterProductServiceHandlerServer registers the http handlers for service ProductService to "mux". UnaryRPC :call ProductServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterProductServiceHandlerFromEndpoint instead.

func RegisterProductServiceServer

func RegisterProductServiceServer(s grpc.ServiceRegistrar, srv ProductServiceServer)

Types

type CommandItem

type CommandItem struct {
	ItemType ItemType `` /* 127-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*CommandItem) Descriptor deprecated

func (*CommandItem) Descriptor() ([]byte, []int)

Deprecated: Use CommandItem.ProtoReflect.Descriptor instead.

func (*CommandItem) GetItemType

func (x *CommandItem) GetItemType() ItemType

func (*CommandItem) ProtoMessage

func (*CommandItem) ProtoMessage()

func (*CommandItem) ProtoReflect

func (x *CommandItem) ProtoReflect() protoreflect.Message

func (*CommandItem) Reset

func (x *CommandItem) Reset()

func (*CommandItem) String

func (x *CommandItem) String() string

type CommandType

type CommandType int32
const (
	CommandType_PLACE_ORDER CommandType = 0
)

func (CommandType) Descriptor

func (CommandType) Enum

func (x CommandType) Enum() *CommandType

func (CommandType) EnumDescriptor deprecated

func (CommandType) EnumDescriptor() ([]byte, []int)

Deprecated: Use CommandType.Descriptor instead.

func (CommandType) Number

func (x CommandType) Number() protoreflect.EnumNumber

func (CommandType) String

func (x CommandType) String() string

func (CommandType) Type

type CounterServiceClient

type CounterServiceClient interface {
	GetListOrderFulfillment(ctx context.Context, in *GetListOrderFulfillmentRequest, opts ...grpc.CallOption) (*GetListOrderFulfillmentResponse, error)
	PlaceOrder(ctx context.Context, in *PlaceOrderRequest, opts ...grpc.CallOption) (*PlaceOrderResponse, error)
}

CounterServiceClient is the client API for CounterService 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.

type CounterServiceServer

type CounterServiceServer interface {
	GetListOrderFulfillment(context.Context, *GetListOrderFulfillmentRequest) (*GetListOrderFulfillmentResponse, error)
	PlaceOrder(context.Context, *PlaceOrderRequest) (*PlaceOrderResponse, error)
}

CounterServiceServer is the server API for CounterService service. All implementations should embed UnimplementedCounterServiceServer for forward compatibility

type GetItemTypesRequest

type GetItemTypesRequest struct {
	// contains filtered or unexported fields
}

func (*GetItemTypesRequest) Descriptor deprecated

func (*GetItemTypesRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetItemTypesRequest.ProtoReflect.Descriptor instead.

func (*GetItemTypesRequest) ProtoMessage

func (*GetItemTypesRequest) ProtoMessage()

func (*GetItemTypesRequest) ProtoReflect

func (x *GetItemTypesRequest) ProtoReflect() protoreflect.Message

func (*GetItemTypesRequest) Reset

func (x *GetItemTypesRequest) Reset()

func (*GetItemTypesRequest) String

func (x *GetItemTypesRequest) String() string

type GetItemTypesResponse

type GetItemTypesResponse struct {
	ItemTypes []*ItemTypeDto `protobuf:"bytes,1,rep,name=item_types,json=itemTypes,proto3" json:"item_types,omitempty"`
	// contains filtered or unexported fields
}

func (*GetItemTypesResponse) Descriptor deprecated

func (*GetItemTypesResponse) Descriptor() ([]byte, []int)

Deprecated: Use GetItemTypesResponse.ProtoReflect.Descriptor instead.

func (*GetItemTypesResponse) GetItemTypes

func (x *GetItemTypesResponse) GetItemTypes() []*ItemTypeDto

func (*GetItemTypesResponse) ProtoMessage

func (*GetItemTypesResponse) ProtoMessage()

func (*GetItemTypesResponse) ProtoReflect

func (x *GetItemTypesResponse) ProtoReflect() protoreflect.Message

func (*GetItemTypesResponse) Reset

func (x *GetItemTypesResponse) Reset()

func (*GetItemTypesResponse) String

func (x *GetItemTypesResponse) String() string

type GetItemsByTypeRequest

type GetItemsByTypeRequest struct {
	ItemTypes string `protobuf:"bytes,1,opt,name=item_types,json=itemTypes,proto3" json:"item_types,omitempty"`
	// contains filtered or unexported fields
}

func (*GetItemsByTypeRequest) Descriptor deprecated

func (*GetItemsByTypeRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetItemsByTypeRequest.ProtoReflect.Descriptor instead.

func (*GetItemsByTypeRequest) GetItemTypes

func (x *GetItemsByTypeRequest) GetItemTypes() string

func (*GetItemsByTypeRequest) ProtoMessage

func (*GetItemsByTypeRequest) ProtoMessage()

func (*GetItemsByTypeRequest) ProtoReflect

func (x *GetItemsByTypeRequest) ProtoReflect() protoreflect.Message

func (*GetItemsByTypeRequest) Reset

func (x *GetItemsByTypeRequest) Reset()

func (*GetItemsByTypeRequest) String

func (x *GetItemsByTypeRequest) String() string

type GetItemsByTypeResponse

type GetItemsByTypeResponse struct {
	Items []*ItemDto `protobuf:"bytes,1,rep,name=items,proto3" json:"items,omitempty"`
	// contains filtered or unexported fields
}

func (*GetItemsByTypeResponse) Descriptor deprecated

func (*GetItemsByTypeResponse) Descriptor() ([]byte, []int)

Deprecated: Use GetItemsByTypeResponse.ProtoReflect.Descriptor instead.

func (*GetItemsByTypeResponse) GetItems

func (x *GetItemsByTypeResponse) GetItems() []*ItemDto

func (*GetItemsByTypeResponse) ProtoMessage

func (*GetItemsByTypeResponse) ProtoMessage()

func (*GetItemsByTypeResponse) ProtoReflect

func (x *GetItemsByTypeResponse) ProtoReflect() protoreflect.Message

func (*GetItemsByTypeResponse) Reset

func (x *GetItemsByTypeResponse) Reset()

func (*GetItemsByTypeResponse) String

func (x *GetItemsByTypeResponse) String() string

type GetListOrderFulfillmentRequest

type GetListOrderFulfillmentRequest struct {
	// contains filtered or unexported fields
}

func (*GetListOrderFulfillmentRequest) Descriptor deprecated

func (*GetListOrderFulfillmentRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetListOrderFulfillmentRequest.ProtoReflect.Descriptor instead.

func (*GetListOrderFulfillmentRequest) ProtoMessage

func (*GetListOrderFulfillmentRequest) ProtoMessage()

func (*GetListOrderFulfillmentRequest) ProtoReflect

func (*GetListOrderFulfillmentRequest) Reset

func (x *GetListOrderFulfillmentRequest) Reset()

func (*GetListOrderFulfillmentRequest) String

type GetListOrderFulfillmentResponse

type GetListOrderFulfillmentResponse struct {
	Orders []*OrderDto `protobuf:"bytes,1,rep,name=orders,proto3" json:"orders,omitempty"`
	// contains filtered or unexported fields
}

func (*GetListOrderFulfillmentResponse) Descriptor deprecated

func (*GetListOrderFulfillmentResponse) Descriptor() ([]byte, []int)

Deprecated: Use GetListOrderFulfillmentResponse.ProtoReflect.Descriptor instead.

func (*GetListOrderFulfillmentResponse) GetOrders

func (x *GetListOrderFulfillmentResponse) GetOrders() []*OrderDto

func (*GetListOrderFulfillmentResponse) ProtoMessage

func (*GetListOrderFulfillmentResponse) ProtoMessage()

func (*GetListOrderFulfillmentResponse) ProtoReflect

func (*GetListOrderFulfillmentResponse) Reset

func (*GetListOrderFulfillmentResponse) String

type ItemDto

type ItemDto struct {
	Price float64 `protobuf:"fixed64,1,opt,name=price,proto3" json:"price,omitempty"`
	Type  int32   `protobuf:"varint,2,opt,name=type,proto3" json:"type,omitempty"`
	// contains filtered or unexported fields
}

func (*ItemDto) Descriptor deprecated

func (*ItemDto) Descriptor() ([]byte, []int)

Deprecated: Use ItemDto.ProtoReflect.Descriptor instead.

func (*ItemDto) GetPrice

func (x *ItemDto) GetPrice() float64

func (*ItemDto) GetType

func (x *ItemDto) GetType() int32

func (*ItemDto) ProtoMessage

func (*ItemDto) ProtoMessage()

func (*ItemDto) ProtoReflect

func (x *ItemDto) ProtoReflect() protoreflect.Message

func (*ItemDto) Reset

func (x *ItemDto) Reset()

func (*ItemDto) String

func (x *ItemDto) String() string

type ItemType

type ItemType int32
const (
	// Beverages
	ItemType_CAPPUCCINO       ItemType = 0
	ItemType_COFFEE_BLACK     ItemType = 1
	ItemType_COFFEE_WITH_ROOM ItemType = 2
	ItemType_ESPRESSO         ItemType = 3
	ItemType_ESPRESSO_DOUBLE  ItemType = 4
	ItemType_LATTE            ItemType = 5
	// Food
	ItemType_CAKEPOP             ItemType = 6
	ItemType_CROISSANT           ItemType = 7
	ItemType_MUFFIN              ItemType = 8
	ItemType_CROISSANT_CHOCOLATE ItemType = 9
)

func (ItemType) Descriptor

func (ItemType) Descriptor() protoreflect.EnumDescriptor

func (ItemType) Enum

func (x ItemType) Enum() *ItemType

func (ItemType) EnumDescriptor deprecated

func (ItemType) EnumDescriptor() ([]byte, []int)

Deprecated: Use ItemType.Descriptor instead.

func (ItemType) Number

func (x ItemType) Number() protoreflect.EnumNumber

func (ItemType) String

func (x ItemType) String() string

func (ItemType) Type

type ItemTypeDto

type ItemTypeDto struct {
	Name  string  `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Type  int32   `protobuf:"varint,2,opt,name=type,proto3" json:"type,omitempty"`
	Price float64 `protobuf:"fixed64,3,opt,name=price,proto3" json:"price,omitempty"`
	Image string  `protobuf:"bytes,4,opt,name=image,proto3" json:"image,omitempty"`
	// contains filtered or unexported fields
}

func (*ItemTypeDto) Descriptor deprecated

func (*ItemTypeDto) Descriptor() ([]byte, []int)

Deprecated: Use ItemTypeDto.ProtoReflect.Descriptor instead.

func (*ItemTypeDto) GetImage

func (x *ItemTypeDto) GetImage() string

func (*ItemTypeDto) GetName

func (x *ItemTypeDto) GetName() string

func (*ItemTypeDto) GetPrice

func (x *ItemTypeDto) GetPrice() float64

func (*ItemTypeDto) GetType

func (x *ItemTypeDto) GetType() int32

func (*ItemTypeDto) ProtoMessage

func (*ItemTypeDto) ProtoMessage()

func (*ItemTypeDto) ProtoReflect

func (x *ItemTypeDto) ProtoReflect() protoreflect.Message

func (*ItemTypeDto) Reset

func (x *ItemTypeDto) Reset()

func (*ItemTypeDto) String

func (x *ItemTypeDto) String() string

type LineItemDto

type LineItemDto struct {
	Id             string   `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	ItemType       ItemType `` /* 127-byte string literal not displayed */
	Name           string   `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
	Price          float64  `protobuf:"fixed64,4,opt,name=price,proto3" json:"price,omitempty"`
	ItemStatus     Status   `` /* 131-byte string literal not displayed */
	IsBaristaOrder bool     `protobuf:"varint,6,opt,name=is_barista_order,json=isBaristaOrder,proto3" json:"is_barista_order,omitempty"`
	// contains filtered or unexported fields
}

func (*LineItemDto) Descriptor deprecated

func (*LineItemDto) Descriptor() ([]byte, []int)

Deprecated: Use LineItemDto.ProtoReflect.Descriptor instead.

func (*LineItemDto) GetId

func (x *LineItemDto) GetId() string

func (*LineItemDto) GetIsBaristaOrder

func (x *LineItemDto) GetIsBaristaOrder() bool

func (*LineItemDto) GetItemStatus

func (x *LineItemDto) GetItemStatus() Status

func (*LineItemDto) GetItemType

func (x *LineItemDto) GetItemType() ItemType

func (*LineItemDto) GetName

func (x *LineItemDto) GetName() string

func (*LineItemDto) GetPrice

func (x *LineItemDto) GetPrice() float64

func (*LineItemDto) ProtoMessage

func (*LineItemDto) ProtoMessage()

func (*LineItemDto) ProtoReflect

func (x *LineItemDto) ProtoReflect() protoreflect.Message

func (*LineItemDto) Reset

func (x *LineItemDto) Reset()

func (*LineItemDto) String

func (x *LineItemDto) String() string

type Location

type Location int32
const (
	Location_ATLANTA   Location = 0
	Location_CHARLOTTE Location = 1
	Location_RALEIGH   Location = 2
)

func (Location) Descriptor

func (Location) Descriptor() protoreflect.EnumDescriptor

func (Location) Enum

func (x Location) Enum() *Location

func (Location) EnumDescriptor deprecated

func (Location) EnumDescriptor() ([]byte, []int)

Deprecated: Use Location.Descriptor instead.

func (Location) Number

func (x Location) Number() protoreflect.EnumNumber

func (Location) String

func (x Location) String() string

func (Location) Type

type OrderDto

type OrderDto struct {
	Id              string         `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	OrderSource     OrderSource    `` /* 139-byte string literal not displayed */
	LoyaltyMemberId string         `protobuf:"bytes,3,opt,name=loyalty_member_id,json=loyaltyMemberId,proto3" json:"loyalty_member_id,omitempty"`
	OrderStatus     Status         `` /* 134-byte string literal not displayed */
	Localtion       Location       `protobuf:"varint,5,opt,name=localtion,proto3,enum=go.coffeeshop.proto.common.Location" json:"localtion,omitempty"`
	LineItems       []*LineItemDto `protobuf:"bytes,6,rep,name=line_items,json=lineItems,proto3" json:"line_items,omitempty"`
	// contains filtered or unexported fields
}

func (*OrderDto) Descriptor deprecated

func (*OrderDto) Descriptor() ([]byte, []int)

Deprecated: Use OrderDto.ProtoReflect.Descriptor instead.

func (*OrderDto) GetId

func (x *OrderDto) GetId() string

func (*OrderDto) GetLineItems

func (x *OrderDto) GetLineItems() []*LineItemDto

func (*OrderDto) GetLocaltion

func (x *OrderDto) GetLocaltion() Location

func (*OrderDto) GetLoyaltyMemberId

func (x *OrderDto) GetLoyaltyMemberId() string

func (*OrderDto) GetOrderSource

func (x *OrderDto) GetOrderSource() OrderSource

func (*OrderDto) GetOrderStatus

func (x *OrderDto) GetOrderStatus() Status

func (*OrderDto) ProtoMessage

func (*OrderDto) ProtoMessage()

func (*OrderDto) ProtoReflect

func (x *OrderDto) ProtoReflect() protoreflect.Message

func (*OrderDto) Reset

func (x *OrderDto) Reset()

func (*OrderDto) String

func (x *OrderDto) String() string

type OrderSource

type OrderSource int32
const (
	OrderSource_COUNTER OrderSource = 0
	OrderSource_WEB     OrderSource = 1
)

func (OrderSource) Descriptor

func (OrderSource) Enum

func (x OrderSource) Enum() *OrderSource

func (OrderSource) EnumDescriptor deprecated

func (OrderSource) EnumDescriptor() ([]byte, []int)

Deprecated: Use OrderSource.Descriptor instead.

func (OrderSource) Number

func (x OrderSource) Number() protoreflect.EnumNumber

func (OrderSource) String

func (x OrderSource) String() string

func (OrderSource) Type

type PlaceOrderRequest

type PlaceOrderRequest struct {
	CommandType     CommandType            `` /* 139-byte string literal not displayed */
	OrderSource     OrderSource            `` /* 139-byte string literal not displayed */
	Location        Location               `protobuf:"varint,3,opt,name=location,proto3,enum=go.coffeeshop.proto.common.Location" json:"location,omitempty"`
	LoyaltyMemberId string                 `protobuf:"bytes,4,opt,name=loyalty_member_id,json=loyaltyMemberId,proto3" json:"loyalty_member_id,omitempty"`
	BaristaItems    []*CommandItem         `protobuf:"bytes,5,rep,name=barista_items,json=baristaItems,proto3" json:"barista_items,omitempty"`
	KitchenItems    []*CommandItem         `protobuf:"bytes,6,rep,name=kitchen_items,json=kitchenItems,proto3" json:"kitchen_items,omitempty"`
	Timestamp       *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	// contains filtered or unexported fields
}

func (*PlaceOrderRequest) Descriptor deprecated

func (*PlaceOrderRequest) Descriptor() ([]byte, []int)

Deprecated: Use PlaceOrderRequest.ProtoReflect.Descriptor instead.

func (*PlaceOrderRequest) GetBaristaItems

func (x *PlaceOrderRequest) GetBaristaItems() []*CommandItem

func (*PlaceOrderRequest) GetCommandType

func (x *PlaceOrderRequest) GetCommandType() CommandType

func (*PlaceOrderRequest) GetKitchenItems

func (x *PlaceOrderRequest) GetKitchenItems() []*CommandItem

func (*PlaceOrderRequest) GetLocation

func (x *PlaceOrderRequest) GetLocation() Location

func (*PlaceOrderRequest) GetLoyaltyMemberId

func (x *PlaceOrderRequest) GetLoyaltyMemberId() string

func (*PlaceOrderRequest) GetOrderSource

func (x *PlaceOrderRequest) GetOrderSource() OrderSource

func (*PlaceOrderRequest) GetTimestamp

func (x *PlaceOrderRequest) GetTimestamp() *timestamppb.Timestamp

func (*PlaceOrderRequest) ProtoMessage

func (*PlaceOrderRequest) ProtoMessage()

func (*PlaceOrderRequest) ProtoReflect

func (x *PlaceOrderRequest) ProtoReflect() protoreflect.Message

func (*PlaceOrderRequest) Reset

func (x *PlaceOrderRequest) Reset()

func (*PlaceOrderRequest) String

func (x *PlaceOrderRequest) String() string

type PlaceOrderResponse

type PlaceOrderResponse struct {
	// contains filtered or unexported fields
}

func (*PlaceOrderResponse) Descriptor deprecated

func (*PlaceOrderResponse) Descriptor() ([]byte, []int)

Deprecated: Use PlaceOrderResponse.ProtoReflect.Descriptor instead.

func (*PlaceOrderResponse) ProtoMessage

func (*PlaceOrderResponse) ProtoMessage()

func (*PlaceOrderResponse) ProtoReflect

func (x *PlaceOrderResponse) ProtoReflect() protoreflect.Message

func (*PlaceOrderResponse) Reset

func (x *PlaceOrderResponse) Reset()

func (*PlaceOrderResponse) String

func (x *PlaceOrderResponse) String() string

type ProductServiceClient

type ProductServiceClient interface {
	GetItemTypes(ctx context.Context, in *GetItemTypesRequest, opts ...grpc.CallOption) (*GetItemTypesResponse, error)
	GetItemsByType(ctx context.Context, in *GetItemsByTypeRequest, opts ...grpc.CallOption) (*GetItemsByTypeResponse, error)
}

ProductServiceClient is the client API for ProductService 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.

type ProductServiceServer

type ProductServiceServer interface {
	GetItemTypes(context.Context, *GetItemTypesRequest) (*GetItemTypesResponse, error)
	GetItemsByType(context.Context, *GetItemsByTypeRequest) (*GetItemsByTypeResponse, error)
}

ProductServiceServer is the server API for ProductService service. All implementations should embed UnimplementedProductServiceServer for forward compatibility

type Status

type Status int32
const (
	Status_PLACED      Status = 0
	Status_IN_PROGRESS Status = 1
	Status_FULFILLED   Status = 2
)

func (Status) Descriptor

func (Status) Descriptor() protoreflect.EnumDescriptor

func (Status) Enum

func (x Status) Enum() *Status

func (Status) EnumDescriptor deprecated

func (Status) EnumDescriptor() ([]byte, []int)

Deprecated: Use Status.Descriptor instead.

func (Status) Number

func (x Status) Number() protoreflect.EnumNumber

func (Status) String

func (x Status) String() string

func (Status) Type

func (Status) Type() protoreflect.EnumType

type UnimplementedCounterServiceServer

type UnimplementedCounterServiceServer struct {
}

UnimplementedCounterServiceServer should be embedded to have forward compatible implementations.

func (UnimplementedCounterServiceServer) PlaceOrder

type UnimplementedProductServiceServer

type UnimplementedProductServiceServer struct {
}

UnimplementedProductServiceServer should be embedded to have forward compatible implementations.

func (UnimplementedProductServiceServer) GetItemTypes

func (UnimplementedProductServiceServer) GetItemsByType

type UnsafeCounterServiceServer

type UnsafeCounterServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeCounterServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to CounterServiceServer will result in compilation errors.

type UnsafeProductServiceServer

type UnsafeProductServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeProductServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ProductServiceServer will result in compilation errors.

Jump to

Keyboard shortcuts

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