protov1

package
v0.0.0-...-74c7ceb Latest Latest
Warning

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

Go to latest
Published: Sep 1, 2021 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthGreeter = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowGreeter   = fmt.Errorf("proto: integer overflow")
)

Functions

func RegisterGreeterServiceServer

func RegisterGreeterServiceServer(s *grpc.Server, srv GreeterServiceServer)

Types

type GreeterServiceClient

type GreeterServiceClient interface {
	SayHello(ctx context.Context, in *HelloRequest, opts ...grpc.CallOption) (*HelloReply, error)
	SayTime(ctx context.Context, in *types.Empty, opts ...grpc.CallOption) (*types.Timestamp, error)
	SubscribeTime(ctx context.Context, in *TimeRequest, opts ...grpc.CallOption) (GreeterService_SubscribeTimeClient, error)
}

GreeterServiceClient is the client API for GreeterService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewGreeterServiceClient

func NewGreeterServiceClient(cc *grpc.ClientConn) GreeterServiceClient

type GreeterServiceServer

type GreeterServiceServer interface {
	SayHello(context.Context, *HelloRequest) (*HelloReply, error)
	SayTime(context.Context, *types.Empty) (*types.Timestamp, error)
	SubscribeTime(*TimeRequest, GreeterService_SubscribeTimeServer) error
}

GreeterServiceServer is the server API for GreeterService service.

type GreeterService_SubscribeTimeClient

type GreeterService_SubscribeTimeClient interface {
	Recv() (*types.Timestamp, error)
	grpc.ClientStream
}

type GreeterService_SubscribeTimeServer

type GreeterService_SubscribeTimeServer interface {
	Send(*types.Timestamp) error
	grpc.ServerStream
}

type HelloReply

type HelloReply struct {
	Message              string   `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*HelloReply) Descriptor

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

func (*HelloReply) GetMessage

func (m *HelloReply) GetMessage() string

func (*HelloReply) Marshal

func (m *HelloReply) Marshal() (dAtA []byte, err error)

func (*HelloReply) MarshalTo

func (m *HelloReply) MarshalTo(dAtA []byte) (int, error)

func (*HelloReply) ProtoMessage

func (*HelloReply) ProtoMessage()

func (*HelloReply) Reset

func (m *HelloReply) Reset()

func (*HelloReply) Size

func (m *HelloReply) Size() (n int)

func (*HelloReply) String

func (m *HelloReply) String() string

func (*HelloReply) Unmarshal

func (m *HelloReply) Unmarshal(dAtA []byte) error

func (*HelloReply) Validate

func (m *HelloReply) Validate() error

Validate checks the field values on HelloReply with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

func (*HelloReply) XXX_DiscardUnknown

func (m *HelloReply) XXX_DiscardUnknown()

func (*HelloReply) XXX_Marshal

func (m *HelloReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*HelloReply) XXX_Merge

func (m *HelloReply) XXX_Merge(src proto.Message)

func (*HelloReply) XXX_MessageName

func (*HelloReply) XXX_MessageName() string

func (*HelloReply) XXX_Size

func (m *HelloReply) XXX_Size() int

func (*HelloReply) XXX_Unmarshal

func (m *HelloReply) XXX_Unmarshal(b []byte) error

type HelloReplyValidationError

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

HelloReplyValidationError is the validation error returned by HelloReply.Validate if the designated constraints aren't met.

func (HelloReplyValidationError) Cause

func (e HelloReplyValidationError) Cause() error

Cause function returns cause value.

func (HelloReplyValidationError) Error

Error satisfies the builtin error interface

func (HelloReplyValidationError) ErrorName

func (e HelloReplyValidationError) ErrorName() string

ErrorName returns error name.

func (HelloReplyValidationError) Field

Field function returns field value.

func (HelloReplyValidationError) Key

Key function returns key value.

func (HelloReplyValidationError) Reason

func (e HelloReplyValidationError) Reason() string

Reason function returns reason value.

type HelloRequest

type HelloRequest struct {
	Name                 string   `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*HelloRequest) Descriptor

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

func (*HelloRequest) GetName

func (m *HelloRequest) GetName() string

func (*HelloRequest) Marshal

func (m *HelloRequest) Marshal() (dAtA []byte, err error)

func (*HelloRequest) MarshalTo

func (m *HelloRequest) MarshalTo(dAtA []byte) (int, error)

func (*HelloRequest) ProtoMessage

func (*HelloRequest) ProtoMessage()

func (*HelloRequest) Reset

func (m *HelloRequest) Reset()

func (*HelloRequest) Size

func (m *HelloRequest) Size() (n int)

func (*HelloRequest) String

func (m *HelloRequest) String() string

func (*HelloRequest) Unmarshal

func (m *HelloRequest) Unmarshal(dAtA []byte) error

func (*HelloRequest) Validate

func (m *HelloRequest) Validate() error

Validate checks the field values on HelloRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

func (*HelloRequest) XXX_DiscardUnknown

func (m *HelloRequest) XXX_DiscardUnknown()

func (*HelloRequest) XXX_Marshal

func (m *HelloRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*HelloRequest) XXX_Merge

func (m *HelloRequest) XXX_Merge(src proto.Message)

func (*HelloRequest) XXX_MessageName

func (*HelloRequest) XXX_MessageName() string

func (*HelloRequest) XXX_Size

func (m *HelloRequest) XXX_Size() int

func (*HelloRequest) XXX_Unmarshal

func (m *HelloRequest) XXX_Unmarshal(b []byte) error

type HelloRequestValidationError

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

HelloRequestValidationError is the validation error returned by HelloRequest.Validate if the designated constraints aren't met.

func (HelloRequestValidationError) Cause

Cause function returns cause value.

func (HelloRequestValidationError) Error

Error satisfies the builtin error interface

func (HelloRequestValidationError) ErrorName

func (e HelloRequestValidationError) ErrorName() string

ErrorName returns error name.

func (HelloRequestValidationError) Field

Field function returns field value.

func (HelloRequestValidationError) Key

Key function returns key value.

func (HelloRequestValidationError) Reason

Reason function returns reason value.

type TimeRequest

type TimeRequest struct {
	Count                int32           `protobuf:"varint,1,opt,name=count,proto3" json:"count,omitempty"`
	Interval             *types.Duration `protobuf:"bytes,2,opt,name=interval,proto3" json:"interval,omitempty"`
	XXX_NoUnkeyedLiteral struct{}        `json:"-"`
	XXX_unrecognized     []byte          `json:"-"`
	XXX_sizecache        int32           `json:"-"`
}

func (*TimeRequest) Descriptor

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

func (*TimeRequest) GetCount

func (m *TimeRequest) GetCount() int32

func (*TimeRequest) GetInterval

func (m *TimeRequest) GetInterval() *types.Duration

func (*TimeRequest) Marshal

func (m *TimeRequest) Marshal() (dAtA []byte, err error)

func (*TimeRequest) MarshalTo

func (m *TimeRequest) MarshalTo(dAtA []byte) (int, error)

func (*TimeRequest) ProtoMessage

func (*TimeRequest) ProtoMessage()

func (*TimeRequest) Reset

func (m *TimeRequest) Reset()

func (*TimeRequest) Size

func (m *TimeRequest) Size() (n int)

func (*TimeRequest) String

func (m *TimeRequest) String() string

func (*TimeRequest) Unmarshal

func (m *TimeRequest) Unmarshal(dAtA []byte) error

func (*TimeRequest) Validate

func (m *TimeRequest) Validate() error

Validate checks the field values on TimeRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

func (*TimeRequest) XXX_DiscardUnknown

func (m *TimeRequest) XXX_DiscardUnknown()

func (*TimeRequest) XXX_Marshal

func (m *TimeRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TimeRequest) XXX_Merge

func (m *TimeRequest) XXX_Merge(src proto.Message)

func (*TimeRequest) XXX_MessageName

func (*TimeRequest) XXX_MessageName() string

func (*TimeRequest) XXX_Size

func (m *TimeRequest) XXX_Size() int

func (*TimeRequest) XXX_Unmarshal

func (m *TimeRequest) XXX_Unmarshal(b []byte) error

type TimeRequestValidationError

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

TimeRequestValidationError is the validation error returned by TimeRequest.Validate if the designated constraints aren't met.

func (TimeRequestValidationError) Cause

Cause function returns cause value.

func (TimeRequestValidationError) Error

Error satisfies the builtin error interface

func (TimeRequestValidationError) ErrorName

func (e TimeRequestValidationError) ErrorName() string

ErrorName returns error name.

func (TimeRequestValidationError) Field

Field function returns field value.

func (TimeRequestValidationError) Key

Key function returns key value.

func (TimeRequestValidationError) Reason

Reason function returns reason value.

Jump to

Keyboard shortcuts

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