user

package
v0.0.0-...-b044b52 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	UserService_CreateUser_FullMethodName = "/user.UserService/CreateUser"
	UserService_GetUser_FullMethodName    = "/user.UserService/GetUser"
	UserService_UpdateUser_FullMethodName = "/user.UserService/UpdateUser"
	UserService_DeleteUser_FullMethodName = "/user.UserService/DeleteUser"
	UserService_ListUser_FullMethodName   = "/user.UserService/ListUser"
)

Variables

View Source
var File_gateway_api_user_user_proto protoreflect.FileDescriptor
View Source
var UserService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "user.UserService",
	HandlerType: (*UserServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CreateUser",
			Handler:    _UserService_CreateUser_Handler,
		},
		{
			MethodName: "GetUser",
			Handler:    _UserService_GetUser_Handler,
		},
		{
			MethodName: "UpdateUser",
			Handler:    _UserService_UpdateUser_Handler,
		},
		{
			MethodName: "DeleteUser",
			Handler:    _UserService_DeleteUser_Handler,
		},
		{
			MethodName: "ListUser",
			Handler:    _UserService_ListUser_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "gateway/api/user/user.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 RegisterUserServiceServer

func RegisterUserServiceServer(s grpc.ServiceRegistrar, srv UserServiceServer)

Types

type UnimplementedUserServiceServer

type UnimplementedUserServiceServer struct {
}

UnimplementedUserServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedUserServiceServer) CreateUser

func (UnimplementedUserServiceServer) DeleteUser

func (UnimplementedUserServiceServer) GetUser

func (UnimplementedUserServiceServer) ListUser

func (UnimplementedUserServiceServer) UpdateUser

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 {
	Name     string   `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Password []byte   `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"`
	Roles    []string `protobuf:"bytes,3,rep,name=roles,proto3" json:"roles,omitempty"`
	// contains filtered or unexported fields
}

func (*User) Descriptor deprecated

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

Deprecated: Use User.ProtoReflect.Descriptor instead.

func (*User) GetName

func (x *User) GetName() string

func (*User) GetPassword

func (x *User) GetPassword() []byte

func (*User) GetRoles

func (x *User) GetRoles() []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 UserCreateRequest

type UserCreateRequest struct {
	User *User `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"`
	// contains filtered or unexported fields
}

func (*UserCreateRequest) Descriptor deprecated

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

Deprecated: Use UserCreateRequest.ProtoReflect.Descriptor instead.

func (*UserCreateRequest) GetUser

func (x *UserCreateRequest) GetUser() *User

func (*UserCreateRequest) ProtoMessage

func (*UserCreateRequest) ProtoMessage()

func (*UserCreateRequest) ProtoReflect

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

func (*UserCreateRequest) Reset

func (x *UserCreateRequest) Reset()

func (*UserCreateRequest) String

func (x *UserCreateRequest) String() string

type UserDeleteRequest

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

func (*UserDeleteRequest) Descriptor deprecated

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

Deprecated: Use UserDeleteRequest.ProtoReflect.Descriptor instead.

func (*UserDeleteRequest) GetName

func (x *UserDeleteRequest) GetName() string

func (*UserDeleteRequest) ProtoMessage

func (*UserDeleteRequest) ProtoMessage()

func (*UserDeleteRequest) ProtoReflect

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

func (*UserDeleteRequest) Reset

func (x *UserDeleteRequest) Reset()

func (*UserDeleteRequest) String

func (x *UserDeleteRequest) String() string

type UserGetRequest

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

func (*UserGetRequest) Descriptor deprecated

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

Deprecated: Use UserGetRequest.ProtoReflect.Descriptor instead.

func (*UserGetRequest) GetName

func (x *UserGetRequest) GetName() string

func (*UserGetRequest) ProtoMessage

func (*UserGetRequest) ProtoMessage()

func (*UserGetRequest) ProtoReflect

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

func (*UserGetRequest) Reset

func (x *UserGetRequest) Reset()

func (*UserGetRequest) String

func (x *UserGetRequest) String() string

type UserListRequest

type UserListRequest struct {
	Query *UserQuery `protobuf:"bytes,1,opt,name=query,proto3" json:"query,omitempty"`
	// contains filtered or unexported fields
}

func (*UserListRequest) Descriptor deprecated

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

Deprecated: Use UserListRequest.ProtoReflect.Descriptor instead.

func (*UserListRequest) GetQuery

func (x *UserListRequest) GetQuery() *UserQuery

func (*UserListRequest) ProtoMessage

func (*UserListRequest) ProtoMessage()

func (*UserListRequest) ProtoReflect

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

func (*UserListRequest) Reset

func (x *UserListRequest) Reset()

func (*UserListRequest) String

func (x *UserListRequest) String() string

type UserListResponse

type UserListResponse struct {

	// users is the list of users with the passwords set to the empty strings
	Users []*User `protobuf:"bytes,2,rep,name=users,proto3" json:"users,omitempty"`
	// contains filtered or unexported fields
}

func (*UserListResponse) Descriptor deprecated

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

Deprecated: Use UserListResponse.ProtoReflect.Descriptor instead.

func (*UserListResponse) GetUsers

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

func (*UserListResponse) ProtoMessage

func (*UserListResponse) ProtoMessage()

func (*UserListResponse) ProtoReflect

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

func (*UserListResponse) Reset

func (x *UserListResponse) Reset()

func (*UserListResponse) String

func (x *UserListResponse) String() string

type UserQuery

type UserQuery struct {
	Name  *core.StringQuery     `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Roles *core.CollectionQuery `protobuf:"bytes,2,opt,name=roles,proto3" json:"roles,omitempty"`
	// contains filtered or unexported fields
}

func (*UserQuery) Descriptor deprecated

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

Deprecated: Use UserQuery.ProtoReflect.Descriptor instead.

func (*UserQuery) GetName

func (x *UserQuery) GetName() *core.StringQuery

func (*UserQuery) GetRoles

func (x *UserQuery) GetRoles() *core.CollectionQuery

func (*UserQuery) Matches

func (q *UserQuery) Matches(user *marinav1.User) (bool, error)

func (*UserQuery) ProtoMessage

func (*UserQuery) ProtoMessage()

func (*UserQuery) ProtoReflect

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

func (*UserQuery) Reset

func (x *UserQuery) Reset()

func (*UserQuery) String

func (x *UserQuery) String() string

type UserServiceClient

type UserServiceClient interface {
	CreateUser(ctx context.Context, in *UserCreateRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	GetUser(ctx context.Context, in *UserGetRequest, opts ...grpc.CallOption) (*User, error)
	UpdateUser(ctx context.Context, in *UserUpdateRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	DeleteUser(ctx context.Context, in *UserDeleteRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	ListUser(ctx context.Context, in *UserListRequest, opts ...grpc.CallOption) (*UserListResponse, 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 UserServiceServer

type UserServiceServer interface {
	CreateUser(context.Context, *UserCreateRequest) (*emptypb.Empty, error)
	GetUser(context.Context, *UserGetRequest) (*User, error)
	UpdateUser(context.Context, *UserUpdateRequest) (*emptypb.Empty, error)
	DeleteUser(context.Context, *UserDeleteRequest) (*emptypb.Empty, error)
	ListUser(context.Context, *UserListRequest) (*UserListResponse, error)
	// contains filtered or unexported methods
}

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

type UserUpdateRequest

type UserUpdateRequest struct {
	User *User `protobuf:"bytes,2,opt,name=user,proto3" json:"user,omitempty"`
	// contains filtered or unexported fields
}

func (*UserUpdateRequest) Descriptor deprecated

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

Deprecated: Use UserUpdateRequest.ProtoReflect.Descriptor instead.

func (*UserUpdateRequest) GetUser

func (x *UserUpdateRequest) GetUser() *User

func (*UserUpdateRequest) ProtoMessage

func (*UserUpdateRequest) ProtoMessage()

func (*UserUpdateRequest) ProtoReflect

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

func (*UserUpdateRequest) Reset

func (x *UserUpdateRequest) Reset()

func (*UserUpdateRequest) String

func (x *UserUpdateRequest) String() string

Jump to

Keyboard shortcuts

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