Documentation
¶
Index ¶
- func RegisterCacheServer(s *grpc.Server, srv CacheServer)
- type CacheClient
- type CacheServer
- type GetReply
- func (*GetReply) Descriptor() ([]byte, []int)
- func (m *GetReply) GetExists() bool
- func (m *GetReply) GetValue() []byte
- func (*GetReply) ProtoMessage()
- func (m *GetReply) Reset()
- func (m *GetReply) String() string
- func (m *GetReply) XXX_DiscardUnknown()
- func (m *GetReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GetReply) XXX_Merge(src proto.Message)
- func (m *GetReply) XXX_Size() int
- func (m *GetReply) XXX_Unmarshal(b []byte) error
- type GetRequest
- func (*GetRequest) Descriptor() ([]byte, []int)
- func (m *GetRequest) GetKey() string
- func (*GetRequest) ProtoMessage()
- func (m *GetRequest) Reset()
- func (m *GetRequest) String() string
- func (m *GetRequest) XXX_DiscardUnknown()
- func (m *GetRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GetRequest) XXX_Merge(src proto.Message)
- func (m *GetRequest) XXX_Size() int
- func (m *GetRequest) XXX_Unmarshal(b []byte) error
- type SetReply
- func (*SetReply) Descriptor() ([]byte, []int)
- func (*SetReply) ProtoMessage()
- func (m *SetReply) Reset()
- func (m *SetReply) String() string
- func (m *SetReply) XXX_DiscardUnknown()
- func (m *SetReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SetReply) XXX_Merge(src proto.Message)
- func (m *SetReply) XXX_Size() int
- func (m *SetReply) XXX_Unmarshal(b []byte) error
- type SetRequest
- func (*SetRequest) Descriptor() ([]byte, []int)
- func (m *SetRequest) GetKey() string
- func (m *SetRequest) GetValue() []byte
- func (*SetRequest) ProtoMessage()
- func (m *SetRequest) Reset()
- func (m *SetRequest) String() string
- func (m *SetRequest) XXX_DiscardUnknown()
- func (m *SetRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SetRequest) XXX_Merge(src proto.Message)
- func (m *SetRequest) XXX_Size() int
- func (m *SetRequest) XXX_Unmarshal(b []byte) error
- type UnimplementedCacheServer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterCacheServer ¶
func RegisterCacheServer(s *grpc.Server, srv CacheServer)
Types ¶
type CacheClient ¶
type CacheClient interface { Get(ctx context.Context, in *GetRequest, opts ...grpc.CallOption) (*GetReply, error) Set(ctx context.Context, in *SetRequest, opts ...grpc.CallOption) (*SetReply, error) }
CacheClient is the client API for Cache service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewCacheClient ¶
func NewCacheClient(cc grpc.ClientConnInterface) CacheClient
type CacheServer ¶
type CacheServer interface { Get(context.Context, *GetRequest) (*GetReply, error) Set(context.Context, *SetRequest) (*SetReply, error) }
CacheServer is the server API for Cache service.
type GetReply ¶
type GetReply struct { Exists bool `protobuf:"varint,1,opt,name=exists,proto3" json:"exists,omitempty"` Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*GetReply) Descriptor ¶
func (*GetReply) ProtoMessage ¶
func (*GetReply) ProtoMessage()
func (*GetReply) XXX_DiscardUnknown ¶
func (m *GetReply) XXX_DiscardUnknown()
func (*GetReply) XXX_Marshal ¶
func (*GetReply) XXX_Unmarshal ¶
type GetRequest ¶
type GetRequest struct { Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*GetRequest) Descriptor ¶
func (*GetRequest) Descriptor() ([]byte, []int)
func (*GetRequest) GetKey ¶
func (m *GetRequest) GetKey() string
func (*GetRequest) ProtoMessage ¶
func (*GetRequest) ProtoMessage()
func (*GetRequest) Reset ¶
func (m *GetRequest) Reset()
func (*GetRequest) String ¶
func (m *GetRequest) String() string
func (*GetRequest) XXX_DiscardUnknown ¶
func (m *GetRequest) XXX_DiscardUnknown()
func (*GetRequest) XXX_Marshal ¶
func (m *GetRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GetRequest) XXX_Merge ¶
func (m *GetRequest) XXX_Merge(src proto.Message)
func (*GetRequest) XXX_Size ¶
func (m *GetRequest) XXX_Size() int
func (*GetRequest) XXX_Unmarshal ¶
func (m *GetRequest) XXX_Unmarshal(b []byte) error
type SetReply ¶
type SetReply struct { XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SetReply) Descriptor ¶
func (*SetReply) ProtoMessage ¶
func (*SetReply) ProtoMessage()
func (*SetReply) XXX_DiscardUnknown ¶
func (m *SetReply) XXX_DiscardUnknown()
func (*SetReply) XXX_Marshal ¶
func (*SetReply) XXX_Unmarshal ¶
type SetRequest ¶
type SetRequest struct { Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*SetRequest) Descriptor ¶
func (*SetRequest) Descriptor() ([]byte, []int)
func (*SetRequest) GetKey ¶
func (m *SetRequest) GetKey() string
func (*SetRequest) GetValue ¶
func (m *SetRequest) GetValue() []byte
func (*SetRequest) ProtoMessage ¶
func (*SetRequest) ProtoMessage()
func (*SetRequest) Reset ¶
func (m *SetRequest) Reset()
func (*SetRequest) String ¶
func (m *SetRequest) String() string
func (*SetRequest) XXX_DiscardUnknown ¶
func (m *SetRequest) XXX_DiscardUnknown()
func (*SetRequest) XXX_Marshal ¶
func (m *SetRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SetRequest) XXX_Merge ¶
func (m *SetRequest) XXX_Merge(src proto.Message)
func (*SetRequest) XXX_Size ¶
func (m *SetRequest) XXX_Size() int
func (*SetRequest) XXX_Unmarshal ¶
func (m *SetRequest) XXX_Unmarshal(b []byte) error
type UnimplementedCacheServer ¶
type UnimplementedCacheServer struct { }
UnimplementedCacheServer can be embedded to have forward compatible implementations.
func (*UnimplementedCacheServer) Get ¶
func (*UnimplementedCacheServer) Get(ctx context.Context, req *GetRequest) (*GetReply, error)
func (*UnimplementedCacheServer) Set ¶
func (*UnimplementedCacheServer) Set(ctx context.Context, req *SetRequest) (*SetReply, error)
Click to show internal directories.
Click to hide internal directories.