proto

package
v0.1.0-alpha1 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2020 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var GreetRequestJSONMarshaler = new(jsonpb.Marshaler)

GreetRequestJSONMarshaler describes the default jsonpb.Marshaler used by all instances of GreetRequest. This struct is safe to replace or modify but should not be done so concurrently.

View Source
var GreetRequestJSONUnmarshaler = new(jsonpb.Unmarshaler)

GreetRequestJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all instances of GreetRequest. This struct is safe to replace or modify but should not be done so concurrently.

View Source
var GreetResponseJSONMarshaler = new(jsonpb.Marshaler)

GreetResponseJSONMarshaler describes the default jsonpb.Marshaler used by all instances of GreetResponse. This struct is safe to replace or modify but should not be done so concurrently.

View Source
var GreetResponseJSONUnmarshaler = new(jsonpb.Unmarshaler)

GreetResponseJSONUnmarshaler describes the default jsonpb.Unmarshaler used by all instances of GreetResponse. This struct is safe to replace or modify but should not be done so concurrently.

Functions

func RegisterHelloHandler

func RegisterHelloHandler(s server.Server, hdlr HelloHandler, opts ...server.HandlerOption) error

func RegisterHelloWeb

func RegisterHelloWeb(r chi.Router, i HelloHandler, middlewares ...func(http.Handler) http.Handler)

Types

type GreetRequest

type GreetRequest 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 (*GreetRequest) Descriptor

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

func (*GreetRequest) GetName

func (m *GreetRequest) GetName() string

func (*GreetRequest) MarshalJSON

func (m *GreetRequest) MarshalJSON() ([]byte, error)

MarshalJSON satisfies the encoding/json Marshaler interface. This method uses the more correct jsonpb package to correctly marshal the message.

func (*GreetRequest) ProtoMessage

func (*GreetRequest) ProtoMessage()

func (*GreetRequest) Reset

func (m *GreetRequest) Reset()

func (*GreetRequest) String

func (m *GreetRequest) String() string

func (*GreetRequest) UnmarshalJSON

func (m *GreetRequest) UnmarshalJSON(b []byte) error

UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method uses the more correct jsonpb package to correctly unmarshal the message.

func (*GreetRequest) XXX_DiscardUnknown

func (m *GreetRequest) XXX_DiscardUnknown()

func (*GreetRequest) XXX_Marshal

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

func (*GreetRequest) XXX_Merge

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

func (*GreetRequest) XXX_Size

func (m *GreetRequest) XXX_Size() int

func (*GreetRequest) XXX_Unmarshal

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

type GreetResponse

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

func (*GreetResponse) Descriptor

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

func (*GreetResponse) GetErr

func (m *GreetResponse) GetErr() string

func (*GreetResponse) GetMessage

func (m *GreetResponse) GetMessage() string

func (*GreetResponse) MarshalJSON

func (m *GreetResponse) MarshalJSON() ([]byte, error)

MarshalJSON satisfies the encoding/json Marshaler interface. This method uses the more correct jsonpb package to correctly marshal the message.

func (*GreetResponse) ProtoMessage

func (*GreetResponse) ProtoMessage()

func (*GreetResponse) Reset

func (m *GreetResponse) Reset()

func (*GreetResponse) String

func (m *GreetResponse) String() string

func (*GreetResponse) UnmarshalJSON

func (m *GreetResponse) UnmarshalJSON(b []byte) error

UnmarshalJSON satisfies the encoding/json Unmarshaler interface. This method uses the more correct jsonpb package to correctly unmarshal the message.

func (*GreetResponse) XXX_DiscardUnknown

func (m *GreetResponse) XXX_DiscardUnknown()

func (*GreetResponse) XXX_Marshal

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

func (*GreetResponse) XXX_Merge

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

func (*GreetResponse) XXX_Size

func (m *GreetResponse) XXX_Size() int

func (*GreetResponse) XXX_Unmarshal

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

type HelloHandler

type HelloHandler interface {
	Greet(context.Context, *GreetRequest, *GreetResponse) error
}

type HelloService

type HelloService interface {
	Greet(ctx context.Context, in *GreetRequest, opts ...client.CallOption) (*GreetResponse, error)
}

func NewHelloService

func NewHelloService(name string, c client.Client) HelloService

Jump to

Keyboard shortcuts

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