Auction

package
v0.0.0-...-a323e87 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2022 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Comm_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "Auction.comm",
	HandlerType: (*CommServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Bid",
			Handler:    _Comm_Bid_Handler,
		},
		{
			MethodName: "Message",
			Handler:    _Comm_Message_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "Auction/Auction.proto",
}

Comm_ServiceDesc is the grpc.ServiceDesc for Comm 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_Auction_Auction_proto protoreflect.FileDescriptor

Functions

func RegisterCommServer

func RegisterCommServer(s grpc.ServiceRegistrar, srv CommServer)

Types

type BidAmount

type BidAmount struct {
	Id       int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Amount   int32 `protobuf:"varint,2,opt,name=amount,proto3" json:"amount,omitempty"`
	Lamptime int32 `protobuf:"varint,3,opt,name=Lamptime,proto3" json:"Lamptime,omitempty"`
	// contains filtered or unexported fields
}

func (*BidAmount) Descriptor deprecated

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

Deprecated: Use BidAmount.ProtoReflect.Descriptor instead.

func (*BidAmount) GetAmount

func (x *BidAmount) GetAmount() int32

func (*BidAmount) GetId

func (x *BidAmount) GetId() int32

func (*BidAmount) GetLamptime

func (x *BidAmount) GetLamptime() int32

func (*BidAmount) ProtoMessage

func (*BidAmount) ProtoMessage()

func (*BidAmount) ProtoReflect

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

func (*BidAmount) Reset

func (x *BidAmount) Reset()

func (*BidAmount) String

func (x *BidAmount) String() string

type CommClient

type CommClient interface {
	Bid(ctx context.Context, in *BidAmount, opts ...grpc.CallOption) (*Reply, error)
	Message(ctx context.Context, in *Request, opts ...grpc.CallOption) (*CurrentStatus, error)
}

CommClient is the client API for Comm 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 NewCommClient

func NewCommClient(cc grpc.ClientConnInterface) CommClient

type CommServer

type CommServer interface {
	Bid(context.Context, *BidAmount) (*Reply, error)
	Message(context.Context, *Request) (*CurrentStatus, error)
	// contains filtered or unexported methods
}

CommServer is the server API for Comm service. All implementations must embed UnimplementedCommServer for forward compatibility

type CurrentStatus

type CurrentStatus struct {
	Comment  string `protobuf:"bytes,1,opt,name=Comment,proto3" json:"Comment,omitempty"`
	Outcome  string `protobuf:"bytes,2,opt,name=outcome,proto3" json:"outcome,omitempty"`
	LampTime int32  `protobuf:"varint,3,opt,name=LampTime,proto3" json:"LampTime,omitempty"`
	Id       int32  `protobuf:"varint,4,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*CurrentStatus) Descriptor deprecated

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

Deprecated: Use CurrentStatus.ProtoReflect.Descriptor instead.

func (*CurrentStatus) GetComment

func (x *CurrentStatus) GetComment() string

func (*CurrentStatus) GetId

func (x *CurrentStatus) GetId() int32

func (*CurrentStatus) GetLampTime

func (x *CurrentStatus) GetLampTime() int32

func (*CurrentStatus) GetOutcome

func (x *CurrentStatus) GetOutcome() string

func (*CurrentStatus) ProtoMessage

func (*CurrentStatus) ProtoMessage()

func (*CurrentStatus) ProtoReflect

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

func (*CurrentStatus) Reset

func (x *CurrentStatus) Reset()

func (*CurrentStatus) String

func (x *CurrentStatus) String() string

type Reply

type Reply struct {
	Id         int32  `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Response   string `protobuf:"bytes,2,opt,name=response,proto3" json:"response,omitempty"`
	HighestBid int32  `protobuf:"varint,3,opt,name=highestBid,proto3" json:"highestBid,omitempty"`
	LampTime   int32  `protobuf:"varint,4,opt,name=LampTime,proto3" json:"LampTime,omitempty"`
	// contains filtered or unexported fields
}

func (*Reply) Descriptor deprecated

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

Deprecated: Use Reply.ProtoReflect.Descriptor instead.

func (*Reply) GetHighestBid

func (x *Reply) GetHighestBid() int32

func (*Reply) GetId

func (x *Reply) GetId() int32

func (*Reply) GetLampTime

func (x *Reply) GetLampTime() int32

func (*Reply) GetResponse

func (x *Reply) GetResponse() string

func (*Reply) ProtoMessage

func (*Reply) ProtoMessage()

func (*Reply) ProtoReflect

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

func (*Reply) Reset

func (x *Reply) Reset()

func (*Reply) String

func (x *Reply) String() string

type Request

type Request struct {
	Id       int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Lamptime int32 `protobuf:"varint,2,opt,name=Lamptime,proto3" json:"Lamptime,omitempty"`
	// contains filtered or unexported fields
}

func (*Request) Descriptor deprecated

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

Deprecated: Use Request.ProtoReflect.Descriptor instead.

func (*Request) GetId

func (x *Request) GetId() int32

func (*Request) GetLamptime

func (x *Request) GetLamptime() int32

func (*Request) ProtoMessage

func (*Request) ProtoMessage()

func (*Request) ProtoReflect

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

func (*Request) Reset

func (x *Request) Reset()

func (*Request) String

func (x *Request) String() string

type UnimplementedCommServer

type UnimplementedCommServer struct {
}

UnimplementedCommServer must be embedded to have forward compatible implementations.

func (UnimplementedCommServer) Bid

func (UnimplementedCommServer) Message

type UnsafeCommServer

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

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

Jump to

Keyboard shortcuts

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