Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterMenuHTTPServer(s *http.Server, srv MenuHTTPServer)
- func RegisterMenuServer(s grpc.ServiceRegistrar, srv MenuServer)
- type GetMenuReq
- func (*GetMenuReq) Descriptor() ([]byte, []int)deprecated
- func (x *GetMenuReq) GetPlatformID() int32
- func (x *GetMenuReq) GetSecret() string
- func (x *GetMenuReq) GetUserID() string
- func (*GetMenuReq) ProtoMessage()
- func (x *GetMenuReq) ProtoReflect() protoreflect.Message
- func (x *GetMenuReq) Reset()
- func (x *GetMenuReq) String() string
- type GetMenuResp
- func (*GetMenuResp) Descriptor() ([]byte, []int)deprecated
- func (x *GetMenuResp) GetExpireTimeSeconds() int64
- func (x *GetMenuResp) GetMenus() []*Menu
- func (*GetMenuResp) ProtoMessage()
- func (x *GetMenuResp) ProtoReflect() protoreflect.Message
- func (x *GetMenuResp) Reset()
- func (x *GetMenuResp) String() string
- type Menu
- type MenuClient
- type MenuHTTPClient
- type MenuHTTPClientImpl
- type MenuHTTPServer
- type MenuImpl
- type MenuServer
- type UnimplementedMenuServer
- type UnsafeMenuServer
Constants ¶
const ( Menu_GetMenu_FullMethodName = "/atreus.menu.Menu/getMenu" Menu_GetMenuList_FullMethodName = "/atreus.menu.Menu/getMenuList" )
const OperationMenugetMenu = "/atreus.menu.Menu/getMenu"
const OperationMenugetMenuList = "/atreus.menu.Menu/getMenuList"
Variables ¶
var Menu_ServiceDesc = grpc.ServiceDesc{ ServiceName: "atreus.menu.Menu", HandlerType: (*MenuServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "getMenu", Handler: _Menu_GetMenu_Handler, }, { MethodName: "getMenuList", Handler: _Menu_GetMenuList_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "api/menu/menu.proto", }
Menu_ServiceDesc is the grpc.ServiceDesc for Menu service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterMenuHTTPServer ¶
func RegisterMenuHTTPServer(s *http.Server, srv MenuHTTPServer)
func RegisterMenuServer ¶
func RegisterMenuServer(s grpc.ServiceRegistrar, srv MenuServer)
Types ¶
type GetMenuReq ¶
type GetMenuReq struct { Secret string `protobuf:"bytes,1,opt,name=secret,proto3" json:"secret,omitempty"` PlatformID int32 `protobuf:"varint,2,opt,name=platformID,proto3" json:"platformID,omitempty"` UserID string `protobuf:"bytes,3,opt,name=userID,proto3" json:"userID,omitempty"` // contains filtered or unexported fields }
func (*GetMenuReq) Descriptor
deprecated
func (*GetMenuReq) Descriptor() ([]byte, []int)
Deprecated: Use GetMenuReq.ProtoReflect.Descriptor instead.
func (*GetMenuReq) GetPlatformID ¶
func (x *GetMenuReq) GetPlatformID() int32
func (*GetMenuReq) GetSecret ¶
func (x *GetMenuReq) GetSecret() string
func (*GetMenuReq) GetUserID ¶
func (x *GetMenuReq) GetUserID() string
func (*GetMenuReq) ProtoMessage ¶
func (*GetMenuReq) ProtoMessage()
func (*GetMenuReq) ProtoReflect ¶
func (x *GetMenuReq) ProtoReflect() protoreflect.Message
func (*GetMenuReq) Reset ¶
func (x *GetMenuReq) Reset()
func (*GetMenuReq) String ¶
func (x *GetMenuReq) String() string
type GetMenuResp ¶
type GetMenuResp struct { Menus []*Menu `protobuf:"bytes,1,rep,name=menus,proto3" json:"menus,omitempty"` ExpireTimeSeconds int64 `protobuf:"varint,3,opt,name=expireTimeSeconds,proto3" json:"expireTimeSeconds,omitempty"` // contains filtered or unexported fields }
func (*GetMenuResp) Descriptor
deprecated
func (*GetMenuResp) Descriptor() ([]byte, []int)
Deprecated: Use GetMenuResp.ProtoReflect.Descriptor instead.
func (*GetMenuResp) GetExpireTimeSeconds ¶
func (x *GetMenuResp) GetExpireTimeSeconds() int64
func (*GetMenuResp) GetMenus ¶
func (x *GetMenuResp) GetMenus() []*Menu
func (*GetMenuResp) ProtoMessage ¶
func (*GetMenuResp) ProtoMessage()
func (*GetMenuResp) ProtoReflect ¶
func (x *GetMenuResp) ProtoReflect() protoreflect.Message
func (*GetMenuResp) Reset ¶
func (x *GetMenuResp) Reset()
func (*GetMenuResp) String ¶
func (x *GetMenuResp) String() string
type Menu ¶
type Menu struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Icon string `protobuf:"bytes,2,opt,name=icon,proto3" json:"icon,omitempty"` Children []*Menu `protobuf:"bytes,3,rep,name=children,proto3" json:"children,omitempty"` // contains filtered or unexported fields }
func (*Menu) Descriptor
deprecated
func (*Menu) GetChildren ¶
func (*Menu) ProtoMessage ¶
func (*Menu) ProtoMessage()
func (*Menu) ProtoReflect ¶
func (x *Menu) ProtoReflect() protoreflect.Message
type MenuClient ¶
type MenuClient interface { // 获取菜单树 GetMenu(ctx context.Context, in *GetMenuReq, opts ...grpc.CallOption) (*GetMenuResp, error) // 分页获取基础menu列表 GetMenuList(ctx context.Context, in *GetMenuReq, opts ...grpc.CallOption) (*GetMenuResp, error) }
MenuClient is the client API for Menu 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 NewMenuClient ¶
func NewMenuClient(cc grpc.ClientConnInterface) MenuClient
type MenuHTTPClient ¶
type MenuHTTPClient interface { GetMenu(ctx context.Context, req *GetMenuReq, opts ...http.CallOption) (rsp *GetMenuResp, err error) GetMenuList(ctx context.Context, req *GetMenuReq, opts ...http.CallOption) (rsp *GetMenuResp, err error) }
func NewMenuHTTPClient ¶
func NewMenuHTTPClient(client *http.Client) MenuHTTPClient
type MenuHTTPClientImpl ¶
type MenuHTTPClientImpl struct {
// contains filtered or unexported fields
}
func (*MenuHTTPClientImpl) GetMenu ¶
func (c *MenuHTTPClientImpl) GetMenu(ctx context.Context, in *GetMenuReq, opts ...http.CallOption) (*GetMenuResp, error)
func (*MenuHTTPClientImpl) GetMenuList ¶
func (c *MenuHTTPClientImpl) GetMenuList(ctx context.Context, in *GetMenuReq, opts ...http.CallOption) (*GetMenuResp, error)
type MenuHTTPServer ¶
type MenuHTTPServer interface { // GetMenu获取菜单树 GetMenu(context.Context, *GetMenuReq) (*GetMenuResp, error) // GetMenuList分页获取基础menu列表 GetMenuList(context.Context, *GetMenuReq) (*GetMenuResp, error) }
type MenuImpl ¶
type MenuImpl struct {
// contains filtered or unexported fields
}
func NewMenuImpl ¶
func NewMenuImpl(conn *grpc.ClientConn) *MenuImpl
func (*MenuImpl) GetMenu ¶
func (c *MenuImpl) GetMenu(ctx context.Context, in *GetMenuReq) (*GetMenuResp, error)
func (*MenuImpl) GetMenuList ¶
func (c *MenuImpl) GetMenuList(ctx context.Context, in *GetMenuReq) (*GetMenuResp, error)
type MenuServer ¶
type MenuServer interface { // 获取菜单树 GetMenu(context.Context, *GetMenuReq) (*GetMenuResp, error) // 分页获取基础menu列表 GetMenuList(context.Context, *GetMenuReq) (*GetMenuResp, error) }
MenuServer is the server API for Menu service. All implementations should embed UnimplementedMenuServer for forward compatibility
type UnimplementedMenuServer ¶
type UnimplementedMenuServer struct { }
UnimplementedMenuServer should be embedded to have forward compatible implementations.
func (UnimplementedMenuServer) GetMenu ¶
func (UnimplementedMenuServer) GetMenu(context.Context, *GetMenuReq) (*GetMenuResp, error)
func (UnimplementedMenuServer) GetMenuList ¶
func (UnimplementedMenuServer) GetMenuList(context.Context, *GetMenuReq) (*GetMenuResp, error)
type UnsafeMenuServer ¶
type UnsafeMenuServer interface {
// contains filtered or unexported methods
}
UnsafeMenuServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to MenuServer will result in compilation errors.