Documentation ¶
Index ¶
- Variables
- func RegisterNinshouServer(s *grpc.Server, srv NinshouServer)
- type Client
- type NinshouClient
- type NinshouServer
- type User
- func (*User) Descriptor() ([]byte, []int)
- func (m *User) GetCreatedAt() *time.Time
- func (m *User) GetDeletedAt() *time.Time
- func (m *User) GetEmail() string
- func (m *User) GetId() *common.UUID
- func (m *User) GetName() string
- func (m *User) GetUpdatedAt() *time.Time
- func (m *User) Marshal() (dAtA []byte, err error)
- func (m *User) MarshalTo(dAtA []byte) (int, error)
- func (*User) ProtoMessage()
- func (m *User) Reset()
- func (m *User) Size() (n int)
- func (m *User) String() string
- func (m *User) Unmarshal(dAtA []byte) error
- func (m *User) XXX_DiscardUnknown()
- func (m *User) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *User) XXX_Merge(src proto.Message)
- func (m *User) XXX_Size() int
- func (m *User) XXX_Unmarshal(b []byte) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInvalidLengthNinshou = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowNinshou = fmt.Errorf("proto: integer overflow") )
Functions ¶
func RegisterNinshouServer ¶
func RegisterNinshouServer(s *grpc.Server, srv NinshouServer)
Types ¶
type Client ¶
type Client struct { grpc.Client NinshouClient }
Client is the client to the Ninshou gRPC service.
func NewClient ¶
func NewClient(config *grpc.ClientConfig) *Client
NewClient returns a client to the Ninshou gRPC service.
type NinshouClient ¶
type NinshouClient interface { CreateUser(ctx context.Context, in *User, opts ...grpc.CallOption) (*User, error) GetUser(ctx context.Context, in *User, opts ...grpc.CallOption) (*User, error) }
NinshouClient is the client API for Ninshou service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewNinshouClient ¶
func NewNinshouClient(cc *grpc.ClientConn) NinshouClient
type NinshouServer ¶
type NinshouServer interface { CreateUser(context.Context, *User) (*User, error) GetUser(context.Context, *User) (*User, error) }
NinshouServer is the server API for Ninshou service.
type User ¶
type User struct { Id *common.UUID `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty" bson:"_id"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` Email string `protobuf:"bytes,3,opt,name=email,proto3" json:"email,omitempty"` CreatedAt *time.Time `protobuf:"bytes,4,opt,name=createdAt,proto3,stdtime" json:"createdAt,omitempty"` UpdatedAt *time.Time `protobuf:"bytes,5,opt,name=updatedAt,proto3,stdtime" json:"updatedAt,omitempty"` DeletedAt *time.Time `protobuf:"bytes,6,opt,name=deletedAt,proto3,stdtime" json:"deletedAt,omitempty"` }
func (*User) Descriptor ¶
func (*User) GetCreatedAt ¶
func (*User) GetDeletedAt ¶
func (*User) GetUpdatedAt ¶
func (*User) ProtoMessage ¶
func (*User) ProtoMessage()
func (*User) XXX_DiscardUnknown ¶
func (m *User) XXX_DiscardUnknown()
func (*User) XXX_Unmarshal ¶
Click to show internal directories.
Click to hide internal directories.