// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: api/v1/category.proto

package v1

import (
	context "context"
	fmt "fmt"
	_ "github.com/gogo/protobuf/gogoproto"
	proto "github.com/gogo/protobuf/proto"
	github_com_gogo_protobuf_types "github.com/gogo/protobuf/types"
	_ "google.golang.org/genproto/googleapis/api/annotations"
	grpc "google.golang.org/grpc"
	codes "google.golang.org/grpc/codes"
	status "google.golang.org/grpc/status"
	emptypb "google.golang.org/protobuf/types/known/emptypb"
	_ "google.golang.org/protobuf/types/known/timestamppb"
	io "io"
	math "math"
	math_bits "math/bits"
	time "time"
)

// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
var _ = time.Kitchen

// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package

type Category struct {
	Id        int32      `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	ParentId  int32      `protobuf:"varint,2,opt,name=parent_id,json=parentId,proto3" json:"parent_id,omitempty"`
	Title     string     `protobuf:"bytes,3,opt,name=title,proto3" json:"title,omitempty" validate:"required"`
	DocCount  int32      `protobuf:"varint,4,opt,name=doc_count,json=docCount,proto3" json:"doc_count,omitempty"`
	Sort      int32      `protobuf:"varint,5,opt,name=sort,proto3" json:"sort,omitempty"`
	Enable    bool       `protobuf:"varint,6,opt,name=enable,proto3" json:"enable,omitempty"`
	Cover     string     `protobuf:"bytes,9,opt,name=cover,proto3" json:"cover,omitempty"`
	CreatedAt *time.Time `protobuf:"bytes,7,opt,name=created_at,json=createdAt,proto3,stdtime" json:"created_at,omitempty"`
	UpdatedAt *time.Time `protobuf:"bytes,8,opt,name=updated_at,json=updatedAt,proto3,stdtime" json:"updated_at,omitempty"`
}

func (m *Category) Reset()         { *m = Category{} }
func (m *Category) String() string { return proto.CompactTextString(m) }
func (*Category) ProtoMessage()    {}
func (*Category) Descriptor() ([]byte, []int) {
	return fileDescriptor_1f1bb9165c79c987, []int{0}
}
func (m *Category) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *Category) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_Category.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *Category) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Category.Merge(m, src)
}
func (m *Category) XXX_Size() int {
	return m.Size()
}
func (m *Category) XXX_DiscardUnknown() {
	xxx_messageInfo_Category.DiscardUnknown(m)
}

var xxx_messageInfo_Category proto.InternalMessageInfo

func (m *Category) GetId() int32 {
	if m != nil {
		return m.Id
	}
	return 0
}

func (m *Category) GetParentId() int32 {
	if m != nil {
		return m.ParentId
	}
	return 0
}

func (m *Category) GetTitle() string {
	if m != nil {
		return m.Title
	}
	return ""
}

func (m *Category) GetDocCount() int32 {
	if m != nil {
		return m.DocCount
	}
	return 0
}

func (m *Category) GetSort() int32 {
	if m != nil {
		return m.Sort
	}
	return 0
}

func (m *Category) GetEnable() bool {
	if m != nil {
		return m.Enable
	}
	return false
}

func (m *Category) GetCover() string {
	if m != nil {
		return m.Cover
	}
	return ""
}

func (m *Category) GetCreatedAt() *time.Time {
	if m != nil {
		return m.CreatedAt
	}
	return nil
}

func (m *Category) GetUpdatedAt() *time.Time {
	if m != nil {
		return m.UpdatedAt
	}
	return nil
}

type ListCategoryRequest struct {
	Page     int64    `protobuf:"varint,1,opt,name=page,proto3" json:"page,omitempty"`
	Size_    int64    `protobuf:"varint,2,opt,name=size,proto3" json:"size,omitempty"`
	ParentId []int64  `protobuf:"varint,3,rep,packed,name=parent_id,json=parentId,proto3" json:"parent_id,omitempty"`
	Wd       string   `protobuf:"bytes,4,opt,name=wd,proto3" json:"wd,omitempty"`
	Enable   []bool   `protobuf:"varint,5,rep,packed,name=enable,proto3" json:"enable,omitempty"`
	Field    []string `protobuf:"bytes,6,rep,name=field,proto3" json:"field,omitempty"`
}

func (m *ListCategoryRequest) Reset()         { *m = ListCategoryRequest{} }
func (m *ListCategoryRequest) String() string { return proto.CompactTextString(m) }
func (*ListCategoryRequest) ProtoMessage()    {}
func (*ListCategoryRequest) Descriptor() ([]byte, []int) {
	return fileDescriptor_1f1bb9165c79c987, []int{1}
}
func (m *ListCategoryRequest) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *ListCategoryRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_ListCategoryRequest.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *ListCategoryRequest) XXX_Merge(src proto.Message) {
	xxx_messageInfo_ListCategoryRequest.Merge(m, src)
}
func (m *ListCategoryRequest) XXX_Size() int {
	return m.Size()
}
func (m *ListCategoryRequest) XXX_DiscardUnknown() {
	xxx_messageInfo_ListCategoryRequest.DiscardUnknown(m)
}

var xxx_messageInfo_ListCategoryRequest proto.InternalMessageInfo

func (m *ListCategoryRequest) GetPage() int64 {
	if m != nil {
		return m.Page
	}
	return 0
}

func (m *ListCategoryRequest) GetSize_() int64 {
	if m != nil {
		return m.Size_
	}
	return 0
}

func (m *ListCategoryRequest) GetParentId() []int64 {
	if m != nil {
		return m.ParentId
	}
	return nil
}

func (m *ListCategoryRequest) GetWd() string {
	if m != nil {
		return m.Wd
	}
	return ""
}

func (m *ListCategoryRequest) GetEnable() []bool {
	if m != nil {
		return m.Enable
	}
	return nil
}

func (m *ListCategoryRequest) GetField() []string {
	if m != nil {
		return m.Field
	}
	return nil
}

type ListCategoryReply struct {
	Total    int64       `protobuf:"varint,1,opt,name=total,proto3" json:"total,omitempty"`
	Category []*Category `protobuf:"bytes,2,rep,name=category,proto3" json:"category,omitempty"`
}

func (m *ListCategoryReply) Reset()         { *m = ListCategoryReply{} }
func (m *ListCategoryReply) String() string { return proto.CompactTextString(m) }
func (*ListCategoryReply) ProtoMessage()    {}
func (*ListCategoryReply) Descriptor() ([]byte, []int) {
	return fileDescriptor_1f1bb9165c79c987, []int{2}
}
func (m *ListCategoryReply) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *ListCategoryReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_ListCategoryReply.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *ListCategoryReply) XXX_Merge(src proto.Message) {
	xxx_messageInfo_ListCategoryReply.Merge(m, src)
}
func (m *ListCategoryReply) XXX_Size() int {
	return m.Size()
}
func (m *ListCategoryReply) XXX_DiscardUnknown() {
	xxx_messageInfo_ListCategoryReply.DiscardUnknown(m)
}

var xxx_messageInfo_ListCategoryReply proto.InternalMessageInfo

func (m *ListCategoryReply) GetTotal() int64 {
	if m != nil {
		return m.Total
	}
	return 0
}

func (m *ListCategoryReply) GetCategory() []*Category {
	if m != nil {
		return m.Category
	}
	return nil
}

type DeleteCategoryRequest struct {
	Id []int64 `protobuf:"varint,1,rep,packed,name=id,proto3" json:"id,omitempty"`
}

func (m *DeleteCategoryRequest) Reset()         { *m = DeleteCategoryRequest{} }
func (m *DeleteCategoryRequest) String() string { return proto.CompactTextString(m) }
func (*DeleteCategoryRequest) ProtoMessage()    {}
func (*DeleteCategoryRequest) Descriptor() ([]byte, []int) {
	return fileDescriptor_1f1bb9165c79c987, []int{3}
}
func (m *DeleteCategoryRequest) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *DeleteCategoryRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_DeleteCategoryRequest.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *DeleteCategoryRequest) XXX_Merge(src proto.Message) {
	xxx_messageInfo_DeleteCategoryRequest.Merge(m, src)
}
func (m *DeleteCategoryRequest) XXX_Size() int {
	return m.Size()
}
func (m *DeleteCategoryRequest) XXX_DiscardUnknown() {
	xxx_messageInfo_DeleteCategoryRequest.DiscardUnknown(m)
}

var xxx_messageInfo_DeleteCategoryRequest proto.InternalMessageInfo

func (m *DeleteCategoryRequest) GetId() []int64 {
	if m != nil {
		return m.Id
	}
	return nil
}

type GetCategoryRequest struct {
	Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
}

func (m *GetCategoryRequest) Reset()         { *m = GetCategoryRequest{} }
func (m *GetCategoryRequest) String() string { return proto.CompactTextString(m) }
func (*GetCategoryRequest) ProtoMessage()    {}
func (*GetCategoryRequest) Descriptor() ([]byte, []int) {
	return fileDescriptor_1f1bb9165c79c987, []int{4}
}
func (m *GetCategoryRequest) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *GetCategoryRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_GetCategoryRequest.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *GetCategoryRequest) XXX_Merge(src proto.Message) {
	xxx_messageInfo_GetCategoryRequest.Merge(m, src)
}
func (m *GetCategoryRequest) XXX_Size() int {
	return m.Size()
}
func (m *GetCategoryRequest) XXX_DiscardUnknown() {
	xxx_messageInfo_GetCategoryRequest.DiscardUnknown(m)
}

var xxx_messageInfo_GetCategoryRequest proto.InternalMessageInfo

func (m *GetCategoryRequest) GetId() int64 {
	if m != nil {
		return m.Id
	}
	return 0
}

func init() {
	proto.RegisterType((*Category)(nil), "api.v1.Category")
	proto.RegisterType((*ListCategoryRequest)(nil), "api.v1.ListCategoryRequest")
	proto.RegisterType((*ListCategoryReply)(nil), "api.v1.ListCategoryReply")
	proto.RegisterType((*DeleteCategoryRequest)(nil), "api.v1.DeleteCategoryRequest")
	proto.RegisterType((*GetCategoryRequest)(nil), "api.v1.GetCategoryRequest")
}

func init() { proto.RegisterFile("api/v1/category.proto", fileDescriptor_1f1bb9165c79c987) }

var fileDescriptor_1f1bb9165c79c987 = []byte{
	// 644 bytes of a gzipped FileDescriptorProto
	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x94, 0xc1, 0x6a, 0xdb, 0x4c,
	0x10, 0xc7, 0xb3, 0x52, 0xec, 0xcf, 0x5e, 0x7f, 0x98, 0x64, 0x13, 0x27, 0xaa, 0xdc, 0x38, 0x42,
	0x14, 0x6a, 0x42, 0x2b, 0x91, 0x94, 0x5e, 0xd2, 0x43, 0x49, 0xd2, 0x52, 0x02, 0x3d, 0x04, 0xd1,
	0x10, 0xe8, 0x25, 0x6c, 0xb4, 0x13, 0xb1, 0x20, 0x6b, 0x15, 0x69, 0xed, 0x90, 0x1e, 0xfb, 0x04,
	0x81, 0x5e, 0xfa, 0x46, 0xed, 0x31, 0xd0, 0x4b, 0x4f, 0x6d, 0x48, 0xfa, 0x04, 0x7d, 0x82, 0xa2,
	0x95, 0x14, 0x6c, 0xcb, 0x81, 0xd2, 0xdb, 0xcc, 0x68, 0xe6, 0x3f, 0x33, 0xbf, 0x1d, 0x1b, 0x77,
	0x68, 0xcc, 0xdd, 0xd1, 0xa6, 0xeb, 0x53, 0x09, 0x81, 0x48, 0x2e, 0x9c, 0x38, 0x11, 0x52, 0x90,
	0x3a, 0x8d, 0xb9, 0x33, 0xda, 0x34, 0xd7, 0x03, 0x21, 0x82, 0x10, 0x5c, 0x15, 0x3d, 0x19, 0x9e,
	0xba, 0x92, 0x0f, 0x20, 0x95, 0x74, 0x10, 0xe7, 0x89, 0xe6, 0x72, 0x20, 0x02, 0xa1, 0x4c, 0x37,
	0xb3, 0x8a, 0xe8, 0xc3, 0xa2, 0x2c, 0x13, 0xa7, 0x51, 0x24, 0x24, 0x95, 0x5c, 0x44, 0x69, 0xf1,
	0xb5, 0x3b, 0x2d, 0x0a, 0x83, 0x58, 0x16, 0x9d, 0xed, 0x2f, 0x1a, 0x6e, 0xec, 0x15, 0xc3, 0x90,
	0x36, 0xd6, 0x38, 0x33, 0x90, 0x85, 0xfa, 0x35, 0x4f, 0xe3, 0x8c, 0x74, 0x71, 0x33, 0xa6, 0x09,
	0x44, 0xf2, 0x98, 0x33, 0x43, 0x53, 0xe1, 0x46, 0x1e, 0xd8, 0x67, 0xe4, 0x29, 0xae, 0x49, 0x2e,
	0x43, 0x30, 0x74, 0x0b, 0xf5, 0x9b, 0xbb, 0xab, 0xbf, 0x7f, 0xac, 0x2f, 0x8d, 0x68, 0xc8, 0x19,
	0x95, 0xb0, 0x6d, 0x27, 0x70, 0x36, 0xe4, 0x09, 0x30, 0xdb, 0xcb, 0xb3, 0x32, 0x2d, 0x26, 0xfc,
	0x63, 0x5f, 0x0c, 0x23, 0x69, 0xcc, 0xe7, 0x5a, 0x4c, 0xf8, 0x7b, 0x99, 0x4f, 0x08, 0x9e, 0x4f,
	0x45, 0x22, 0x8d, 0x9a, 0x8a, 0x2b, 0x9b, 0xac, 0xe0, 0x3a, 0x44, 0xf4, 0x24, 0x04, 0xa3, 0x6e,
	0xa1, 0x7e, 0xc3, 0x2b, 0x3c, 0xb2, 0x8c, 0x6b, 0xbe, 0x18, 0x41, 0x62, 0x34, 0xb3, 0xbe, 0x5e,
	0xee, 0x90, 0x97, 0x18, 0xfb, 0x09, 0x50, 0x09, 0xec, 0x98, 0x4a, 0xe3, 0x3f, 0x0b, 0xf5, 0x5b,
	0x5b, 0xa6, 0x93, 0x6f, 0xee, 0x94, 0x9b, 0x3b, 0xef, 0x4a, 0x9c, 0xbb, 0xf3, 0x97, 0x3f, 0xd7,
	0x91, 0xd7, 0x2c, 0x6a, 0x76, 0x64, 0x26, 0x30, 0x8c, 0x59, 0x29, 0xd0, 0xf8, 0x5b, 0x81, 0xa2,
	0x66, 0x47, 0xda, 0x9f, 0x11, 0x5e, 0x7a, 0xcb, 0x53, 0x59, 0xd2, 0xf4, 0xe0, 0x6c, 0x08, 0xa9,
	0xda, 0x2d, 0xa6, 0x01, 0x28, 0xac, 0xba, 0xa7, 0x6c, 0xb5, 0x2f, 0xff, 0x00, 0x8a, 0xa9, 0xee,
	0x29, 0x7b, 0x12, 0xb6, 0x6e, 0xe9, 0x7d, 0x7d, 0x0c, 0x76, 0x1b, 0x6b, 0xe7, 0x4c, 0x61, 0x6b,
	0x7a, 0xda, 0x39, 0x1b, 0x83, 0x53, 0xb3, 0xf4, 0x49, 0x38, 0xa7, 0x1c, 0x42, 0x66, 0xd4, 0x2d,
	0x3d, 0x83, 0xa3, 0x1c, 0xfb, 0x08, 0x2f, 0x4e, 0x4e, 0x16, 0x87, 0x17, 0x59, 0xaa, 0x14, 0x92,
	0x86, 0xc5, 0x60, 0xb9, 0x43, 0x9e, 0xe0, 0x46, 0x79, 0x9b, 0x86, 0x66, 0xe9, 0xfd, 0xd6, 0xd6,
	0x82, 0x93, 0x1f, 0xa7, 0x73, 0x57, 0x7e, 0x97, 0x61, 0x3f, 0xc6, 0x9d, 0x57, 0x10, 0x82, 0x84,
	0xe9, 0xa5, 0xcb, 0x4b, 0xca, 0xb6, 0xd0, 0x38, 0xb3, 0x1f, 0x61, 0xf2, 0x06, 0xe4, 0x7d, 0x59,
	0x28, 0xcf, 0xda, 0xba, 0xd6, 0x71, 0xab, 0xcc, 0xd9, 0x39, 0xd8, 0x27, 0x47, 0xb8, 0xbd, 0xa7,
	0x1e, 0xe8, 0xee, 0x42, 0x2b, 0xc3, 0x98, 0x2b, 0x95, 0x37, 0x7a, 0x9d, 0x9d, 0xb7, 0xdd, 0xfd,
	0xf8, 0xed, 0xd7, 0x27, 0xad, 0x63, 0x2f, 0xb8, 0x53, 0x3f, 0xb9, 0x6d, 0xb4, 0x91, 0x09, 0x1f,
	0xaa, 0x87, 0xfb, 0x77, 0x61, 0x73, 0xa6, 0x30, 0xc5, 0xed, 0x49, 0x20, 0x64, 0xad, 0x14, 0x9e,
	0x09, 0xea, 0xde, 0x2e, 0x86, 0xea, 0x42, 0x36, 0x2a, 0x5d, 0xc8, 0x21, 0x6e, 0x8d, 0xa1, 0x24,
	0x66, 0xa9, 0x5f, 0xe5, 0x6b, 0x56, 0x96, 0x2a, 0x65, 0x49, 0x55, 0x16, 0xf0, 0xff, 0xe3, 0x37,
	0x42, 0xba, 0x65, 0xed, 0x8c, 0x9b, 0x36, 0x1f, 0xcc, 0xfe, 0x18, 0x87, 0x17, 0xf6, 0x9a, 0xea,
	0xb0, 0x4a, 0x3a, 0xd3, 0x1d, 0xdc, 0x90, 0xa7, 0x72, 0xf7, 0xf9, 0xd7, 0x9b, 0x1e, 0xba, 0xba,
	0xe9, 0xa1, 0xeb, 0x9b, 0x1e, 0xba, 0xbc, 0xed, 0xcd, 0x5d, 0xdd, 0xf6, 0xe6, 0xbe, 0xdf, 0xf6,
	0xe6, 0x70, 0xf1, 0x1f, 0x78, 0x80, 0xde, 0x2f, 0x0e, 0x44, 0x02, 0x4c, 0xf8, 0x85, 0xc2, 0x8b,
	0xd1, 0xe6, 0x49, 0x5d, 0xe1, 0x79, 0xf6, 0x27, 0x00, 0x00, 0xff, 0xff, 0x7a, 0xac, 0x26, 0x45,
	0x40, 0x05, 0x00, 0x00,
}

// Reference imports to suppress errors if they are not otherwise used.
var _ context.Context
var _ grpc.ClientConn

// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion4

// CategoryAPIClient is the client API for CategoryAPI service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type CategoryAPIClient interface {
	CreateCategory(ctx context.Context, in *Category, opts ...grpc.CallOption) (*emptypb.Empty, error)
	UpdateCategory(ctx context.Context, in *Category, opts ...grpc.CallOption) (*emptypb.Empty, error)
	DeleteCategory(ctx context.Context, in *DeleteCategoryRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	GetCategory(ctx context.Context, in *GetCategoryRequest, opts ...grpc.CallOption) (*Category, error)
	ListCategory(ctx context.Context, in *ListCategoryRequest, opts ...grpc.CallOption) (*ListCategoryReply, error)
}

type categoryAPIClient struct {
	cc *grpc.ClientConn
}

func NewCategoryAPIClient(cc *grpc.ClientConn) CategoryAPIClient {
	return &categoryAPIClient{cc}
}

func (c *categoryAPIClient) CreateCategory(ctx context.Context, in *Category, opts ...grpc.CallOption) (*emptypb.Empty, error) {
	out := new(emptypb.Empty)
	err := c.cc.Invoke(ctx, "/api.v1.CategoryAPI/CreateCategory", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *categoryAPIClient) UpdateCategory(ctx context.Context, in *Category, opts ...grpc.CallOption) (*emptypb.Empty, error) {
	out := new(emptypb.Empty)
	err := c.cc.Invoke(ctx, "/api.v1.CategoryAPI/UpdateCategory", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *categoryAPIClient) DeleteCategory(ctx context.Context, in *DeleteCategoryRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {
	out := new(emptypb.Empty)
	err := c.cc.Invoke(ctx, "/api.v1.CategoryAPI/DeleteCategory", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *categoryAPIClient) GetCategory(ctx context.Context, in *GetCategoryRequest, opts ...grpc.CallOption) (*Category, error) {
	out := new(Category)
	err := c.cc.Invoke(ctx, "/api.v1.CategoryAPI/GetCategory", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *categoryAPIClient) ListCategory(ctx context.Context, in *ListCategoryRequest, opts ...grpc.CallOption) (*ListCategoryReply, error) {
	out := new(ListCategoryReply)
	err := c.cc.Invoke(ctx, "/api.v1.CategoryAPI/ListCategory", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// CategoryAPIServer is the server API for CategoryAPI service.
type CategoryAPIServer interface {
	CreateCategory(context.Context, *Category) (*emptypb.Empty, error)
	UpdateCategory(context.Context, *Category) (*emptypb.Empty, error)
	DeleteCategory(context.Context, *DeleteCategoryRequest) (*emptypb.Empty, error)
	GetCategory(context.Context, *GetCategoryRequest) (*Category, error)
	ListCategory(context.Context, *ListCategoryRequest) (*ListCategoryReply, error)
}

// UnimplementedCategoryAPIServer can be embedded to have forward compatible implementations.
type UnimplementedCategoryAPIServer struct {
}

func (*UnimplementedCategoryAPIServer) CreateCategory(ctx context.Context, req *Category) (*emptypb.Empty, error) {
	return nil, status.Errorf(codes.Unimplemented, "method CreateCategory not implemented")
}
func (*UnimplementedCategoryAPIServer) UpdateCategory(ctx context.Context, req *Category) (*emptypb.Empty, error) {
	return nil, status.Errorf(codes.Unimplemented, "method UpdateCategory not implemented")
}
func (*UnimplementedCategoryAPIServer) DeleteCategory(ctx context.Context, req *DeleteCategoryRequest) (*emptypb.Empty, error) {
	return nil, status.Errorf(codes.Unimplemented, "method DeleteCategory not implemented")
}
func (*UnimplementedCategoryAPIServer) GetCategory(ctx context.Context, req *GetCategoryRequest) (*Category, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GetCategory not implemented")
}
func (*UnimplementedCategoryAPIServer) ListCategory(ctx context.Context, req *ListCategoryRequest) (*ListCategoryReply, error) {
	return nil, status.Errorf(codes.Unimplemented, "method ListCategory not implemented")
}

func RegisterCategoryAPIServer(s *grpc.Server, srv CategoryAPIServer) {
	s.RegisterService(&_CategoryAPI_serviceDesc, srv)
}

func _CategoryAPI_CreateCategory_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(Category)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(CategoryAPIServer).CreateCategory(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.v1.CategoryAPI/CreateCategory",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(CategoryAPIServer).CreateCategory(ctx, req.(*Category))
	}
	return interceptor(ctx, in, info, handler)
}

func _CategoryAPI_UpdateCategory_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(Category)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(CategoryAPIServer).UpdateCategory(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.v1.CategoryAPI/UpdateCategory",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(CategoryAPIServer).UpdateCategory(ctx, req.(*Category))
	}
	return interceptor(ctx, in, info, handler)
}

func _CategoryAPI_DeleteCategory_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(DeleteCategoryRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(CategoryAPIServer).DeleteCategory(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.v1.CategoryAPI/DeleteCategory",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(CategoryAPIServer).DeleteCategory(ctx, req.(*DeleteCategoryRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _CategoryAPI_GetCategory_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GetCategoryRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(CategoryAPIServer).GetCategory(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.v1.CategoryAPI/GetCategory",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(CategoryAPIServer).GetCategory(ctx, req.(*GetCategoryRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _CategoryAPI_ListCategory_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(ListCategoryRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(CategoryAPIServer).ListCategory(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.v1.CategoryAPI/ListCategory",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(CategoryAPIServer).ListCategory(ctx, req.(*ListCategoryRequest))
	}
	return interceptor(ctx, in, info, handler)
}

var _CategoryAPI_serviceDesc = grpc.ServiceDesc{
	ServiceName: "api.v1.CategoryAPI",
	HandlerType: (*CategoryAPIServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CreateCategory",
			Handler:    _CategoryAPI_CreateCategory_Handler,
		},
		{
			MethodName: "UpdateCategory",
			Handler:    _CategoryAPI_UpdateCategory_Handler,
		},
		{
			MethodName: "DeleteCategory",
			Handler:    _CategoryAPI_DeleteCategory_Handler,
		},
		{
			MethodName: "GetCategory",
			Handler:    _CategoryAPI_GetCategory_Handler,
		},
		{
			MethodName: "ListCategory",
			Handler:    _CategoryAPI_ListCategory_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "api/v1/category.proto",
}

func (m *Category) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Category) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Category) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if len(m.Cover) > 0 {
		i -= len(m.Cover)
		copy(dAtA[i:], m.Cover)
		i = encodeVarintCategory(dAtA, i, uint64(len(m.Cover)))
		i--
		dAtA[i] = 0x4a
	}
	if m.UpdatedAt != nil {
		n1, err1 := github_com_gogo_protobuf_types.StdTimeMarshalTo(*m.UpdatedAt, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdTime(*m.UpdatedAt):])
		if err1 != nil {
			return 0, err1
		}
		i -= n1
		i = encodeVarintCategory(dAtA, i, uint64(n1))
		i--
		dAtA[i] = 0x42
	}
	if m.CreatedAt != nil {
		n2, err2 := github_com_gogo_protobuf_types.StdTimeMarshalTo(*m.CreatedAt, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdTime(*m.CreatedAt):])
		if err2 != nil {
			return 0, err2
		}
		i -= n2
		i = encodeVarintCategory(dAtA, i, uint64(n2))
		i--
		dAtA[i] = 0x3a
	}
	if m.Enable {
		i--
		if m.Enable {
			dAtA[i] = 1
		} else {
			dAtA[i] = 0
		}
		i--
		dAtA[i] = 0x30
	}
	if m.Sort != 0 {
		i = encodeVarintCategory(dAtA, i, uint64(m.Sort))
		i--
		dAtA[i] = 0x28
	}
	if m.DocCount != 0 {
		i = encodeVarintCategory(dAtA, i, uint64(m.DocCount))
		i--
		dAtA[i] = 0x20
	}
	if len(m.Title) > 0 {
		i -= len(m.Title)
		copy(dAtA[i:], m.Title)
		i = encodeVarintCategory(dAtA, i, uint64(len(m.Title)))
		i--
		dAtA[i] = 0x1a
	}
	if m.ParentId != 0 {
		i = encodeVarintCategory(dAtA, i, uint64(m.ParentId))
		i--
		dAtA[i] = 0x10
	}
	if m.Id != 0 {
		i = encodeVarintCategory(dAtA, i, uint64(m.Id))
		i--
		dAtA[i] = 0x8
	}
	return len(dAtA) - i, nil
}

func (m *ListCategoryRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ListCategoryRequest) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *ListCategoryRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if len(m.Field) > 0 {
		for iNdEx := len(m.Field) - 1; iNdEx >= 0; iNdEx-- {
			i -= len(m.Field[iNdEx])
			copy(dAtA[i:], m.Field[iNdEx])
			i = encodeVarintCategory(dAtA, i, uint64(len(m.Field[iNdEx])))
			i--
			dAtA[i] = 0x32
		}
	}
	if len(m.Enable) > 0 {
		for iNdEx := len(m.Enable) - 1; iNdEx >= 0; iNdEx-- {
			i--
			if m.Enable[iNdEx] {
				dAtA[i] = 1
			} else {
				dAtA[i] = 0
			}
		}
		i = encodeVarintCategory(dAtA, i, uint64(len(m.Enable)))
		i--
		dAtA[i] = 0x2a
	}
	if len(m.Wd) > 0 {
		i -= len(m.Wd)
		copy(dAtA[i:], m.Wd)
		i = encodeVarintCategory(dAtA, i, uint64(len(m.Wd)))
		i--
		dAtA[i] = 0x22
	}
	if len(m.ParentId) > 0 {
		dAtA4 := make([]byte, len(m.ParentId)*10)
		var j3 int
		for _, num1 := range m.ParentId {
			num := uint64(num1)
			for num >= 1<<7 {
				dAtA4[j3] = uint8(uint64(num)&0x7f | 0x80)
				num >>= 7
				j3++
			}
			dAtA4[j3] = uint8(num)
			j3++
		}
		i -= j3
		copy(dAtA[i:], dAtA4[:j3])
		i = encodeVarintCategory(dAtA, i, uint64(j3))
		i--
		dAtA[i] = 0x1a
	}
	if m.Size_ != 0 {
		i = encodeVarintCategory(dAtA, i, uint64(m.Size_))
		i--
		dAtA[i] = 0x10
	}
	if m.Page != 0 {
		i = encodeVarintCategory(dAtA, i, uint64(m.Page))
		i--
		dAtA[i] = 0x8
	}
	return len(dAtA) - i, nil
}

func (m *ListCategoryReply) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ListCategoryReply) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *ListCategoryReply) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if len(m.Category) > 0 {
		for iNdEx := len(m.Category) - 1; iNdEx >= 0; iNdEx-- {
			{
				size, err := m.Category[iNdEx].MarshalToSizedBuffer(dAtA[:i])
				if err != nil {
					return 0, err
				}
				i -= size
				i = encodeVarintCategory(dAtA, i, uint64(size))
			}
			i--
			dAtA[i] = 0x12
		}
	}
	if m.Total != 0 {
		i = encodeVarintCategory(dAtA, i, uint64(m.Total))
		i--
		dAtA[i] = 0x8
	}
	return len(dAtA) - i, nil
}

func (m *DeleteCategoryRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *DeleteCategoryRequest) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *DeleteCategoryRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if len(m.Id) > 0 {
		dAtA6 := make([]byte, len(m.Id)*10)
		var j5 int
		for _, num1 := range m.Id {
			num := uint64(num1)
			for num >= 1<<7 {
				dAtA6[j5] = uint8(uint64(num)&0x7f | 0x80)
				num >>= 7
				j5++
			}
			dAtA6[j5] = uint8(num)
			j5++
		}
		i -= j5
		copy(dAtA[i:], dAtA6[:j5])
		i = encodeVarintCategory(dAtA, i, uint64(j5))
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *GetCategoryRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *GetCategoryRequest) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *GetCategoryRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.Id != 0 {
		i = encodeVarintCategory(dAtA, i, uint64(m.Id))
		i--
		dAtA[i] = 0x8
	}
	return len(dAtA) - i, nil
}

func encodeVarintCategory(dAtA []byte, offset int, v uint64) int {
	offset -= sovCategory(v)
	base := offset
	for v >= 1<<7 {
		dAtA[offset] = uint8(v&0x7f | 0x80)
		v >>= 7
		offset++
	}
	dAtA[offset] = uint8(v)
	return base
}
func (m *Category) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.Id != 0 {
		n += 1 + sovCategory(uint64(m.Id))
	}
	if m.ParentId != 0 {
		n += 1 + sovCategory(uint64(m.ParentId))
	}
	l = len(m.Title)
	if l > 0 {
		n += 1 + l + sovCategory(uint64(l))
	}
	if m.DocCount != 0 {
		n += 1 + sovCategory(uint64(m.DocCount))
	}
	if m.Sort != 0 {
		n += 1 + sovCategory(uint64(m.Sort))
	}
	if m.Enable {
		n += 2
	}
	if m.CreatedAt != nil {
		l = github_com_gogo_protobuf_types.SizeOfStdTime(*m.CreatedAt)
		n += 1 + l + sovCategory(uint64(l))
	}
	if m.UpdatedAt != nil {
		l = github_com_gogo_protobuf_types.SizeOfStdTime(*m.UpdatedAt)
		n += 1 + l + sovCategory(uint64(l))
	}
	l = len(m.Cover)
	if l > 0 {
		n += 1 + l + sovCategory(uint64(l))
	}
	return n
}

func (m *ListCategoryRequest) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.Page != 0 {
		n += 1 + sovCategory(uint64(m.Page))
	}
	if m.Size_ != 0 {
		n += 1 + sovCategory(uint64(m.Size_))
	}
	if len(m.ParentId) > 0 {
		l = 0
		for _, e := range m.ParentId {
			l += sovCategory(uint64(e))
		}
		n += 1 + sovCategory(uint64(l)) + l
	}
	l = len(m.Wd)
	if l > 0 {
		n += 1 + l + sovCategory(uint64(l))
	}
	if len(m.Enable) > 0 {
		n += 1 + sovCategory(uint64(len(m.Enable))) + len(m.Enable)*1
	}
	if len(m.Field) > 0 {
		for _, s := range m.Field {
			l = len(s)
			n += 1 + l + sovCategory(uint64(l))
		}
	}
	return n
}

func (m *ListCategoryReply) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.Total != 0 {
		n += 1 + sovCategory(uint64(m.Total))
	}
	if len(m.Category) > 0 {
		for _, e := range m.Category {
			l = e.Size()
			n += 1 + l + sovCategory(uint64(l))
		}
	}
	return n
}

func (m *DeleteCategoryRequest) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if len(m.Id) > 0 {
		l = 0
		for _, e := range m.Id {
			l += sovCategory(uint64(e))
		}
		n += 1 + sovCategory(uint64(l)) + l
	}
	return n
}

func (m *GetCategoryRequest) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.Id != 0 {
		n += 1 + sovCategory(uint64(m.Id))
	}
	return n
}

func sovCategory(x uint64) (n int) {
	return (math_bits.Len64(x|1) + 6) / 7
}
func sozCategory(x uint64) (n int) {
	return sovCategory(uint64((x << 1) ^ uint64((int64(x) >> 63))))
}
func (m *Category) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowCategory
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Category: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Category: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
			}
			m.Id = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Id |= int32(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field ParentId", wireType)
			}
			m.ParentId = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.ParentId |= int32(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Title", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthCategory
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthCategory
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Title = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 4:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field DocCount", wireType)
			}
			m.DocCount = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.DocCount |= int32(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 5:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Sort", wireType)
			}
			m.Sort = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Sort |= int32(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 6:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Enable", wireType)
			}
			var v int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				v |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			m.Enable = bool(v != 0)
		case 7:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field CreatedAt", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthCategory
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthCategory
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.CreatedAt == nil {
				m.CreatedAt = new(time.Time)
			}
			if err := github_com_gogo_protobuf_types.StdTimeUnmarshal(m.CreatedAt, dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 8:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field UpdatedAt", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthCategory
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthCategory
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.UpdatedAt == nil {
				m.UpdatedAt = new(time.Time)
			}
			if err := github_com_gogo_protobuf_types.StdTimeUnmarshal(m.UpdatedAt, dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 9:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Cover", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthCategory
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthCategory
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Cover = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipCategory(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthCategory
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ListCategoryRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowCategory
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ListCategoryRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ListCategoryRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Page", wireType)
			}
			m.Page = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Page |= int64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Size_", wireType)
			}
			m.Size_ = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Size_ |= int64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType == 0 {
				var v int64
				for shift := uint(0); ; shift += 7 {
					if shift >= 64 {
						return ErrIntOverflowCategory
					}
					if iNdEx >= l {
						return io.ErrUnexpectedEOF
					}
					b := dAtA[iNdEx]
					iNdEx++
					v |= int64(b&0x7F) << shift
					if b < 0x80 {
						break
					}
				}
				m.ParentId = append(m.ParentId, v)
			} else if wireType == 2 {
				var packedLen int
				for shift := uint(0); ; shift += 7 {
					if shift >= 64 {
						return ErrIntOverflowCategory
					}
					if iNdEx >= l {
						return io.ErrUnexpectedEOF
					}
					b := dAtA[iNdEx]
					iNdEx++
					packedLen |= int(b&0x7F) << shift
					if b < 0x80 {
						break
					}
				}
				if packedLen < 0 {
					return ErrInvalidLengthCategory
				}
				postIndex := iNdEx + packedLen
				if postIndex < 0 {
					return ErrInvalidLengthCategory
				}
				if postIndex > l {
					return io.ErrUnexpectedEOF
				}
				var elementCount int
				var count int
				for _, integer := range dAtA[iNdEx:postIndex] {
					if integer < 128 {
						count++
					}
				}
				elementCount = count
				if elementCount != 0 && len(m.ParentId) == 0 {
					m.ParentId = make([]int64, 0, elementCount)
				}
				for iNdEx < postIndex {
					var v int64
					for shift := uint(0); ; shift += 7 {
						if shift >= 64 {
							return ErrIntOverflowCategory
						}
						if iNdEx >= l {
							return io.ErrUnexpectedEOF
						}
						b := dAtA[iNdEx]
						iNdEx++
						v |= int64(b&0x7F) << shift
						if b < 0x80 {
							break
						}
					}
					m.ParentId = append(m.ParentId, v)
				}
			} else {
				return fmt.Errorf("proto: wrong wireType = %d for field ParentId", wireType)
			}
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Wd", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthCategory
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthCategory
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Wd = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 5:
			if wireType == 0 {
				var v int
				for shift := uint(0); ; shift += 7 {
					if shift >= 64 {
						return ErrIntOverflowCategory
					}
					if iNdEx >= l {
						return io.ErrUnexpectedEOF
					}
					b := dAtA[iNdEx]
					iNdEx++
					v |= int(b&0x7F) << shift
					if b < 0x80 {
						break
					}
				}
				m.Enable = append(m.Enable, bool(v != 0))
			} else if wireType == 2 {
				var packedLen int
				for shift := uint(0); ; shift += 7 {
					if shift >= 64 {
						return ErrIntOverflowCategory
					}
					if iNdEx >= l {
						return io.ErrUnexpectedEOF
					}
					b := dAtA[iNdEx]
					iNdEx++
					packedLen |= int(b&0x7F) << shift
					if b < 0x80 {
						break
					}
				}
				if packedLen < 0 {
					return ErrInvalidLengthCategory
				}
				postIndex := iNdEx + packedLen
				if postIndex < 0 {
					return ErrInvalidLengthCategory
				}
				if postIndex > l {
					return io.ErrUnexpectedEOF
				}
				var elementCount int
				elementCount = packedLen
				if elementCount != 0 && len(m.Enable) == 0 {
					m.Enable = make([]bool, 0, elementCount)
				}
				for iNdEx < postIndex {
					var v int
					for shift := uint(0); ; shift += 7 {
						if shift >= 64 {
							return ErrIntOverflowCategory
						}
						if iNdEx >= l {
							return io.ErrUnexpectedEOF
						}
						b := dAtA[iNdEx]
						iNdEx++
						v |= int(b&0x7F) << shift
						if b < 0x80 {
							break
						}
					}
					m.Enable = append(m.Enable, bool(v != 0))
				}
			} else {
				return fmt.Errorf("proto: wrong wireType = %d for field Enable", wireType)
			}
		case 6:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Field", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthCategory
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthCategory
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Field = append(m.Field, string(dAtA[iNdEx:postIndex]))
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipCategory(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthCategory
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ListCategoryReply) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowCategory
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ListCategoryReply: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ListCategoryReply: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Total", wireType)
			}
			m.Total = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Total |= int64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Category", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthCategory
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthCategory
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Category = append(m.Category, &Category{})
			if err := m.Category[len(m.Category)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipCategory(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthCategory
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *DeleteCategoryRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowCategory
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: DeleteCategoryRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: DeleteCategoryRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType == 0 {
				var v int64
				for shift := uint(0); ; shift += 7 {
					if shift >= 64 {
						return ErrIntOverflowCategory
					}
					if iNdEx >= l {
						return io.ErrUnexpectedEOF
					}
					b := dAtA[iNdEx]
					iNdEx++
					v |= int64(b&0x7F) << shift
					if b < 0x80 {
						break
					}
				}
				m.Id = append(m.Id, v)
			} else if wireType == 2 {
				var packedLen int
				for shift := uint(0); ; shift += 7 {
					if shift >= 64 {
						return ErrIntOverflowCategory
					}
					if iNdEx >= l {
						return io.ErrUnexpectedEOF
					}
					b := dAtA[iNdEx]
					iNdEx++
					packedLen |= int(b&0x7F) << shift
					if b < 0x80 {
						break
					}
				}
				if packedLen < 0 {
					return ErrInvalidLengthCategory
				}
				postIndex := iNdEx + packedLen
				if postIndex < 0 {
					return ErrInvalidLengthCategory
				}
				if postIndex > l {
					return io.ErrUnexpectedEOF
				}
				var elementCount int
				var count int
				for _, integer := range dAtA[iNdEx:postIndex] {
					if integer < 128 {
						count++
					}
				}
				elementCount = count
				if elementCount != 0 && len(m.Id) == 0 {
					m.Id = make([]int64, 0, elementCount)
				}
				for iNdEx < postIndex {
					var v int64
					for shift := uint(0); ; shift += 7 {
						if shift >= 64 {
							return ErrIntOverflowCategory
						}
						if iNdEx >= l {
							return io.ErrUnexpectedEOF
						}
						b := dAtA[iNdEx]
						iNdEx++
						v |= int64(b&0x7F) << shift
						if b < 0x80 {
							break
						}
					}
					m.Id = append(m.Id, v)
				}
			} else {
				return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
			}
		default:
			iNdEx = preIndex
			skippy, err := skipCategory(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthCategory
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *GetCategoryRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowCategory
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: GetCategoryRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: GetCategoryRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
			}
			m.Id = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Id |= int64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipCategory(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthCategory
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func skipCategory(dAtA []byte) (n int, err error) {
	l := len(dAtA)
	iNdEx := 0
	depth := 0
	for iNdEx < l {
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return 0, ErrIntOverflowCategory
			}
			if iNdEx >= l {
				return 0, io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		wireType := int(wire & 0x7)
		switch wireType {
		case 0:
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return 0, ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return 0, io.ErrUnexpectedEOF
				}
				iNdEx++
				if dAtA[iNdEx-1] < 0x80 {
					break
				}
			}
		case 1:
			iNdEx += 8
		case 2:
			var length int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return 0, ErrIntOverflowCategory
				}
				if iNdEx >= l {
					return 0, io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				length |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if length < 0 {
				return 0, ErrInvalidLengthCategory
			}
			iNdEx += length
		case 3:
			depth++
		case 4:
			if depth == 0 {
				return 0, ErrUnexpectedEndOfGroupCategory
			}
			depth--
		case 5:
			iNdEx += 4
		default:
			return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
		}
		if iNdEx < 0 {
			return 0, ErrInvalidLengthCategory
		}
		if depth == 0 {
			return iNdEx, nil
		}
	}
	return 0, io.ErrUnexpectedEOF
}

var (
	ErrInvalidLengthCategory        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowCategory          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupCategory = fmt.Errorf("proto: unexpected end of group")
)
