Documentation
¶
Index ¶
- Constants
- Variables
- func RegisterTeamServer(s grpc.ServiceRegistrar, srv TeamServer)
- type Client
- type Empty
- type TeamClient
- type TeamServer
- type UnimplementedTeamServer
- type UnsafeTeamServer
- type User
- func (*User) Descriptor() ([]byte, []int)deprecated
- func (x *User) GetClients() int32
- func (x *User) GetLastSeen() int64
- func (x *User) GetName() string
- func (x *User) GetOnline() bool
- func (*User) ProtoMessage()
- func (x *User) ProtoReflect() protoreflect.Message
- func (x *User) Reset()
- func (x *User) String() string
- type Users
- type Version
- func (*Version) Descriptor() ([]byte, []int)deprecated
- func (x *Version) GetArch() string
- func (x *Version) GetCommit() string
- func (x *Version) GetCompiledAt() int64
- func (x *Version) GetDirty() bool
- func (x *Version) GetMajor() int32
- func (x *Version) GetMinor() int32
- func (x *Version) GetOS() string
- func (x *Version) GetPatch() int32
- func (*Version) ProtoMessage()
- func (x *Version) ProtoReflect() protoreflect.Message
- func (x *Version) Reset()
- func (x *Version) String() string
Constants ¶
const ( Team_GetVersion_FullMethodName = "/client.Team/GetVersion" Team_GetUsers_FullMethodName = "/client.Team/GetUsers" )
Variables ¶
var File_client_proto protoreflect.FileDescriptor
var File_service_proto protoreflect.FileDescriptor
var Team_ServiceDesc = grpc.ServiceDesc{ ServiceName: "client.Team", HandlerType: (*TeamServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetVersion", Handler: _Team_GetVersion_Handler, }, { MethodName: "GetUsers", Handler: _Team_GetUsers_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "service.proto", }
Team_ServiceDesc is the grpc.ServiceDesc for Team service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterTeamServer ¶
func RegisterTeamServer(s grpc.ServiceRegistrar, srv TeamServer)
Types ¶
type Client ¶
type Client struct {
ID uint32 `protobuf:"varint,1,opt,name=ID,proto3" json:"ID,omitempty"`
Name string `protobuf:"bytes,2,opt,name=Name,proto3" json:"Name,omitempty"`
User *User `protobuf:"bytes,3,opt,name=User,proto3" json:"User,omitempty"`
// contains filtered or unexported fields
}
[ Client & User ]
func (*Client) Descriptor
deprecated
func (*Client) ProtoMessage ¶
func (*Client) ProtoMessage()
func (*Client) ProtoReflect ¶
func (x *Client) ProtoReflect() protoreflect.Message
type Empty ¶
type Empty struct {
// contains filtered or unexported fields
}
[ Others ]
func (*Empty) Descriptor
deprecated
func (*Empty) ProtoMessage ¶
func (*Empty) ProtoMessage()
func (*Empty) ProtoReflect ¶
func (x *Empty) ProtoReflect() protoreflect.Message
type TeamClient ¶
type TeamClient interface {
GetVersion(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Version, error)
GetUsers(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Users, error)
}
TeamClient is the client API for Team 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 NewTeamClient ¶
func NewTeamClient(cc grpc.ClientConnInterface) TeamClient
type TeamServer ¶
type TeamServer interface {
GetVersion(context.Context, *Empty) (*Version, error)
GetUsers(context.Context, *Empty) (*Users, error)
// contains filtered or unexported methods
}
TeamServer is the server API for Team service. All implementations must embed UnimplementedTeamServer for forward compatibility
type UnimplementedTeamServer ¶
type UnimplementedTeamServer struct {
}
UnimplementedTeamServer must be embedded to have forward compatible implementations.
func (UnimplementedTeamServer) GetVersion ¶
type UnsafeTeamServer ¶
type UnsafeTeamServer interface {
// contains filtered or unexported methods
}
UnsafeTeamServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TeamServer will result in compilation errors.
type User ¶
type User struct {
Name string `protobuf:"bytes,1,opt,name=Name,proto3" json:"Name,omitempty"`
Online bool `protobuf:"varint,2,opt,name=Online,proto3" json:"Online,omitempty"`
LastSeen int64 `protobuf:"varint,3,opt,name=LastSeen,proto3" json:"LastSeen,omitempty"`
Clients int32 `protobuf:"varint,4,opt,name=Clients,proto3" json:"Clients,omitempty"`
// contains filtered or unexported fields
}
func (*User) Descriptor
deprecated
func (*User) GetClients ¶
func (*User) GetLastSeen ¶
func (*User) ProtoMessage ¶
func (*User) ProtoMessage()
func (*User) ProtoReflect ¶
func (x *User) ProtoReflect() protoreflect.Message
type Users ¶
type Users struct {
Users []*User `protobuf:"bytes,1,rep,name=Users,proto3" json:"Users,omitempty"`
// contains filtered or unexported fields
}
func (*Users) Descriptor
deprecated
func (*Users) ProtoMessage ¶
func (*Users) ProtoMessage()
func (*Users) ProtoReflect ¶
func (x *Users) ProtoReflect() protoreflect.Message
type Version ¶
type Version struct {
Major int32 `protobuf:"varint,1,opt,name=Major,proto3" json:"Major,omitempty"`
Minor int32 `protobuf:"varint,2,opt,name=Minor,proto3" json:"Minor,omitempty"`
Patch int32 `protobuf:"varint,3,opt,name=Patch,proto3" json:"Patch,omitempty"`
Commit string `protobuf:"bytes,4,opt,name=Commit,proto3" json:"Commit,omitempty"`
Dirty bool `protobuf:"varint,5,opt,name=Dirty,proto3" json:"Dirty,omitempty"`
CompiledAt int64 `protobuf:"varint,6,opt,name=CompiledAt,proto3" json:"CompiledAt,omitempty"`
OS string `protobuf:"bytes,7,opt,name=OS,proto3" json:"OS,omitempty"`
Arch string `protobuf:"bytes,8,opt,name=Arch,proto3" json:"Arch,omitempty"`
// contains filtered or unexported fields
}
func (*Version) Descriptor
deprecated
func (*Version) GetCompiledAt ¶
func (*Version) ProtoMessage ¶
func (*Version) ProtoMessage()
func (*Version) ProtoReflect ¶
func (x *Version) ProtoReflect() protoreflect.Message