Documentation ¶
Index ¶
- Variables
- func RegisterCategoryServiceServer(s grpc.ServiceRegistrar, srv CategoryServiceServer)
- type Category
- func (*Category) Descriptor() ([]byte, []int)deprecated
- func (x *Category) GetId() int32
- func (x *Category) GetName() string
- func (x *Category) GetSubCategories() []*Category
- func (x *Category) GetUrl() string
- func (*Category) ProtoMessage()
- func (x *Category) ProtoReflect() protoreflect.Message
- func (x *Category) Reset()
- func (x *Category) String() string
- type CategoryServiceClient
- type CategoryServiceServer
- type CategoryTreeRequest
- func (*CategoryTreeRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CategoryTreeRequest) GetRoot() int32
- func (*CategoryTreeRequest) ProtoMessage()
- func (x *CategoryTreeRequest) ProtoReflect() protoreflect.Message
- func (x *CategoryTreeRequest) Reset()
- func (x *CategoryTreeRequest) String() string
- type CategoryTreeResponse
- func (*CategoryTreeResponse) Descriptor() ([]byte, []int)deprecated
- func (x *CategoryTreeResponse) GetCategories() []*Category
- func (*CategoryTreeResponse) ProtoMessage()
- func (x *CategoryTreeResponse) ProtoReflect() protoreflect.Message
- func (x *CategoryTreeResponse) Reset()
- func (x *CategoryTreeResponse) String() string
- type UnimplementedCategoryServiceServer
- type UnsafeCategoryServiceServer
Constants ¶
This section is empty.
Variables ¶
var CategoryService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "category.CategoryService", HandlerType: (*CategoryServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetCategoryTree", Handler: _CategoryService_GetCategoryTree_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "category.proto", }
CategoryService_ServiceDesc is the grpc.ServiceDesc for CategoryService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_category_proto protoreflect.FileDescriptor
Functions ¶
func RegisterCategoryServiceServer ¶
func RegisterCategoryServiceServer(s grpc.ServiceRegistrar, srv CategoryServiceServer)
Types ¶
type Category ¶
type Category struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` Url string `protobuf:"bytes,3,opt,name=url,proto3" json:"url,omitempty"` SubCategories []*Category `protobuf:"bytes,4,rep,name=subCategories,proto3" json:"subCategories,omitempty"` // contains filtered or unexported fields }
func (*Category) Descriptor
deprecated
func (*Category) GetSubCategories ¶
func (*Category) ProtoMessage ¶
func (*Category) ProtoMessage()
func (*Category) ProtoReflect ¶
func (x *Category) ProtoReflect() protoreflect.Message
type CategoryServiceClient ¶
type CategoryServiceClient interface {
GetCategoryTree(ctx context.Context, in *CategoryTreeRequest, opts ...grpc.CallOption) (*CategoryTreeResponse, error)
}
CategoryServiceClient is the client API for CategoryService 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 NewCategoryServiceClient ¶
func NewCategoryServiceClient(cc grpc.ClientConnInterface) CategoryServiceClient
type CategoryServiceServer ¶
type CategoryServiceServer interface { GetCategoryTree(context.Context, *CategoryTreeRequest) (*CategoryTreeResponse, error) // contains filtered or unexported methods }
CategoryServiceServer is the server API for CategoryService service. All implementations must embed UnimplementedCategoryServiceServer for forward compatibility
type CategoryTreeRequest ¶
type CategoryTreeRequest struct { Root int32 `protobuf:"varint,1,opt,name=root,proto3" json:"root,omitempty"` // contains filtered or unexported fields }
func (*CategoryTreeRequest) Descriptor
deprecated
func (*CategoryTreeRequest) Descriptor() ([]byte, []int)
Deprecated: Use CategoryTreeRequest.ProtoReflect.Descriptor instead.
func (*CategoryTreeRequest) GetRoot ¶
func (x *CategoryTreeRequest) GetRoot() int32
func (*CategoryTreeRequest) ProtoMessage ¶
func (*CategoryTreeRequest) ProtoMessage()
func (*CategoryTreeRequest) ProtoReflect ¶
func (x *CategoryTreeRequest) ProtoReflect() protoreflect.Message
func (*CategoryTreeRequest) Reset ¶
func (x *CategoryTreeRequest) Reset()
func (*CategoryTreeRequest) String ¶
func (x *CategoryTreeRequest) String() string
type CategoryTreeResponse ¶
type CategoryTreeResponse struct { Categories []*Category `protobuf:"bytes,1,rep,name=categories,proto3" json:"categories,omitempty"` // contains filtered or unexported fields }
func (*CategoryTreeResponse) Descriptor
deprecated
func (*CategoryTreeResponse) Descriptor() ([]byte, []int)
Deprecated: Use CategoryTreeResponse.ProtoReflect.Descriptor instead.
func (*CategoryTreeResponse) GetCategories ¶
func (x *CategoryTreeResponse) GetCategories() []*Category
func (*CategoryTreeResponse) ProtoMessage ¶
func (*CategoryTreeResponse) ProtoMessage()
func (*CategoryTreeResponse) ProtoReflect ¶
func (x *CategoryTreeResponse) ProtoReflect() protoreflect.Message
func (*CategoryTreeResponse) Reset ¶
func (x *CategoryTreeResponse) Reset()
func (*CategoryTreeResponse) String ¶
func (x *CategoryTreeResponse) String() string
type UnimplementedCategoryServiceServer ¶
type UnimplementedCategoryServiceServer struct { }
UnimplementedCategoryServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedCategoryServiceServer) GetCategoryTree ¶
func (UnimplementedCategoryServiceServer) GetCategoryTree(context.Context, *CategoryTreeRequest) (*CategoryTreeResponse, error)
type UnsafeCategoryServiceServer ¶
type UnsafeCategoryServiceServer interface {
// contains filtered or unexported methods
}
UnsafeCategoryServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to CategoryServiceServer will result in compilation errors.