contacts

package
v0.0.0-...-acd6729 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 17, 2022 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	User_Race_name = map[int32]string{
		0: "RACE_UNSPECIFIED",
		1: "YELLOW",
		2: "WHITE",
		3: "BLACK",
	}
	User_Race_value = map[string]int32{
		"RACE_UNSPECIFIED": 0,
		"YELLOW":           1,
		"WHITE":            2,
		"BLACK":            3,
	}
)

Enum value maps for User_Race.

View Source
var (
	DeptAddUserReq_Race_name = map[int32]string{
		0: "RACE_UNSPECIFIED",
		1: "YELLOW",
		2: "WHITE",
		3: "BLACK",
	}
	DeptAddUserReq_Race_value = map[string]int32{
		"RACE_UNSPECIFIED": 0,
		"YELLOW":           1,
		"WHITE":            2,
		"BLACK":            3,
	}
)

Enum value maps for DeptAddUserReq_Race.

View Source
var (
	UserPageQuery_Race_name = map[int32]string{
		0: "RACE_UNSPECIFIED",
		1: "YELLOW",
		2: "WHITE",
		3: "BLACK",
	}
	UserPageQuery_Race_value = map[string]int32{
		"RACE_UNSPECIFIED": 0,
		"YELLOW":           1,
		"WHITE":            2,
		"BLACK":            3,
	}
)

Enum value maps for UserPageQuery_Race.

View Source
var CarService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "contacts.CarService",
	HandlerType: (*CarServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Create",
			Handler:    _CarService_Create_Handler,
		},
		{
			MethodName: "Update",
			Handler:    _CarService_Update_Handler,
		},
		{
			MethodName: "Delete",
			Handler:    _CarService_Delete_Handler,
		},
		{
			MethodName: "FindById",
			Handler:    _CarService_FindById_Handler,
		},
		{
			MethodName: "Find",
			Handler:    _CarService_Find_Handler,
		},
		{
			MethodName: "Count",
			Handler:    _CarService_Count_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "api/v1/contacts/contacts.proto",
}

CarService_ServiceDesc is the grpc.ServiceDesc for CarService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var DeptService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "contacts.DeptService",
	HandlerType: (*DeptServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Create",
			Handler:    _DeptService_Create_Handler,
		},
		{
			MethodName: "Update",
			Handler:    _DeptService_Update_Handler,
		},
		{
			MethodName: "Delete",
			Handler:    _DeptService_Delete_Handler,
		},
		{
			MethodName: "FindById",
			Handler:    _DeptService_FindById_Handler,
		},
		{
			MethodName: "Find",
			Handler:    _DeptService_Find_Handler,
		},
		{
			MethodName: "Count",
			Handler:    _DeptService_Count_Handler,
		},
		{
			MethodName: "AddUser",
			Handler:    _DeptService_AddUser_Handler,
		},
		{
			MethodName: "AddUserById",
			Handler:    _DeptService_AddUserById_Handler,
		},
		{
			MethodName: "RemoveUser",
			Handler:    _DeptService_RemoveUser_Handler,
		},
		{
			MethodName: "FindUsers",
			Handler:    _DeptService_FindUsers_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "api/v1/contacts/contacts.proto",
}

DeptService_ServiceDesc is the grpc.ServiceDesc for DeptService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_api_v1_contacts_contacts_proto protoreflect.FileDescriptor
View Source
var UserService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "contacts.UserService",
	HandlerType: (*UserServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Create",
			Handler:    _UserService_Create_Handler,
		},
		{
			MethodName: "Update",
			Handler:    _UserService_Update_Handler,
		},
		{
			MethodName: "Delete",
			Handler:    _UserService_Delete_Handler,
		},
		{
			MethodName: "FindById",
			Handler:    _UserService_FindById_Handler,
		},
		{
			MethodName: "Find",
			Handler:    _UserService_Find_Handler,
		},
		{
			MethodName: "Count",
			Handler:    _UserService_Count_Handler,
		},
		{
			MethodName: "AddCar",
			Handler:    _UserService_AddCar_Handler,
		},
		{
			MethodName: "AddCarById",
			Handler:    _UserService_AddCarById_Handler,
		},
		{
			MethodName: "RemoveCar",
			Handler:    _UserService_RemoveCar_Handler,
		},
		{
			MethodName: "FindCars",
			Handler:    _UserService_FindCars_Handler,
		},
		{
			MethodName: "FindDepts",
			Handler:    _UserService_FindDepts_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "api/v1/contacts/contacts.proto",
}

UserService_ServiceDesc is the grpc.ServiceDesc for UserService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterCarServiceHTTPServer

func RegisterCarServiceHTTPServer(s *http.Server, srv CarServiceHTTPServer)

func RegisterCarServiceServer

func RegisterCarServiceServer(s grpc.ServiceRegistrar, srv CarServiceServer)

func RegisterDeptServiceHTTPServer

func RegisterDeptServiceHTTPServer(s *http.Server, srv DeptServiceHTTPServer)

func RegisterDeptServiceServer

func RegisterDeptServiceServer(s grpc.ServiceRegistrar, srv DeptServiceServer)

func RegisterUserServiceHTTPServer

func RegisterUserServiceHTTPServer(s *http.Server, srv UserServiceHTTPServer)

func RegisterUserServiceServer

func RegisterUserServiceServer(s grpc.ServiceRegistrar, srv UserServiceServer)

Types

type Car

type Car struct {
	CarId  string                  `protobuf:"bytes,1,opt,name=car_id,proto3" json:"car_id,omitempty"`
	UserId *wrapperspb.StringValue `protobuf:"bytes,2,opt,name=user_id,proto3" json:"user_id,omitempty"`
	// contains filtered or unexported fields
}

func (*Car) Descriptor deprecated

func (*Car) Descriptor() ([]byte, []int)

Deprecated: Use Car.ProtoReflect.Descriptor instead.

func (*Car) GetCarId

func (x *Car) GetCarId() string

func (*Car) GetUserId

func (x *Car) GetUserId() *wrapperspb.StringValue

func (*Car) ProtoMessage

func (*Car) ProtoMessage()

func (*Car) ProtoReflect

func (x *Car) ProtoReflect() protoreflect.Message

func (*Car) Reset

func (x *Car) Reset()

func (*Car) String

func (x *Car) String() string

type CarId

type CarId struct {
	CarId string `protobuf:"bytes,1,opt,name=car_id,proto3" json:"car_id,omitempty"`
	// contains filtered or unexported fields
}

func (*CarId) Descriptor deprecated

func (*CarId) Descriptor() ([]byte, []int)

Deprecated: Use CarId.ProtoReflect.Descriptor instead.

func (*CarId) GetCarId

func (x *CarId) GetCarId() string

func (*CarId) ProtoMessage

func (*CarId) ProtoMessage()

func (*CarId) ProtoReflect

func (x *CarId) ProtoReflect() protoreflect.Message

func (*CarId) Reset

func (x *CarId) Reset()

func (*CarId) String

func (x *CarId) String() string

type CarIdAndUserId

type CarIdAndUserId struct {
	CarId  string `protobuf:"bytes,1,opt,name=car_id,proto3" json:"car_id,omitempty"`
	UserId string `protobuf:"bytes,2,opt,name=user_id,proto3" json:"user_id,omitempty"`
	// contains filtered or unexported fields
}

func (*CarIdAndUserId) Descriptor deprecated

func (*CarIdAndUserId) Descriptor() ([]byte, []int)

Deprecated: Use CarIdAndUserId.ProtoReflect.Descriptor instead.

func (*CarIdAndUserId) GetCarId

func (x *CarIdAndUserId) GetCarId() string

func (*CarIdAndUserId) GetUserId

func (x *CarIdAndUserId) GetUserId() string

func (*CarIdAndUserId) ProtoMessage

func (*CarIdAndUserId) ProtoMessage()

func (*CarIdAndUserId) ProtoReflect

func (x *CarIdAndUserId) ProtoReflect() protoreflect.Message

func (*CarIdAndUserId) Reset

func (x *CarIdAndUserId) Reset()

func (*CarIdAndUserId) String

func (x *CarIdAndUserId) String() string

type CarPageQuery

type CarPageQuery struct {
	CarId         string                  `protobuf:"bytes,1,opt,name=car_id,proto3" json:"car_id,omitempty"`
	UserId        *wrapperspb.StringValue `protobuf:"bytes,2,opt,name=user_id,proto3" json:"user_id,omitempty"`
	PageIndex     int32                   `protobuf:"varint,3,opt,name=page_index,proto3" json:"page_index,omitempty"`
	PageSize      int32                   `protobuf:"varint,4,opt,name=page_size,proto3" json:"page_size,omitempty"`
	PageDataCount *wrapperspb.BoolValue   `protobuf:"bytes,5,opt,name=page_data_count,proto3" json:"page_data_count,omitempty"`
	// contains filtered or unexported fields
}

func (*CarPageQuery) Descriptor deprecated

func (*CarPageQuery) Descriptor() ([]byte, []int)

Deprecated: Use CarPageQuery.ProtoReflect.Descriptor instead.

func (*CarPageQuery) GetCarId

func (x *CarPageQuery) GetCarId() string

func (*CarPageQuery) GetPageDataCount

func (x *CarPageQuery) GetPageDataCount() *wrapperspb.BoolValue

func (*CarPageQuery) GetPageIndex

func (x *CarPageQuery) GetPageIndex() int32

func (*CarPageQuery) GetPageSize

func (x *CarPageQuery) GetPageSize() int32

func (*CarPageQuery) GetUserId

func (x *CarPageQuery) GetUserId() *wrapperspb.StringValue

func (*CarPageQuery) ProtoMessage

func (*CarPageQuery) ProtoMessage()

func (*CarPageQuery) ProtoReflect

func (x *CarPageQuery) ProtoReflect() protoreflect.Message

func (*CarPageQuery) Reset

func (x *CarPageQuery) Reset()

func (*CarPageQuery) String

func (x *CarPageQuery) String() string

type CarServiceClient

type CarServiceClient interface {
	Create(ctx context.Context, in *Car, opts ...grpc.CallOption) (*CarId, error)
	Update(ctx context.Context, in *Car, opts ...grpc.CallOption) (*emptypb.Empty, error)
	Delete(ctx context.Context, in *CarId, opts ...grpc.CallOption) (*emptypb.Empty, error)
	FindById(ctx context.Context, in *CarId, opts ...grpc.CallOption) (*Car, error)
	Find(ctx context.Context, in *CarPageQuery, opts ...grpc.CallOption) (*CarWithCount, error)
	Count(ctx context.Context, in *Car, opts ...grpc.CallOption) (*CountNumber, error)
}

CarServiceClient is the client API for CarService 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 NewCarServiceClient

func NewCarServiceClient(cc grpc.ClientConnInterface) CarServiceClient

type CarServiceHTTPClient

type CarServiceHTTPClient interface {
	Count(ctx context.Context, req *Car, opts ...http.CallOption) (rsp *CountNumber, err error)
	Create(ctx context.Context, req *Car, opts ...http.CallOption) (rsp *CarId, err error)
	Delete(ctx context.Context, req *CarId, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
	Find(ctx context.Context, req *CarPageQuery, opts ...http.CallOption) (rsp *CarWithCount, err error)
	FindById(ctx context.Context, req *CarId, opts ...http.CallOption) (rsp *Car, err error)
	Update(ctx context.Context, req *Car, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
}

func NewCarServiceHTTPClient

func NewCarServiceHTTPClient(client *http.Client) CarServiceHTTPClient

type CarServiceHTTPClientImpl

type CarServiceHTTPClientImpl struct {
	// contains filtered or unexported fields
}

func (*CarServiceHTTPClientImpl) Count

func (c *CarServiceHTTPClientImpl) Count(ctx context.Context, in *Car, opts ...http.CallOption) (*CountNumber, error)

func (*CarServiceHTTPClientImpl) Create

func (c *CarServiceHTTPClientImpl) Create(ctx context.Context, in *Car, opts ...http.CallOption) (*CarId, error)

func (*CarServiceHTTPClientImpl) Delete

func (c *CarServiceHTTPClientImpl) Delete(ctx context.Context, in *CarId, opts ...http.CallOption) (*emptypb.Empty, error)

func (*CarServiceHTTPClientImpl) Find

func (*CarServiceHTTPClientImpl) FindById

func (c *CarServiceHTTPClientImpl) FindById(ctx context.Context, in *CarId, opts ...http.CallOption) (*Car, error)

func (*CarServiceHTTPClientImpl) Update

func (c *CarServiceHTTPClientImpl) Update(ctx context.Context, in *Car, opts ...http.CallOption) (*emptypb.Empty, error)

type CarServiceHTTPServer

type CarServiceHTTPServer interface {
	Count(context.Context, *Car) (*CountNumber, error)
	Create(context.Context, *Car) (*CarId, error)
	Delete(context.Context, *CarId) (*emptypb.Empty, error)
	Find(context.Context, *CarPageQuery) (*CarWithCount, error)
	FindById(context.Context, *CarId) (*Car, error)
	Update(context.Context, *Car) (*emptypb.Empty, error)
}

type CarServiceServer

type CarServiceServer interface {
	Create(context.Context, *Car) (*CarId, error)
	Update(context.Context, *Car) (*emptypb.Empty, error)
	Delete(context.Context, *CarId) (*emptypb.Empty, error)
	FindById(context.Context, *CarId) (*Car, error)
	Find(context.Context, *CarPageQuery) (*CarWithCount, error)
	Count(context.Context, *Car) (*CountNumber, error)
	// contains filtered or unexported methods
}

CarServiceServer is the server API for CarService service. All implementations must embed UnimplementedCarServiceServer for forward compatibility

type CarWithCount

type CarWithCount struct {
	DataCount *wrapperspb.Int32Value `protobuf:"bytes,1,opt,name=data_count,proto3" json:"data_count,omitempty"`
	Cars      []*Car                 `protobuf:"bytes,2,rep,name=Cars,proto3" json:"Cars,omitempty"`
	// contains filtered or unexported fields
}

func (*CarWithCount) Descriptor deprecated

func (*CarWithCount) Descriptor() ([]byte, []int)

Deprecated: Use CarWithCount.ProtoReflect.Descriptor instead.

func (*CarWithCount) GetCars

func (x *CarWithCount) GetCars() []*Car

func (*CarWithCount) GetDataCount

func (x *CarWithCount) GetDataCount() *wrapperspb.Int32Value

func (*CarWithCount) ProtoMessage

func (*CarWithCount) ProtoMessage()

func (*CarWithCount) ProtoReflect

func (x *CarWithCount) ProtoReflect() protoreflect.Message

func (*CarWithCount) Reset

func (x *CarWithCount) Reset()

func (*CarWithCount) String

func (x *CarWithCount) String() string

type Cars

type Cars struct {
	DataList []*Car `protobuf:"bytes,1,rep,name=data_list,proto3" json:"data_list,omitempty"`
	// contains filtered or unexported fields
}

func (*Cars) Descriptor deprecated

func (*Cars) Descriptor() ([]byte, []int)

Deprecated: Use Cars.ProtoReflect.Descriptor instead.

func (*Cars) GetDataList

func (x *Cars) GetDataList() []*Car

func (*Cars) ProtoMessage

func (*Cars) ProtoMessage()

func (*Cars) ProtoReflect

func (x *Cars) ProtoReflect() protoreflect.Message

func (*Cars) Reset

func (x *Cars) Reset()

func (*Cars) String

func (x *Cars) String() string

type CountNumber

type CountNumber struct {
	Value int32 `protobuf:"varint,1,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

func (*CountNumber) Descriptor deprecated

func (*CountNumber) Descriptor() ([]byte, []int)

Deprecated: Use CountNumber.ProtoReflect.Descriptor instead.

func (*CountNumber) GetValue

func (x *CountNumber) GetValue() int32

func (*CountNumber) ProtoMessage

func (*CountNumber) ProtoMessage()

func (*CountNumber) ProtoReflect

func (x *CountNumber) ProtoReflect() protoreflect.Message

func (*CountNumber) Reset

func (x *CountNumber) Reset()

func (*CountNumber) String

func (x *CountNumber) String() string

type Dept

type Dept struct {
	DeptId string `protobuf:"bytes,1,opt,name=dept_id,proto3" json:"dept_id,omitempty"`
	// contains filtered or unexported fields
}

func (*Dept) Descriptor deprecated

func (*Dept) Descriptor() ([]byte, []int)

Deprecated: Use Dept.ProtoReflect.Descriptor instead.

func (*Dept) GetDeptId

func (x *Dept) GetDeptId() string

func (*Dept) ProtoMessage

func (*Dept) ProtoMessage()

func (*Dept) ProtoReflect

func (x *Dept) ProtoReflect() protoreflect.Message

func (*Dept) Reset

func (x *Dept) Reset()

func (*Dept) String

func (x *Dept) String() string

type DeptAddUserReq

type DeptAddUserReq struct {
	UserId string                  `protobuf:"bytes,1,opt,name=user_id,proto3" json:"user_id,omitempty"`
	Phone  *wrapperspb.StringValue `protobuf:"bytes,2,opt,name=phone,proto3" json:"phone,omitempty"`
	Race   DeptAddUserReq_Race     `protobuf:"varint,3,opt,name=race,proto3,enum=contacts.DeptAddUserReq_Race" json:"race,omitempty"`
	DeptId string                  `protobuf:"bytes,4,opt,name=dept_id,proto3" json:"dept_id,omitempty"`
	// contains filtered or unexported fields
}

func (*DeptAddUserReq) Descriptor deprecated

func (*DeptAddUserReq) Descriptor() ([]byte, []int)

Deprecated: Use DeptAddUserReq.ProtoReflect.Descriptor instead.

func (*DeptAddUserReq) GetDeptId

func (x *DeptAddUserReq) GetDeptId() string

func (*DeptAddUserReq) GetPhone

func (x *DeptAddUserReq) GetPhone() *wrapperspb.StringValue

func (*DeptAddUserReq) GetRace

func (x *DeptAddUserReq) GetRace() DeptAddUserReq_Race

func (*DeptAddUserReq) GetUserId

func (x *DeptAddUserReq) GetUserId() string

func (*DeptAddUserReq) ProtoMessage

func (*DeptAddUserReq) ProtoMessage()

func (*DeptAddUserReq) ProtoReflect

func (x *DeptAddUserReq) ProtoReflect() protoreflect.Message

func (*DeptAddUserReq) Reset

func (x *DeptAddUserReq) Reset()

func (*DeptAddUserReq) String

func (x *DeptAddUserReq) String() string

type DeptAddUserReq_Race

type DeptAddUserReq_Race int32
const (
	DeptAddUserReq_RACE_UNSPECIFIED DeptAddUserReq_Race = 0
	DeptAddUserReq_YELLOW           DeptAddUserReq_Race = 1
	DeptAddUserReq_WHITE            DeptAddUserReq_Race = 2
	DeptAddUserReq_BLACK            DeptAddUserReq_Race = 3
)

func (DeptAddUserReq_Race) Descriptor

func (DeptAddUserReq_Race) Enum

func (DeptAddUserReq_Race) EnumDescriptor deprecated

func (DeptAddUserReq_Race) EnumDescriptor() ([]byte, []int)

Deprecated: Use DeptAddUserReq_Race.Descriptor instead.

func (DeptAddUserReq_Race) Number

func (DeptAddUserReq_Race) String

func (x DeptAddUserReq_Race) String() string

func (DeptAddUserReq_Race) Type

type DeptFindUsersReq

type DeptFindUsersReq struct {
	UserId    string                  `protobuf:"bytes,1,opt,name=user_id,proto3" json:"user_id,omitempty"`
	Phone     *wrapperspb.StringValue `protobuf:"bytes,2,opt,name=phone,proto3" json:"phone,omitempty"`
	PageIndex int32                   `protobuf:"varint,3,opt,name=page_index,proto3" json:"page_index,omitempty"`
	PageSize  int32                   `protobuf:"varint,4,opt,name=page_size,proto3" json:"page_size,omitempty"`
	DeptId    string                  `protobuf:"bytes,5,opt,name=dept_id,proto3" json:"dept_id,omitempty"`
	// contains filtered or unexported fields
}

func (*DeptFindUsersReq) Descriptor deprecated

func (*DeptFindUsersReq) Descriptor() ([]byte, []int)

Deprecated: Use DeptFindUsersReq.ProtoReflect.Descriptor instead.

func (*DeptFindUsersReq) GetDeptId

func (x *DeptFindUsersReq) GetDeptId() string

func (*DeptFindUsersReq) GetPageIndex

func (x *DeptFindUsersReq) GetPageIndex() int32

func (*DeptFindUsersReq) GetPageSize

func (x *DeptFindUsersReq) GetPageSize() int32

func (*DeptFindUsersReq) GetPhone

func (x *DeptFindUsersReq) GetPhone() *wrapperspb.StringValue

func (*DeptFindUsersReq) GetUserId

func (x *DeptFindUsersReq) GetUserId() string

func (*DeptFindUsersReq) ProtoMessage

func (*DeptFindUsersReq) ProtoMessage()

func (*DeptFindUsersReq) ProtoReflect

func (x *DeptFindUsersReq) ProtoReflect() protoreflect.Message

func (*DeptFindUsersReq) Reset

func (x *DeptFindUsersReq) Reset()

func (*DeptFindUsersReq) String

func (x *DeptFindUsersReq) String() string

type DeptFindUsersRes

type DeptFindUsersRes struct {
	DataCount int32   `protobuf:"varint,1,opt,name=data_count,proto3" json:"data_count,omitempty"`
	Users     []*User `protobuf:"bytes,2,rep,name=Users,proto3" json:"Users,omitempty"`
	// contains filtered or unexported fields
}

func (*DeptFindUsersRes) Descriptor deprecated

func (*DeptFindUsersRes) Descriptor() ([]byte, []int)

Deprecated: Use DeptFindUsersRes.ProtoReflect.Descriptor instead.

func (*DeptFindUsersRes) GetDataCount

func (x *DeptFindUsersRes) GetDataCount() int32

func (*DeptFindUsersRes) GetUsers

func (x *DeptFindUsersRes) GetUsers() []*User

func (*DeptFindUsersRes) ProtoMessage

func (*DeptFindUsersRes) ProtoMessage()

func (*DeptFindUsersRes) ProtoReflect

func (x *DeptFindUsersRes) ProtoReflect() protoreflect.Message

func (*DeptFindUsersRes) Reset

func (x *DeptFindUsersRes) Reset()

func (*DeptFindUsersRes) String

func (x *DeptFindUsersRes) String() string

type DeptId

type DeptId struct {
	DeptId string `protobuf:"bytes,1,opt,name=dept_id,proto3" json:"dept_id,omitempty"`
	// contains filtered or unexported fields
}

func (*DeptId) Descriptor deprecated

func (*DeptId) Descriptor() ([]byte, []int)

Deprecated: Use DeptId.ProtoReflect.Descriptor instead.

func (*DeptId) GetDeptId

func (x *DeptId) GetDeptId() string

func (*DeptId) ProtoMessage

func (*DeptId) ProtoMessage()

func (*DeptId) ProtoReflect

func (x *DeptId) ProtoReflect() protoreflect.Message

func (*DeptId) Reset

func (x *DeptId) Reset()

func (*DeptId) String

func (x *DeptId) String() string

type DeptIdAndUserId

type DeptIdAndUserId struct {
	DeptId string `protobuf:"bytes,1,opt,name=dept_id,proto3" json:"dept_id,omitempty"`
	UserId string `protobuf:"bytes,2,opt,name=user_id,proto3" json:"user_id,omitempty"`
	// contains filtered or unexported fields
}

func (*DeptIdAndUserId) Descriptor deprecated

func (*DeptIdAndUserId) Descriptor() ([]byte, []int)

Deprecated: Use DeptIdAndUserId.ProtoReflect.Descriptor instead.

func (*DeptIdAndUserId) GetDeptId

func (x *DeptIdAndUserId) GetDeptId() string

func (*DeptIdAndUserId) GetUserId

func (x *DeptIdAndUserId) GetUserId() string

func (*DeptIdAndUserId) ProtoMessage

func (*DeptIdAndUserId) ProtoMessage()

func (*DeptIdAndUserId) ProtoReflect

func (x *DeptIdAndUserId) ProtoReflect() protoreflect.Message

func (*DeptIdAndUserId) Reset

func (x *DeptIdAndUserId) Reset()

func (*DeptIdAndUserId) String

func (x *DeptIdAndUserId) String() string

type DeptPageQuery

type DeptPageQuery struct {
	DeptId        string                `protobuf:"bytes,1,opt,name=dept_id,proto3" json:"dept_id,omitempty"`
	PageIndex     int32                 `protobuf:"varint,2,opt,name=page_index,proto3" json:"page_index,omitempty"`
	PageSize      int32                 `protobuf:"varint,3,opt,name=page_size,proto3" json:"page_size,omitempty"`
	PageDataCount *wrapperspb.BoolValue `protobuf:"bytes,4,opt,name=page_data_count,proto3" json:"page_data_count,omitempty"`
	// contains filtered or unexported fields
}

func (*DeptPageQuery) Descriptor deprecated

func (*DeptPageQuery) Descriptor() ([]byte, []int)

Deprecated: Use DeptPageQuery.ProtoReflect.Descriptor instead.

func (*DeptPageQuery) GetDeptId

func (x *DeptPageQuery) GetDeptId() string

func (*DeptPageQuery) GetPageDataCount

func (x *DeptPageQuery) GetPageDataCount() *wrapperspb.BoolValue

func (*DeptPageQuery) GetPageIndex

func (x *DeptPageQuery) GetPageIndex() int32

func (*DeptPageQuery) GetPageSize

func (x *DeptPageQuery) GetPageSize() int32

func (*DeptPageQuery) ProtoMessage

func (*DeptPageQuery) ProtoMessage()

func (*DeptPageQuery) ProtoReflect

func (x *DeptPageQuery) ProtoReflect() protoreflect.Message

func (*DeptPageQuery) Reset

func (x *DeptPageQuery) Reset()

func (*DeptPageQuery) String

func (x *DeptPageQuery) String() string

type DeptRemoveUserReq

type DeptRemoveUserReq struct {
	UserId    string                  `protobuf:"bytes,1,opt,name=user_id,proto3" json:"user_id,omitempty"`
	Phone     *wrapperspb.StringValue `protobuf:"bytes,2,opt,name=phone,proto3" json:"phone,omitempty"`
	PageIndex int32                   `protobuf:"varint,3,opt,name=page_index,proto3" json:"page_index,omitempty"`
	PageSize  int32                   `protobuf:"varint,4,opt,name=page_size,proto3" json:"page_size,omitempty"`
	DeptId    string                  `protobuf:"bytes,5,opt,name=dept_id,proto3" json:"dept_id,omitempty"`
	// contains filtered or unexported fields
}

func (*DeptRemoveUserReq) Descriptor deprecated

func (*DeptRemoveUserReq) Descriptor() ([]byte, []int)

Deprecated: Use DeptRemoveUserReq.ProtoReflect.Descriptor instead.

func (*DeptRemoveUserReq) GetDeptId

func (x *DeptRemoveUserReq) GetDeptId() string

func (*DeptRemoveUserReq) GetPageIndex

func (x *DeptRemoveUserReq) GetPageIndex() int32

func (*DeptRemoveUserReq) GetPageSize

func (x *DeptRemoveUserReq) GetPageSize() int32

func (*DeptRemoveUserReq) GetPhone

func (x *DeptRemoveUserReq) GetPhone() *wrapperspb.StringValue

func (*DeptRemoveUserReq) GetUserId

func (x *DeptRemoveUserReq) GetUserId() string

func (*DeptRemoveUserReq) ProtoMessage

func (*DeptRemoveUserReq) ProtoMessage()

func (*DeptRemoveUserReq) ProtoReflect

func (x *DeptRemoveUserReq) ProtoReflect() protoreflect.Message

func (*DeptRemoveUserReq) Reset

func (x *DeptRemoveUserReq) Reset()

func (*DeptRemoveUserReq) String

func (x *DeptRemoveUserReq) String() string

type DeptServiceClient

type DeptServiceClient interface {
	Create(ctx context.Context, in *Dept, opts ...grpc.CallOption) (*DeptId, error)
	Update(ctx context.Context, in *Dept, opts ...grpc.CallOption) (*emptypb.Empty, error)
	Delete(ctx context.Context, in *DeptId, opts ...grpc.CallOption) (*emptypb.Empty, error)
	FindById(ctx context.Context, in *DeptId, opts ...grpc.CallOption) (*Dept, error)
	Find(ctx context.Context, in *DeptPageQuery, opts ...grpc.CallOption) (*DeptWithCount, error)
	Count(ctx context.Context, in *Dept, opts ...grpc.CallOption) (*CountNumber, error)
	AddUser(ctx context.Context, in *DeptAddUserReq, opts ...grpc.CallOption) (*UserId, error)
	AddUserById(ctx context.Context, in *DeptIdAndUserId, opts ...grpc.CallOption) (*emptypb.Empty, error)
	RemoveUser(ctx context.Context, in *DeptRemoveUserReq, opts ...grpc.CallOption) (*emptypb.Empty, error)
	FindUsers(ctx context.Context, in *DeptFindUsersReq, opts ...grpc.CallOption) (*DeptFindUsersRes, error)
}

DeptServiceClient is the client API for DeptService 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.

type DeptServiceHTTPClient

type DeptServiceHTTPClient interface {
	AddUser(ctx context.Context, req *DeptAddUserReq, opts ...http.CallOption) (rsp *UserId, err error)
	AddUserById(ctx context.Context, req *DeptIdAndUserId, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
	Count(ctx context.Context, req *Dept, opts ...http.CallOption) (rsp *CountNumber, err error)
	Create(ctx context.Context, req *Dept, opts ...http.CallOption) (rsp *DeptId, err error)
	Delete(ctx context.Context, req *DeptId, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
	Find(ctx context.Context, req *DeptPageQuery, opts ...http.CallOption) (rsp *DeptWithCount, err error)
	FindById(ctx context.Context, req *DeptId, opts ...http.CallOption) (rsp *Dept, err error)
	FindUsers(ctx context.Context, req *DeptFindUsersReq, opts ...http.CallOption) (rsp *DeptFindUsersRes, err error)
	RemoveUser(ctx context.Context, req *DeptRemoveUserReq, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
	Update(ctx context.Context, req *Dept, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
}

func NewDeptServiceHTTPClient

func NewDeptServiceHTTPClient(client *http.Client) DeptServiceHTTPClient

type DeptServiceHTTPClientImpl

type DeptServiceHTTPClientImpl struct {
	// contains filtered or unexported fields
}

func (*DeptServiceHTTPClientImpl) AddUser

func (*DeptServiceHTTPClientImpl) AddUserById

func (*DeptServiceHTTPClientImpl) Count

func (*DeptServiceHTTPClientImpl) Create

func (c *DeptServiceHTTPClientImpl) Create(ctx context.Context, in *Dept, opts ...http.CallOption) (*DeptId, error)

func (*DeptServiceHTTPClientImpl) Delete

func (*DeptServiceHTTPClientImpl) Find

func (*DeptServiceHTTPClientImpl) FindById

func (c *DeptServiceHTTPClientImpl) FindById(ctx context.Context, in *DeptId, opts ...http.CallOption) (*Dept, error)

func (*DeptServiceHTTPClientImpl) FindUsers

func (*DeptServiceHTTPClientImpl) RemoveUser

func (*DeptServiceHTTPClientImpl) Update

func (c *DeptServiceHTTPClientImpl) Update(ctx context.Context, in *Dept, opts ...http.CallOption) (*emptypb.Empty, error)

type DeptServiceServer

type DeptServiceServer interface {
	Create(context.Context, *Dept) (*DeptId, error)
	Update(context.Context, *Dept) (*emptypb.Empty, error)
	Delete(context.Context, *DeptId) (*emptypb.Empty, error)
	FindById(context.Context, *DeptId) (*Dept, error)
	Find(context.Context, *DeptPageQuery) (*DeptWithCount, error)
	Count(context.Context, *Dept) (*CountNumber, error)
	AddUser(context.Context, *DeptAddUserReq) (*UserId, error)
	AddUserById(context.Context, *DeptIdAndUserId) (*emptypb.Empty, error)
	RemoveUser(context.Context, *DeptRemoveUserReq) (*emptypb.Empty, error)
	FindUsers(context.Context, *DeptFindUsersReq) (*DeptFindUsersRes, error)
	// contains filtered or unexported methods
}

DeptServiceServer is the server API for DeptService service. All implementations must embed UnimplementedDeptServiceServer for forward compatibility

type DeptWithCount

type DeptWithCount struct {
	DataCount *wrapperspb.Int32Value `protobuf:"bytes,1,opt,name=data_count,proto3" json:"data_count,omitempty"`
	Depts     []*Dept                `protobuf:"bytes,2,rep,name=Depts,proto3" json:"Depts,omitempty"`
	// contains filtered or unexported fields
}

func (*DeptWithCount) Descriptor deprecated

func (*DeptWithCount) Descriptor() ([]byte, []int)

Deprecated: Use DeptWithCount.ProtoReflect.Descriptor instead.

func (*DeptWithCount) GetDataCount

func (x *DeptWithCount) GetDataCount() *wrapperspb.Int32Value

func (*DeptWithCount) GetDepts

func (x *DeptWithCount) GetDepts() []*Dept

func (*DeptWithCount) ProtoMessage

func (*DeptWithCount) ProtoMessage()

func (*DeptWithCount) ProtoReflect

func (x *DeptWithCount) ProtoReflect() protoreflect.Message

func (*DeptWithCount) Reset

func (x *DeptWithCount) Reset()

func (*DeptWithCount) String

func (x *DeptWithCount) String() string

type Depts

type Depts struct {
	DataList []*Dept `protobuf:"bytes,1,rep,name=data_list,proto3" json:"data_list,omitempty"`
	// contains filtered or unexported fields
}

func (*Depts) Descriptor deprecated

func (*Depts) Descriptor() ([]byte, []int)

Deprecated: Use Depts.ProtoReflect.Descriptor instead.

func (*Depts) GetDataList

func (x *Depts) GetDataList() []*Dept

func (*Depts) ProtoMessage

func (*Depts) ProtoMessage()

func (*Depts) ProtoReflect

func (x *Depts) ProtoReflect() protoreflect.Message

func (*Depts) Reset

func (x *Depts) Reset()

func (*Depts) String

func (x *Depts) String() string

type UnimplementedCarServiceServer

type UnimplementedCarServiceServer struct {
}

UnimplementedCarServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedCarServiceServer) Count

func (UnimplementedCarServiceServer) Create

func (UnimplementedCarServiceServer) Delete

func (UnimplementedCarServiceServer) Find

func (UnimplementedCarServiceServer) FindById

func (UnimplementedCarServiceServer) Update

type UnimplementedDeptServiceServer

type UnimplementedDeptServiceServer struct {
}

UnimplementedDeptServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedDeptServiceServer) AddUser

func (UnimplementedDeptServiceServer) AddUserById

func (UnimplementedDeptServiceServer) Count

func (UnimplementedDeptServiceServer) Create

func (UnimplementedDeptServiceServer) Delete

func (UnimplementedDeptServiceServer) Find

func (UnimplementedDeptServiceServer) FindById

func (UnimplementedDeptServiceServer) FindUsers

func (UnimplementedDeptServiceServer) RemoveUser

func (UnimplementedDeptServiceServer) Update

type UnimplementedUserServiceServer

type UnimplementedUserServiceServer struct {
}

UnimplementedUserServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedUserServiceServer) AddCar

func (UnimplementedUserServiceServer) AddCarById

func (UnimplementedUserServiceServer) Count

func (UnimplementedUserServiceServer) Create

func (UnimplementedUserServiceServer) Delete

func (UnimplementedUserServiceServer) Find

func (UnimplementedUserServiceServer) FindById

func (UnimplementedUserServiceServer) FindCars

func (UnimplementedUserServiceServer) FindDepts

func (UnimplementedUserServiceServer) RemoveCar

func (UnimplementedUserServiceServer) Update

type UnsafeCarServiceServer

type UnsafeCarServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeCarServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to CarServiceServer will result in compilation errors.

type UnsafeDeptServiceServer

type UnsafeDeptServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeDeptServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to DeptServiceServer will result in compilation errors.

type UnsafeUserServiceServer

type UnsafeUserServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeUserServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to UserServiceServer will result in compilation errors.

type User

type User struct {
	UserId string                  `protobuf:"bytes,1,opt,name=user_id,proto3" json:"user_id,omitempty"`
	Phone  *wrapperspb.StringValue `protobuf:"bytes,2,opt,name=phone,proto3" json:"phone,omitempty"`
	Race   User_Race               `protobuf:"varint,3,opt,name=race,proto3,enum=contacts.User_Race" json:"race,omitempty"`
	// contains filtered or unexported fields
}

func (*User) Descriptor deprecated

func (*User) Descriptor() ([]byte, []int)

Deprecated: Use User.ProtoReflect.Descriptor instead.

func (*User) GetPhone

func (x *User) GetPhone() *wrapperspb.StringValue

func (*User) GetRace

func (x *User) GetRace() User_Race

func (*User) GetUserId

func (x *User) GetUserId() string

func (*User) ProtoMessage

func (*User) ProtoMessage()

func (*User) ProtoReflect

func (x *User) ProtoReflect() protoreflect.Message

func (*User) Reset

func (x *User) Reset()

func (*User) String

func (x *User) String() string

type UserAddDeptReq

type UserAddDeptReq struct {
	DeptId string `protobuf:"bytes,1,opt,name=dept_id,proto3" json:"dept_id,omitempty"`
	UserId string `protobuf:"bytes,2,opt,name=user_id,proto3" json:"user_id,omitempty"`
	// contains filtered or unexported fields
}

func (*UserAddDeptReq) Descriptor deprecated

func (*UserAddDeptReq) Descriptor() ([]byte, []int)

Deprecated: Use UserAddDeptReq.ProtoReflect.Descriptor instead.

func (*UserAddDeptReq) GetDeptId

func (x *UserAddDeptReq) GetDeptId() string

func (*UserAddDeptReq) GetUserId

func (x *UserAddDeptReq) GetUserId() string

func (*UserAddDeptReq) ProtoMessage

func (*UserAddDeptReq) ProtoMessage()

func (*UserAddDeptReq) ProtoReflect

func (x *UserAddDeptReq) ProtoReflect() protoreflect.Message

func (*UserAddDeptReq) Reset

func (x *UserAddDeptReq) Reset()

func (*UserAddDeptReq) String

func (x *UserAddDeptReq) String() string

type UserFindCarsReq

type UserFindCarsReq struct {
	CarId     string `protobuf:"bytes,1,opt,name=car_id,proto3" json:"car_id,omitempty"`
	PageIndex int32  `protobuf:"varint,2,opt,name=page_index,proto3" json:"page_index,omitempty"`
	PageSize  int32  `protobuf:"varint,3,opt,name=page_size,proto3" json:"page_size,omitempty"`
	UserId    string `protobuf:"bytes,4,opt,name=user_id,proto3" json:"user_id,omitempty"`
	// contains filtered or unexported fields
}

func (*UserFindCarsReq) Descriptor deprecated

func (*UserFindCarsReq) Descriptor() ([]byte, []int)

Deprecated: Use UserFindCarsReq.ProtoReflect.Descriptor instead.

func (*UserFindCarsReq) GetCarId

func (x *UserFindCarsReq) GetCarId() string

func (*UserFindCarsReq) GetPageIndex

func (x *UserFindCarsReq) GetPageIndex() int32

func (*UserFindCarsReq) GetPageSize

func (x *UserFindCarsReq) GetPageSize() int32

func (*UserFindCarsReq) GetUserId

func (x *UserFindCarsReq) GetUserId() string

func (*UserFindCarsReq) ProtoMessage

func (*UserFindCarsReq) ProtoMessage()

func (*UserFindCarsReq) ProtoReflect

func (x *UserFindCarsReq) ProtoReflect() protoreflect.Message

func (*UserFindCarsReq) Reset

func (x *UserFindCarsReq) Reset()

func (*UserFindCarsReq) String

func (x *UserFindCarsReq) String() string

type UserFindCarsRes

type UserFindCarsRes struct {
	DataCount int32  `protobuf:"varint,1,opt,name=data_count,proto3" json:"data_count,omitempty"`
	Cars      []*Car `protobuf:"bytes,2,rep,name=Cars,proto3" json:"Cars,omitempty"`
	// contains filtered or unexported fields
}

func (*UserFindCarsRes) Descriptor deprecated

func (*UserFindCarsRes) Descriptor() ([]byte, []int)

Deprecated: Use UserFindCarsRes.ProtoReflect.Descriptor instead.

func (*UserFindCarsRes) GetCars

func (x *UserFindCarsRes) GetCars() []*Car

func (*UserFindCarsRes) GetDataCount

func (x *UserFindCarsRes) GetDataCount() int32

func (*UserFindCarsRes) ProtoMessage

func (*UserFindCarsRes) ProtoMessage()

func (*UserFindCarsRes) ProtoReflect

func (x *UserFindCarsRes) ProtoReflect() protoreflect.Message

func (*UserFindCarsRes) Reset

func (x *UserFindCarsRes) Reset()

func (*UserFindCarsRes) String

func (x *UserFindCarsRes) String() string

type UserFindDeptsReq

type UserFindDeptsReq struct {
	DeptId    string `protobuf:"bytes,1,opt,name=dept_id,proto3" json:"dept_id,omitempty"`
	PageIndex int32  `protobuf:"varint,2,opt,name=page_index,proto3" json:"page_index,omitempty"`
	PageSize  int32  `protobuf:"varint,3,opt,name=page_size,proto3" json:"page_size,omitempty"`
	UserId    string `protobuf:"bytes,4,opt,name=user_id,proto3" json:"user_id,omitempty"`
	// contains filtered or unexported fields
}

func (*UserFindDeptsReq) Descriptor deprecated

func (*UserFindDeptsReq) Descriptor() ([]byte, []int)

Deprecated: Use UserFindDeptsReq.ProtoReflect.Descriptor instead.

func (*UserFindDeptsReq) GetDeptId

func (x *UserFindDeptsReq) GetDeptId() string

func (*UserFindDeptsReq) GetPageIndex

func (x *UserFindDeptsReq) GetPageIndex() int32

func (*UserFindDeptsReq) GetPageSize

func (x *UserFindDeptsReq) GetPageSize() int32

func (*UserFindDeptsReq) GetUserId

func (x *UserFindDeptsReq) GetUserId() string

func (*UserFindDeptsReq) ProtoMessage

func (*UserFindDeptsReq) ProtoMessage()

func (*UserFindDeptsReq) ProtoReflect

func (x *UserFindDeptsReq) ProtoReflect() protoreflect.Message

func (*UserFindDeptsReq) Reset

func (x *UserFindDeptsReq) Reset()

func (*UserFindDeptsReq) String

func (x *UserFindDeptsReq) String() string

type UserFindDeptsRes

type UserFindDeptsRes struct {
	DataCount int32   `protobuf:"varint,1,opt,name=data_count,proto3" json:"data_count,omitempty"`
	Depts     []*Dept `protobuf:"bytes,2,rep,name=Depts,proto3" json:"Depts,omitempty"`
	// contains filtered or unexported fields
}

func (*UserFindDeptsRes) Descriptor deprecated

func (*UserFindDeptsRes) Descriptor() ([]byte, []int)

Deprecated: Use UserFindDeptsRes.ProtoReflect.Descriptor instead.

func (*UserFindDeptsRes) GetDataCount

func (x *UserFindDeptsRes) GetDataCount() int32

func (*UserFindDeptsRes) GetDepts

func (x *UserFindDeptsRes) GetDepts() []*Dept

func (*UserFindDeptsRes) ProtoMessage

func (*UserFindDeptsRes) ProtoMessage()

func (*UserFindDeptsRes) ProtoReflect

func (x *UserFindDeptsRes) ProtoReflect() protoreflect.Message

func (*UserFindDeptsRes) Reset

func (x *UserFindDeptsRes) Reset()

func (*UserFindDeptsRes) String

func (x *UserFindDeptsRes) String() string

type UserId

type UserId struct {
	UserId string `protobuf:"bytes,1,opt,name=user_id,proto3" json:"user_id,omitempty"`
	// contains filtered or unexported fields
}

func (*UserId) Descriptor deprecated

func (*UserId) Descriptor() ([]byte, []int)

Deprecated: Use UserId.ProtoReflect.Descriptor instead.

func (*UserId) GetUserId

func (x *UserId) GetUserId() string

func (*UserId) ProtoMessage

func (*UserId) ProtoMessage()

func (*UserId) ProtoReflect

func (x *UserId) ProtoReflect() protoreflect.Message

func (*UserId) Reset

func (x *UserId) Reset()

func (*UserId) String

func (x *UserId) String() string

type UserIdAndCarId

type UserIdAndCarId struct {
	UserId string `protobuf:"bytes,1,opt,name=user_id,proto3" json:"user_id,omitempty"`
	CarId  string `protobuf:"bytes,2,opt,name=car_id,proto3" json:"car_id,omitempty"`
	// contains filtered or unexported fields
}

func (*UserIdAndCarId) Descriptor deprecated

func (*UserIdAndCarId) Descriptor() ([]byte, []int)

Deprecated: Use UserIdAndCarId.ProtoReflect.Descriptor instead.

func (*UserIdAndCarId) GetCarId

func (x *UserIdAndCarId) GetCarId() string

func (*UserIdAndCarId) GetUserId

func (x *UserIdAndCarId) GetUserId() string

func (*UserIdAndCarId) ProtoMessage

func (*UserIdAndCarId) ProtoMessage()

func (*UserIdAndCarId) ProtoReflect

func (x *UserIdAndCarId) ProtoReflect() protoreflect.Message

func (*UserIdAndCarId) Reset

func (x *UserIdAndCarId) Reset()

func (*UserIdAndCarId) String

func (x *UserIdAndCarId) String() string

type UserIdAndDeptId

type UserIdAndDeptId struct {
	UserId string `protobuf:"bytes,1,opt,name=user_id,proto3" json:"user_id,omitempty"`
	DeptId string `protobuf:"bytes,2,opt,name=dept_id,proto3" json:"dept_id,omitempty"`
	// contains filtered or unexported fields
}

func (*UserIdAndDeptId) Descriptor deprecated

func (*UserIdAndDeptId) Descriptor() ([]byte, []int)

Deprecated: Use UserIdAndDeptId.ProtoReflect.Descriptor instead.

func (*UserIdAndDeptId) GetDeptId

func (x *UserIdAndDeptId) GetDeptId() string

func (*UserIdAndDeptId) GetUserId

func (x *UserIdAndDeptId) GetUserId() string

func (*UserIdAndDeptId) ProtoMessage

func (*UserIdAndDeptId) ProtoMessage()

func (*UserIdAndDeptId) ProtoReflect

func (x *UserIdAndDeptId) ProtoReflect() protoreflect.Message

func (*UserIdAndDeptId) Reset

func (x *UserIdAndDeptId) Reset()

func (*UserIdAndDeptId) String

func (x *UserIdAndDeptId) String() string

type UserPageQuery

type UserPageQuery struct {
	UserId        string                  `protobuf:"bytes,1,opt,name=user_id,proto3" json:"user_id,omitempty"`
	Phone         *wrapperspb.StringValue `protobuf:"bytes,2,opt,name=phone,proto3" json:"phone,omitempty"`
	Race          UserPageQuery_Race      `protobuf:"varint,3,opt,name=race,proto3,enum=contacts.UserPageQuery_Race" json:"race,omitempty"`
	PageIndex     int32                   `protobuf:"varint,4,opt,name=page_index,proto3" json:"page_index,omitempty"`
	PageSize      int32                   `protobuf:"varint,5,opt,name=page_size,proto3" json:"page_size,omitempty"`
	PageDataCount *wrapperspb.BoolValue   `protobuf:"bytes,6,opt,name=page_data_count,proto3" json:"page_data_count,omitempty"`
	// contains filtered or unexported fields
}

func (*UserPageQuery) Descriptor deprecated

func (*UserPageQuery) Descriptor() ([]byte, []int)

Deprecated: Use UserPageQuery.ProtoReflect.Descriptor instead.

func (*UserPageQuery) GetPageDataCount

func (x *UserPageQuery) GetPageDataCount() *wrapperspb.BoolValue

func (*UserPageQuery) GetPageIndex

func (x *UserPageQuery) GetPageIndex() int32

func (*UserPageQuery) GetPageSize

func (x *UserPageQuery) GetPageSize() int32

func (*UserPageQuery) GetPhone

func (x *UserPageQuery) GetPhone() *wrapperspb.StringValue

func (*UserPageQuery) GetRace

func (x *UserPageQuery) GetRace() UserPageQuery_Race

func (*UserPageQuery) GetUserId

func (x *UserPageQuery) GetUserId() string

func (*UserPageQuery) ProtoMessage

func (*UserPageQuery) ProtoMessage()

func (*UserPageQuery) ProtoReflect

func (x *UserPageQuery) ProtoReflect() protoreflect.Message

func (*UserPageQuery) Reset

func (x *UserPageQuery) Reset()

func (*UserPageQuery) String

func (x *UserPageQuery) String() string

type UserPageQuery_Race

type UserPageQuery_Race int32
const (
	UserPageQuery_RACE_UNSPECIFIED UserPageQuery_Race = 0
	UserPageQuery_YELLOW           UserPageQuery_Race = 1
	UserPageQuery_WHITE            UserPageQuery_Race = 2
	UserPageQuery_BLACK            UserPageQuery_Race = 3
)

func (UserPageQuery_Race) Descriptor

func (UserPageQuery_Race) Enum

func (UserPageQuery_Race) EnumDescriptor deprecated

func (UserPageQuery_Race) EnumDescriptor() ([]byte, []int)

Deprecated: Use UserPageQuery_Race.Descriptor instead.

func (UserPageQuery_Race) Number

func (UserPageQuery_Race) String

func (x UserPageQuery_Race) String() string

func (UserPageQuery_Race) Type

type UserRemoveCarReq

type UserRemoveCarReq struct {
	CarId     string `protobuf:"bytes,1,opt,name=car_id,proto3" json:"car_id,omitempty"`
	PageIndex int32  `protobuf:"varint,2,opt,name=page_index,proto3" json:"page_index,omitempty"`
	PageSize  int32  `protobuf:"varint,3,opt,name=page_size,proto3" json:"page_size,omitempty"`
	UserId    string `protobuf:"bytes,4,opt,name=user_id,proto3" json:"user_id,omitempty"`
	// contains filtered or unexported fields
}

func (*UserRemoveCarReq) Descriptor deprecated

func (*UserRemoveCarReq) Descriptor() ([]byte, []int)

Deprecated: Use UserRemoveCarReq.ProtoReflect.Descriptor instead.

func (*UserRemoveCarReq) GetCarId

func (x *UserRemoveCarReq) GetCarId() string

func (*UserRemoveCarReq) GetPageIndex

func (x *UserRemoveCarReq) GetPageIndex() int32

func (*UserRemoveCarReq) GetPageSize

func (x *UserRemoveCarReq) GetPageSize() int32

func (*UserRemoveCarReq) GetUserId

func (x *UserRemoveCarReq) GetUserId() string

func (*UserRemoveCarReq) ProtoMessage

func (*UserRemoveCarReq) ProtoMessage()

func (*UserRemoveCarReq) ProtoReflect

func (x *UserRemoveCarReq) ProtoReflect() protoreflect.Message

func (*UserRemoveCarReq) Reset

func (x *UserRemoveCarReq) Reset()

func (*UserRemoveCarReq) String

func (x *UserRemoveCarReq) String() string

type UserServiceClient

type UserServiceClient interface {
	Create(ctx context.Context, in *User, opts ...grpc.CallOption) (*UserId, error)
	Update(ctx context.Context, in *User, opts ...grpc.CallOption) (*emptypb.Empty, error)
	Delete(ctx context.Context, in *UserId, opts ...grpc.CallOption) (*emptypb.Empty, error)
	FindById(ctx context.Context, in *UserId, opts ...grpc.CallOption) (*User, error)
	Find(ctx context.Context, in *UserPageQuery, opts ...grpc.CallOption) (*UserWithCount, error)
	Count(ctx context.Context, in *User, opts ...grpc.CallOption) (*CountNumber, error)
	AddCar(ctx context.Context, in *Car, opts ...grpc.CallOption) (*CarId, error)
	AddCarById(ctx context.Context, in *UserIdAndCarId, opts ...grpc.CallOption) (*emptypb.Empty, error)
	RemoveCar(ctx context.Context, in *UserRemoveCarReq, opts ...grpc.CallOption) (*emptypb.Empty, error)
	FindCars(ctx context.Context, in *UserFindCarsReq, opts ...grpc.CallOption) (*UserFindCarsRes, error)
	FindDepts(ctx context.Context, in *UserFindDeptsReq, opts ...grpc.CallOption) (*UserFindDeptsRes, error)
}

UserServiceClient is the client API for UserService 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.

type UserServiceHTTPClient

type UserServiceHTTPClient interface {
	AddCar(ctx context.Context, req *Car, opts ...http.CallOption) (rsp *CarId, err error)
	AddCarById(ctx context.Context, req *UserIdAndCarId, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
	Count(ctx context.Context, req *User, opts ...http.CallOption) (rsp *CountNumber, err error)
	Create(ctx context.Context, req *User, opts ...http.CallOption) (rsp *UserId, err error)
	Delete(ctx context.Context, req *UserId, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
	Find(ctx context.Context, req *UserPageQuery, opts ...http.CallOption) (rsp *UserWithCount, err error)
	FindById(ctx context.Context, req *UserId, opts ...http.CallOption) (rsp *User, err error)
	FindCars(ctx context.Context, req *UserFindCarsReq, opts ...http.CallOption) (rsp *UserFindCarsRes, err error)
	FindDepts(ctx context.Context, req *UserFindDeptsReq, opts ...http.CallOption) (rsp *UserFindDeptsRes, err error)
	RemoveCar(ctx context.Context, req *UserRemoveCarReq, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
	Update(ctx context.Context, req *User, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
}

func NewUserServiceHTTPClient

func NewUserServiceHTTPClient(client *http.Client) UserServiceHTTPClient

type UserServiceHTTPClientImpl

type UserServiceHTTPClientImpl struct {
	// contains filtered or unexported fields
}

func (*UserServiceHTTPClientImpl) AddCar

func (c *UserServiceHTTPClientImpl) AddCar(ctx context.Context, in *Car, opts ...http.CallOption) (*CarId, error)

func (*UserServiceHTTPClientImpl) AddCarById

func (*UserServiceHTTPClientImpl) Count

func (*UserServiceHTTPClientImpl) Create

func (c *UserServiceHTTPClientImpl) Create(ctx context.Context, in *User, opts ...http.CallOption) (*UserId, error)

func (*UserServiceHTTPClientImpl) Delete

func (*UserServiceHTTPClientImpl) Find

func (*UserServiceHTTPClientImpl) FindById

func (c *UserServiceHTTPClientImpl) FindById(ctx context.Context, in *UserId, opts ...http.CallOption) (*User, error)

func (*UserServiceHTTPClientImpl) FindCars

func (*UserServiceHTTPClientImpl) FindDepts

func (*UserServiceHTTPClientImpl) RemoveCar

func (*UserServiceHTTPClientImpl) Update

func (c *UserServiceHTTPClientImpl) Update(ctx context.Context, in *User, opts ...http.CallOption) (*emptypb.Empty, error)

type UserServiceServer

type UserServiceServer interface {
	Create(context.Context, *User) (*UserId, error)
	Update(context.Context, *User) (*emptypb.Empty, error)
	Delete(context.Context, *UserId) (*emptypb.Empty, error)
	FindById(context.Context, *UserId) (*User, error)
	Find(context.Context, *UserPageQuery) (*UserWithCount, error)
	Count(context.Context, *User) (*CountNumber, error)
	AddCar(context.Context, *Car) (*CarId, error)
	AddCarById(context.Context, *UserIdAndCarId) (*emptypb.Empty, error)
	RemoveCar(context.Context, *UserRemoveCarReq) (*emptypb.Empty, error)
	FindCars(context.Context, *UserFindCarsReq) (*UserFindCarsRes, error)
	FindDepts(context.Context, *UserFindDeptsReq) (*UserFindDeptsRes, error)
	// contains filtered or unexported methods
}

UserServiceServer is the server API for UserService service. All implementations must embed UnimplementedUserServiceServer for forward compatibility

type UserWithCount

type UserWithCount struct {
	DataCount *wrapperspb.Int32Value `protobuf:"bytes,1,opt,name=data_count,proto3" json:"data_count,omitempty"`
	Users     []*User                `protobuf:"bytes,2,rep,name=Users,proto3" json:"Users,omitempty"`
	// contains filtered or unexported fields
}

func (*UserWithCount) Descriptor deprecated

func (*UserWithCount) Descriptor() ([]byte, []int)

Deprecated: Use UserWithCount.ProtoReflect.Descriptor instead.

func (*UserWithCount) GetDataCount

func (x *UserWithCount) GetDataCount() *wrapperspb.Int32Value

func (*UserWithCount) GetUsers

func (x *UserWithCount) GetUsers() []*User

func (*UserWithCount) ProtoMessage

func (*UserWithCount) ProtoMessage()

func (*UserWithCount) ProtoReflect

func (x *UserWithCount) ProtoReflect() protoreflect.Message

func (*UserWithCount) Reset

func (x *UserWithCount) Reset()

func (*UserWithCount) String

func (x *UserWithCount) String() string

type User_Race

type User_Race int32
const (
	User_RACE_UNSPECIFIED User_Race = 0
	User_YELLOW           User_Race = 1
	User_WHITE            User_Race = 2
	User_BLACK            User_Race = 3
)

func (User_Race) Descriptor

func (User_Race) Descriptor() protoreflect.EnumDescriptor

func (User_Race) Enum

func (x User_Race) Enum() *User_Race

func (User_Race) EnumDescriptor deprecated

func (User_Race) EnumDescriptor() ([]byte, []int)

Deprecated: Use User_Race.Descriptor instead.

func (User_Race) Number

func (x User_Race) Number() protoreflect.EnumNumber

func (User_Race) String

func (x User_Race) String() string

func (User_Race) Type

type Users

type Users struct {
	DataList []*User `protobuf:"bytes,1,rep,name=data_list,proto3" json:"data_list,omitempty"`
	// contains filtered or unexported fields
}

func (*Users) Descriptor deprecated

func (*Users) Descriptor() ([]byte, []int)

Deprecated: Use Users.ProtoReflect.Descriptor instead.

func (*Users) GetDataList

func (x *Users) GetDataList() []*User

func (*Users) ProtoMessage

func (*Users) ProtoMessage()

func (*Users) ProtoReflect

func (x *Users) ProtoReflect() protoreflect.Message

func (*Users) Reset

func (x *Users) Reset()

func (*Users) String

func (x *Users) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL