Documentation ¶
Overview ¶
Package examplev1alpha1 is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Index ¶
- Variables
- func RegisterExampleServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterExampleServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ExampleServiceClient) error
- func RegisterExampleServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterExampleServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ExampleServiceServer) error
- func RegisterExampleServiceServer(s *grpc.Server, srv ExampleServiceServer)
- type Example
- func (*Example) Descriptor() ([]byte, []int)deprecated
- func (x *Example) GetGender() Example_Gender
- func (x *Example) GetId() int32
- func (x *Example) GetPurchaseDate() string
- func (*Example) ProtoMessage()
- func (x *Example) ProtoReflect() protoreflect.Message
- func (x *Example) Reset()
- func (x *Example) String() string
- func (m *Example) Validate() error
- type ExampleDeleteRequest
- func (*ExampleDeleteRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ExampleDeleteRequest) GetId() int32
- func (*ExampleDeleteRequest) ProtoMessage()
- func (x *ExampleDeleteRequest) ProtoReflect() protoreflect.Message
- func (x *ExampleDeleteRequest) Reset()
- func (x *ExampleDeleteRequest) String() string
- func (m *ExampleDeleteRequest) Validate() error
- type ExampleDeleteRequestValidationError
- func (e ExampleDeleteRequestValidationError) Cause() error
- func (e ExampleDeleteRequestValidationError) Error() string
- func (e ExampleDeleteRequestValidationError) ErrorName() string
- func (e ExampleDeleteRequestValidationError) Field() string
- func (e ExampleDeleteRequestValidationError) Key() bool
- func (e ExampleDeleteRequestValidationError) Reason() string
- type ExampleDeleteResponse
- func (*ExampleDeleteResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ExampleDeleteResponse) GetExample() *Example
- func (*ExampleDeleteResponse) ProtoMessage()
- func (x *ExampleDeleteResponse) ProtoReflect() protoreflect.Message
- func (x *ExampleDeleteResponse) Reset()
- func (x *ExampleDeleteResponse) String() string
- func (m *ExampleDeleteResponse) Validate() error
- type ExampleDeleteResponseValidationError
- func (e ExampleDeleteResponseValidationError) Cause() error
- func (e ExampleDeleteResponseValidationError) Error() string
- func (e ExampleDeleteResponseValidationError) ErrorName() string
- func (e ExampleDeleteResponseValidationError) Field() string
- func (e ExampleDeleteResponseValidationError) Key() bool
- func (e ExampleDeleteResponseValidationError) Reason() string
- type ExampleGetRequest
- type ExampleGetRequestValidationError
- func (e ExampleGetRequestValidationError) Cause() error
- func (e ExampleGetRequestValidationError) Error() string
- func (e ExampleGetRequestValidationError) ErrorName() string
- func (e ExampleGetRequestValidationError) Field() string
- func (e ExampleGetRequestValidationError) Key() bool
- func (e ExampleGetRequestValidationError) Reason() string
- type ExampleGetResponse
- func (*ExampleGetResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ExampleGetResponse) GetExample() []*Example
- func (*ExampleGetResponse) ProtoMessage()
- func (x *ExampleGetResponse) ProtoReflect() protoreflect.Message
- func (x *ExampleGetResponse) Reset()
- func (x *ExampleGetResponse) String() string
- func (m *ExampleGetResponse) Validate() error
- type ExampleGetResponseValidationError
- func (e ExampleGetResponseValidationError) Cause() error
- func (e ExampleGetResponseValidationError) Error() string
- func (e ExampleGetResponseValidationError) ErrorName() string
- func (e ExampleGetResponseValidationError) Field() string
- func (e ExampleGetResponseValidationError) Key() bool
- func (e ExampleGetResponseValidationError) Reason() string
- type ExamplePostRequest
- func (*ExamplePostRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ExamplePostRequest) GetExample() *Example
- func (*ExamplePostRequest) ProtoMessage()
- func (x *ExamplePostRequest) ProtoReflect() protoreflect.Message
- func (x *ExamplePostRequest) Reset()
- func (x *ExamplePostRequest) String() string
- func (m *ExamplePostRequest) Validate() error
- type ExamplePostRequestValidationError
- func (e ExamplePostRequestValidationError) Cause() error
- func (e ExamplePostRequestValidationError) Error() string
- func (e ExamplePostRequestValidationError) ErrorName() string
- func (e ExamplePostRequestValidationError) Field() string
- func (e ExamplePostRequestValidationError) Key() bool
- func (e ExamplePostRequestValidationError) Reason() string
- type ExamplePostResponse
- func (*ExamplePostResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ExamplePostResponse) GetExample() *Example
- func (*ExamplePostResponse) ProtoMessage()
- func (x *ExamplePostResponse) ProtoReflect() protoreflect.Message
- func (x *ExamplePostResponse) Reset()
- func (x *ExamplePostResponse) String() string
- func (m *ExamplePostResponse) Validate() error
- type ExamplePostResponseValidationError
- func (e ExamplePostResponseValidationError) Cause() error
- func (e ExamplePostResponseValidationError) Error() string
- func (e ExamplePostResponseValidationError) ErrorName() string
- func (e ExamplePostResponseValidationError) Field() string
- func (e ExamplePostResponseValidationError) Key() bool
- func (e ExamplePostResponseValidationError) Reason() string
- type ExampleServiceClient
- type ExampleServiceServer
- type ExampleValidationError
- type Example_Gender
- func (Example_Gender) Descriptor() protoreflect.EnumDescriptor
- func (x Example_Gender) Enum() *Example_Gender
- func (Example_Gender) EnumDescriptor() ([]byte, []int)deprecated
- func (x Example_Gender) Number() protoreflect.EnumNumber
- func (x Example_Gender) String() string
- func (Example_Gender) Type() protoreflect.EnumType
- type HeartbeatRequest
- type HeartbeatRequestValidationError
- func (e HeartbeatRequestValidationError) Cause() error
- func (e HeartbeatRequestValidationError) Error() string
- func (e HeartbeatRequestValidationError) ErrorName() string
- func (e HeartbeatRequestValidationError) Field() string
- func (e HeartbeatRequestValidationError) Key() bool
- func (e HeartbeatRequestValidationError) Reason() string
- type HeartbeatResponse
- type HeartbeatResponseValidationError
- func (e HeartbeatResponseValidationError) Cause() error
- func (e HeartbeatResponseValidationError) Error() string
- func (e HeartbeatResponseValidationError) ErrorName() string
- func (e HeartbeatResponseValidationError) Field() string
- func (e HeartbeatResponseValidationError) Key() bool
- func (e HeartbeatResponseValidationError) Reason() string
- type UnimplementedExampleServiceServer
- func (UnimplementedExampleServiceServer) ExampleDelete(context.Context, *ExampleDeleteRequest) (*ExampleDeleteResponse, error)
- func (UnimplementedExampleServiceServer) ExampleGet(context.Context, *ExampleGetRequest) (*ExampleGetResponse, error)
- func (UnimplementedExampleServiceServer) ExamplePost(context.Context, *ExamplePostRequest) (*ExamplePostResponse, error)
- func (UnimplementedExampleServiceServer) Heartbeat(context.Context, *HeartbeatRequest) (*HeartbeatResponse, error)
- type UnsafeExampleServiceServer
Constants ¶
This section is empty.
Variables ¶
var ( Example_Gender_name = map[int32]string{ 0: "UNSPECIFIED", 1: "MALE", 2: "FEMALE", } Example_Gender_value = map[string]int32{ "UNSPECIFIED": 0, "MALE": 1, "FEMALE": 2, } )
Enum value maps for Example_Gender.
var File_example_v1alpha1_example_proto protoreflect.FileDescriptor
Functions ¶
func RegisterExampleServiceHandler ¶
func RegisterExampleServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
RegisterExampleServiceHandler registers the http handlers for service ExampleService to "mux". The handlers forward requests to the grpc endpoint over "conn".
func RegisterExampleServiceHandlerClient ¶
func RegisterExampleServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ExampleServiceClient) error
RegisterExampleServiceHandlerClient registers the http handlers for service ExampleService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "ExampleServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "ExampleServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "ExampleServiceClient" to call the correct interceptors.
func RegisterExampleServiceHandlerFromEndpoint ¶
func RegisterExampleServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
RegisterExampleServiceHandlerFromEndpoint is same as RegisterExampleServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterExampleServiceHandlerServer ¶
func RegisterExampleServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ExampleServiceServer) error
RegisterExampleServiceHandlerServer registers the http handlers for service ExampleService to "mux". UnaryRPC :call ExampleServiceServer 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 RegisterExampleServiceHandlerFromEndpoint instead.
func RegisterExampleServiceServer ¶
func RegisterExampleServiceServer(s *grpc.Server, srv ExampleServiceServer)
Types ¶
type Example ¶
type Example struct { // The unique identifier of the example. Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // The gender of the example Gender Example_Gender `protobuf:"varint,2,opt,name=gender,proto3,enum=example.v1alpha1.Example_Gender" json:"gender,omitempty"` // The date of purchase of the example PurchaseDate string `protobuf:"bytes,3,opt,name=purchase_date,json=purchaseDate,proto3" json:"purchase_date,omitempty"` // contains filtered or unexported fields }
func (*Example) Descriptor
deprecated
func (*Example) GetGender ¶
func (x *Example) GetGender() Example_Gender
func (*Example) GetPurchaseDate ¶
func (*Example) ProtoMessage ¶
func (*Example) ProtoMessage()
func (*Example) ProtoReflect ¶
func (x *Example) ProtoReflect() protoreflect.Message
type ExampleDeleteRequest ¶
type ExampleDeleteRequest struct { // The unique identifier of the change. Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*ExampleDeleteRequest) Descriptor
deprecated
func (*ExampleDeleteRequest) Descriptor() ([]byte, []int)
Deprecated: Use ExampleDeleteRequest.ProtoReflect.Descriptor instead.
func (*ExampleDeleteRequest) GetId ¶
func (x *ExampleDeleteRequest) GetId() int32
func (*ExampleDeleteRequest) ProtoMessage ¶
func (*ExampleDeleteRequest) ProtoMessage()
func (*ExampleDeleteRequest) ProtoReflect ¶
func (x *ExampleDeleteRequest) ProtoReflect() protoreflect.Message
func (*ExampleDeleteRequest) Reset ¶
func (x *ExampleDeleteRequest) Reset()
func (*ExampleDeleteRequest) String ¶
func (x *ExampleDeleteRequest) String() string
func (*ExampleDeleteRequest) Validate ¶
func (m *ExampleDeleteRequest) Validate() error
Validate checks the field values on ExampleDeleteRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type ExampleDeleteRequestValidationError ¶
type ExampleDeleteRequestValidationError struct {
// contains filtered or unexported fields
}
ExampleDeleteRequestValidationError is the validation error returned by ExampleDeleteRequest.Validate if the designated constraints aren't met.
func (ExampleDeleteRequestValidationError) Cause ¶
func (e ExampleDeleteRequestValidationError) Cause() error
Cause function returns cause value.
func (ExampleDeleteRequestValidationError) Error ¶
func (e ExampleDeleteRequestValidationError) Error() string
Error satisfies the builtin error interface
func (ExampleDeleteRequestValidationError) ErrorName ¶
func (e ExampleDeleteRequestValidationError) ErrorName() string
ErrorName returns error name.
func (ExampleDeleteRequestValidationError) Field ¶
func (e ExampleDeleteRequestValidationError) Field() string
Field function returns field value.
func (ExampleDeleteRequestValidationError) Key ¶
func (e ExampleDeleteRequestValidationError) Key() bool
Key function returns key value.
func (ExampleDeleteRequestValidationError) Reason ¶
func (e ExampleDeleteRequestValidationError) Reason() string
Reason function returns reason value.
type ExampleDeleteResponse ¶
type ExampleDeleteResponse struct { // The deleted example Example *Example `protobuf:"bytes,1,opt,name=example,proto3" json:"example,omitempty"` // contains filtered or unexported fields }
func (*ExampleDeleteResponse) Descriptor
deprecated
func (*ExampleDeleteResponse) Descriptor() ([]byte, []int)
Deprecated: Use ExampleDeleteResponse.ProtoReflect.Descriptor instead.
func (*ExampleDeleteResponse) GetExample ¶
func (x *ExampleDeleteResponse) GetExample() *Example
func (*ExampleDeleteResponse) ProtoMessage ¶
func (*ExampleDeleteResponse) ProtoMessage()
func (*ExampleDeleteResponse) ProtoReflect ¶
func (x *ExampleDeleteResponse) ProtoReflect() protoreflect.Message
func (*ExampleDeleteResponse) Reset ¶
func (x *ExampleDeleteResponse) Reset()
func (*ExampleDeleteResponse) String ¶
func (x *ExampleDeleteResponse) String() string
func (*ExampleDeleteResponse) Validate ¶
func (m *ExampleDeleteResponse) Validate() error
Validate checks the field values on ExampleDeleteResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type ExampleDeleteResponseValidationError ¶
type ExampleDeleteResponseValidationError struct {
// contains filtered or unexported fields
}
ExampleDeleteResponseValidationError is the validation error returned by ExampleDeleteResponse.Validate if the designated constraints aren't met.
func (ExampleDeleteResponseValidationError) Cause ¶
func (e ExampleDeleteResponseValidationError) Cause() error
Cause function returns cause value.
func (ExampleDeleteResponseValidationError) Error ¶
func (e ExampleDeleteResponseValidationError) Error() string
Error satisfies the builtin error interface
func (ExampleDeleteResponseValidationError) ErrorName ¶
func (e ExampleDeleteResponseValidationError) ErrorName() string
ErrorName returns error name.
func (ExampleDeleteResponseValidationError) Field ¶
func (e ExampleDeleteResponseValidationError) Field() string
Field function returns field value.
func (ExampleDeleteResponseValidationError) Key ¶
func (e ExampleDeleteResponseValidationError) Key() bool
Key function returns key value.
func (ExampleDeleteResponseValidationError) Reason ¶
func (e ExampleDeleteResponseValidationError) Reason() string
Reason function returns reason value.
type ExampleGetRequest ¶
type ExampleGetRequest struct {
// contains filtered or unexported fields
}
func (*ExampleGetRequest) Descriptor
deprecated
func (*ExampleGetRequest) Descriptor() ([]byte, []int)
Deprecated: Use ExampleGetRequest.ProtoReflect.Descriptor instead.
func (*ExampleGetRequest) ProtoMessage ¶
func (*ExampleGetRequest) ProtoMessage()
func (*ExampleGetRequest) ProtoReflect ¶
func (x *ExampleGetRequest) ProtoReflect() protoreflect.Message
func (*ExampleGetRequest) Reset ¶
func (x *ExampleGetRequest) Reset()
func (*ExampleGetRequest) String ¶
func (x *ExampleGetRequest) String() string
func (*ExampleGetRequest) Validate ¶
func (m *ExampleGetRequest) Validate() error
Validate checks the field values on ExampleGetRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type ExampleGetRequestValidationError ¶
type ExampleGetRequestValidationError struct {
// contains filtered or unexported fields
}
ExampleGetRequestValidationError is the validation error returned by ExampleGetRequest.Validate if the designated constraints aren't met.
func (ExampleGetRequestValidationError) Cause ¶
func (e ExampleGetRequestValidationError) Cause() error
Cause function returns cause value.
func (ExampleGetRequestValidationError) Error ¶
func (e ExampleGetRequestValidationError) Error() string
Error satisfies the builtin error interface
func (ExampleGetRequestValidationError) ErrorName ¶
func (e ExampleGetRequestValidationError) ErrorName() string
ErrorName returns error name.
func (ExampleGetRequestValidationError) Field ¶
func (e ExampleGetRequestValidationError) Field() string
Field function returns field value.
func (ExampleGetRequestValidationError) Key ¶
func (e ExampleGetRequestValidationError) Key() bool
Key function returns key value.
func (ExampleGetRequestValidationError) Reason ¶
func (e ExampleGetRequestValidationError) Reason() string
Reason function returns reason value.
type ExampleGetResponse ¶
type ExampleGetResponse struct { // The list of example Example []*Example `protobuf:"bytes,1,rep,name=example,proto3" json:"example,omitempty"` // contains filtered or unexported fields }
func (*ExampleGetResponse) Descriptor
deprecated
func (*ExampleGetResponse) Descriptor() ([]byte, []int)
Deprecated: Use ExampleGetResponse.ProtoReflect.Descriptor instead.
func (*ExampleGetResponse) GetExample ¶
func (x *ExampleGetResponse) GetExample() []*Example
func (*ExampleGetResponse) ProtoMessage ¶
func (*ExampleGetResponse) ProtoMessage()
func (*ExampleGetResponse) ProtoReflect ¶
func (x *ExampleGetResponse) ProtoReflect() protoreflect.Message
func (*ExampleGetResponse) Reset ¶
func (x *ExampleGetResponse) Reset()
func (*ExampleGetResponse) String ¶
func (x *ExampleGetResponse) String() string
func (*ExampleGetResponse) Validate ¶
func (m *ExampleGetResponse) Validate() error
Validate checks the field values on ExampleGetResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type ExampleGetResponseValidationError ¶
type ExampleGetResponseValidationError struct {
// contains filtered or unexported fields
}
ExampleGetResponseValidationError is the validation error returned by ExampleGetResponse.Validate if the designated constraints aren't met.
func (ExampleGetResponseValidationError) Cause ¶
func (e ExampleGetResponseValidationError) Cause() error
Cause function returns cause value.
func (ExampleGetResponseValidationError) Error ¶
func (e ExampleGetResponseValidationError) Error() string
Error satisfies the builtin error interface
func (ExampleGetResponseValidationError) ErrorName ¶
func (e ExampleGetResponseValidationError) ErrorName() string
ErrorName returns error name.
func (ExampleGetResponseValidationError) Field ¶
func (e ExampleGetResponseValidationError) Field() string
Field function returns field value.
func (ExampleGetResponseValidationError) Key ¶
func (e ExampleGetResponseValidationError) Key() bool
Key function returns key value.
func (ExampleGetResponseValidationError) Reason ¶
func (e ExampleGetResponseValidationError) Reason() string
Reason function returns reason value.
type ExamplePostRequest ¶
type ExamplePostRequest struct { // The example to add Example *Example `protobuf:"bytes,1,opt,name=example,proto3" json:"example,omitempty"` // contains filtered or unexported fields }
func (*ExamplePostRequest) Descriptor
deprecated
func (*ExamplePostRequest) Descriptor() ([]byte, []int)
Deprecated: Use ExamplePostRequest.ProtoReflect.Descriptor instead.
func (*ExamplePostRequest) GetExample ¶
func (x *ExamplePostRequest) GetExample() *Example
func (*ExamplePostRequest) ProtoMessage ¶
func (*ExamplePostRequest) ProtoMessage()
func (*ExamplePostRequest) ProtoReflect ¶
func (x *ExamplePostRequest) ProtoReflect() protoreflect.Message
func (*ExamplePostRequest) Reset ¶
func (x *ExamplePostRequest) Reset()
func (*ExamplePostRequest) String ¶
func (x *ExamplePostRequest) String() string
func (*ExamplePostRequest) Validate ¶
func (m *ExamplePostRequest) Validate() error
Validate checks the field values on ExamplePostRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type ExamplePostRequestValidationError ¶
type ExamplePostRequestValidationError struct {
// contains filtered or unexported fields
}
ExamplePostRequestValidationError is the validation error returned by ExamplePostRequest.Validate if the designated constraints aren't met.
func (ExamplePostRequestValidationError) Cause ¶
func (e ExamplePostRequestValidationError) Cause() error
Cause function returns cause value.
func (ExamplePostRequestValidationError) Error ¶
func (e ExamplePostRequestValidationError) Error() string
Error satisfies the builtin error interface
func (ExamplePostRequestValidationError) ErrorName ¶
func (e ExamplePostRequestValidationError) ErrorName() string
ErrorName returns error name.
func (ExamplePostRequestValidationError) Field ¶
func (e ExamplePostRequestValidationError) Field() string
Field function returns field value.
func (ExamplePostRequestValidationError) Key ¶
func (e ExamplePostRequestValidationError) Key() bool
Key function returns key value.
func (ExamplePostRequestValidationError) Reason ¶
func (e ExamplePostRequestValidationError) Reason() string
Reason function returns reason value.
type ExamplePostResponse ¶
type ExamplePostResponse struct { // The added example Example *Example `protobuf:"bytes,1,opt,name=example,proto3" json:"example,omitempty"` // contains filtered or unexported fields }
func (*ExamplePostResponse) Descriptor
deprecated
func (*ExamplePostResponse) Descriptor() ([]byte, []int)
Deprecated: Use ExamplePostResponse.ProtoReflect.Descriptor instead.
func (*ExamplePostResponse) GetExample ¶
func (x *ExamplePostResponse) GetExample() *Example
func (*ExamplePostResponse) ProtoMessage ¶
func (*ExamplePostResponse) ProtoMessage()
func (*ExamplePostResponse) ProtoReflect ¶
func (x *ExamplePostResponse) ProtoReflect() protoreflect.Message
func (*ExamplePostResponse) Reset ¶
func (x *ExamplePostResponse) Reset()
func (*ExamplePostResponse) String ¶
func (x *ExamplePostResponse) String() string
func (*ExamplePostResponse) Validate ¶
func (m *ExamplePostResponse) Validate() error
Validate checks the field values on ExamplePostResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type ExamplePostResponseValidationError ¶
type ExamplePostResponseValidationError struct {
// contains filtered or unexported fields
}
ExamplePostResponseValidationError is the validation error returned by ExamplePostResponse.Validate if the designated constraints aren't met.
func (ExamplePostResponseValidationError) Cause ¶
func (e ExamplePostResponseValidationError) Cause() error
Cause function returns cause value.
func (ExamplePostResponseValidationError) Error ¶
func (e ExamplePostResponseValidationError) Error() string
Error satisfies the builtin error interface
func (ExamplePostResponseValidationError) ErrorName ¶
func (e ExamplePostResponseValidationError) ErrorName() string
ErrorName returns error name.
func (ExamplePostResponseValidationError) Field ¶
func (e ExamplePostResponseValidationError) Field() string
Field function returns field value.
func (ExamplePostResponseValidationError) Key ¶
func (e ExamplePostResponseValidationError) Key() bool
Key function returns key value.
func (ExamplePostResponseValidationError) Reason ¶
func (e ExamplePostResponseValidationError) Reason() string
Reason function returns reason value.
type ExampleServiceClient ¶
type ExampleServiceClient interface { // Heartbeat // // Provides information about the service health Heartbeat(ctx context.Context, in *HeartbeatRequest, opts ...grpc.CallOption) (*HeartbeatResponse, error) // ExamplePost // // Sets up a POST endpoint ExamplePost(ctx context.Context, in *ExamplePostRequest, opts ...grpc.CallOption) (*ExamplePostResponse, error) // ExampleGet // // Sets up a GET endpoint ExampleGet(ctx context.Context, in *ExampleGetRequest, opts ...grpc.CallOption) (*ExampleGetResponse, error) // ExampleDelete // // Sets up a DELETE endpoint ExampleDelete(ctx context.Context, in *ExampleDeleteRequest, opts ...grpc.CallOption) (*ExampleDeleteResponse, error) }
ExampleServiceClient is the client API for ExampleService 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 NewExampleServiceClient ¶
func NewExampleServiceClient(cc grpc.ClientConnInterface) ExampleServiceClient
type ExampleServiceServer ¶
type ExampleServiceServer interface { // Heartbeat // // Provides information about the service health Heartbeat(context.Context, *HeartbeatRequest) (*HeartbeatResponse, error) // ExamplePost // // Sets up a POST endpoint ExamplePost(context.Context, *ExamplePostRequest) (*ExamplePostResponse, error) // ExampleGet // // Sets up a GET endpoint ExampleGet(context.Context, *ExampleGetRequest) (*ExampleGetResponse, error) // ExampleDelete // // Sets up a DELETE endpoint ExampleDelete(context.Context, *ExampleDeleteRequest) (*ExampleDeleteResponse, error) }
ExampleServiceServer is the server API for ExampleService service. All implementations should embed UnimplementedExampleServiceServer for forward compatibility
type ExampleValidationError ¶
type ExampleValidationError struct {
// contains filtered or unexported fields
}
ExampleValidationError is the validation error returned by Example.Validate if the designated constraints aren't met.
func (ExampleValidationError) Cause ¶
func (e ExampleValidationError) Cause() error
Cause function returns cause value.
func (ExampleValidationError) Error ¶
func (e ExampleValidationError) Error() string
Error satisfies the builtin error interface
func (ExampleValidationError) ErrorName ¶
func (e ExampleValidationError) ErrorName() string
ErrorName returns error name.
func (ExampleValidationError) Field ¶
func (e ExampleValidationError) Field() string
Field function returns field value.
func (ExampleValidationError) Key ¶
func (e ExampleValidationError) Key() bool
Key function returns key value.
func (ExampleValidationError) Reason ¶
func (e ExampleValidationError) Reason() string
Reason function returns reason value.
type Example_Gender ¶
type Example_Gender int32
const ( Example_UNSPECIFIED Example_Gender = 0 Example_MALE Example_Gender = 1 Example_FEMALE Example_Gender = 2 )
func (Example_Gender) Descriptor ¶
func (Example_Gender) Descriptor() protoreflect.EnumDescriptor
func (Example_Gender) Enum ¶
func (x Example_Gender) Enum() *Example_Gender
func (Example_Gender) EnumDescriptor
deprecated
func (Example_Gender) EnumDescriptor() ([]byte, []int)
Deprecated: Use Example_Gender.Descriptor instead.
func (Example_Gender) Number ¶
func (x Example_Gender) Number() protoreflect.EnumNumber
func (Example_Gender) String ¶
func (x Example_Gender) String() string
func (Example_Gender) Type ¶
func (Example_Gender) Type() protoreflect.EnumType
type HeartbeatRequest ¶
type HeartbeatRequest struct {
// contains filtered or unexported fields
}
func (*HeartbeatRequest) Descriptor
deprecated
func (*HeartbeatRequest) Descriptor() ([]byte, []int)
Deprecated: Use HeartbeatRequest.ProtoReflect.Descriptor instead.
func (*HeartbeatRequest) ProtoMessage ¶
func (*HeartbeatRequest) ProtoMessage()
func (*HeartbeatRequest) ProtoReflect ¶
func (x *HeartbeatRequest) ProtoReflect() protoreflect.Message
func (*HeartbeatRequest) Reset ¶
func (x *HeartbeatRequest) Reset()
func (*HeartbeatRequest) String ¶
func (x *HeartbeatRequest) String() string
func (*HeartbeatRequest) Validate ¶
func (m *HeartbeatRequest) Validate() error
Validate checks the field values on HeartbeatRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type HeartbeatRequestValidationError ¶
type HeartbeatRequestValidationError struct {
// contains filtered or unexported fields
}
HeartbeatRequestValidationError is the validation error returned by HeartbeatRequest.Validate if the designated constraints aren't met.
func (HeartbeatRequestValidationError) Cause ¶
func (e HeartbeatRequestValidationError) Cause() error
Cause function returns cause value.
func (HeartbeatRequestValidationError) Error ¶
func (e HeartbeatRequestValidationError) Error() string
Error satisfies the builtin error interface
func (HeartbeatRequestValidationError) ErrorName ¶
func (e HeartbeatRequestValidationError) ErrorName() string
ErrorName returns error name.
func (HeartbeatRequestValidationError) Field ¶
func (e HeartbeatRequestValidationError) Field() string
Field function returns field value.
func (HeartbeatRequestValidationError) Key ¶
func (e HeartbeatRequestValidationError) Key() bool
Key function returns key value.
func (HeartbeatRequestValidationError) Reason ¶
func (e HeartbeatRequestValidationError) Reason() string
Reason function returns reason value.
type HeartbeatResponse ¶
type HeartbeatResponse struct {
// contains filtered or unexported fields
}
func (*HeartbeatResponse) Descriptor
deprecated
func (*HeartbeatResponse) Descriptor() ([]byte, []int)
Deprecated: Use HeartbeatResponse.ProtoReflect.Descriptor instead.
func (*HeartbeatResponse) ProtoMessage ¶
func (*HeartbeatResponse) ProtoMessage()
func (*HeartbeatResponse) ProtoReflect ¶
func (x *HeartbeatResponse) ProtoReflect() protoreflect.Message
func (*HeartbeatResponse) Reset ¶
func (x *HeartbeatResponse) Reset()
func (*HeartbeatResponse) String ¶
func (x *HeartbeatResponse) String() string
func (*HeartbeatResponse) Validate ¶
func (m *HeartbeatResponse) Validate() error
Validate checks the field values on HeartbeatResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.
type HeartbeatResponseValidationError ¶
type HeartbeatResponseValidationError struct {
// contains filtered or unexported fields
}
HeartbeatResponseValidationError is the validation error returned by HeartbeatResponse.Validate if the designated constraints aren't met.
func (HeartbeatResponseValidationError) Cause ¶
func (e HeartbeatResponseValidationError) Cause() error
Cause function returns cause value.
func (HeartbeatResponseValidationError) Error ¶
func (e HeartbeatResponseValidationError) Error() string
Error satisfies the builtin error interface
func (HeartbeatResponseValidationError) ErrorName ¶
func (e HeartbeatResponseValidationError) ErrorName() string
ErrorName returns error name.
func (HeartbeatResponseValidationError) Field ¶
func (e HeartbeatResponseValidationError) Field() string
Field function returns field value.
func (HeartbeatResponseValidationError) Key ¶
func (e HeartbeatResponseValidationError) Key() bool
Key function returns key value.
func (HeartbeatResponseValidationError) Reason ¶
func (e HeartbeatResponseValidationError) Reason() string
Reason function returns reason value.
type UnimplementedExampleServiceServer ¶
type UnimplementedExampleServiceServer struct { }
UnimplementedExampleServiceServer should be embedded to have forward compatible implementations.
func (UnimplementedExampleServiceServer) ExampleDelete ¶
func (UnimplementedExampleServiceServer) ExampleDelete(context.Context, *ExampleDeleteRequest) (*ExampleDeleteResponse, error)
func (UnimplementedExampleServiceServer) ExampleGet ¶
func (UnimplementedExampleServiceServer) ExampleGet(context.Context, *ExampleGetRequest) (*ExampleGetResponse, error)
func (UnimplementedExampleServiceServer) ExamplePost ¶
func (UnimplementedExampleServiceServer) ExamplePost(context.Context, *ExamplePostRequest) (*ExamplePostResponse, error)
func (UnimplementedExampleServiceServer) Heartbeat ¶
func (UnimplementedExampleServiceServer) Heartbeat(context.Context, *HeartbeatRequest) (*HeartbeatResponse, error)
type UnsafeExampleServiceServer ¶
type UnsafeExampleServiceServer interface {
// contains filtered or unexported methods
}
UnsafeExampleServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ExampleServiceServer will result in compilation errors.