Documentation ¶
Index ¶
- Variables
- func RegisterRightsServer(s grpc.ServiceRegistrar, srv RightsServer)
- type AccessRights
- func (AccessRights) Descriptor() protoreflect.EnumDescriptor
- func (x AccessRights) Enum() *AccessRights
- func (AccessRights) EnumDescriptor() ([]byte, []int)deprecated
- func (x AccessRights) Number() protoreflect.EnumNumber
- func (x AccessRights) String() string
- func (AccessRights) Type() protoreflect.EnumType
- type AccessRuleId
- type AccessRuleIdAndRight
- func (*AccessRuleIdAndRight) Descriptor() ([]byte, []int)deprecated
- func (x *AccessRuleIdAndRight) GetAccessRight() AccessRights
- func (x *AccessRuleIdAndRight) GetId() string
- func (*AccessRuleIdAndRight) ProtoMessage()
- func (x *AccessRuleIdAndRight) ProtoReflect() protoreflect.Message
- func (x *AccessRuleIdAndRight) Reset()
- func (x *AccessRuleIdAndRight) String() string
- type AccessRuleInfo
- func (*AccessRuleInfo) Descriptor() ([]byte, []int)deprecated
- func (x *AccessRuleInfo) GetAccessRight() AccessRights
- func (x *AccessRuleInfo) GetApplicationId() string
- func (x *AccessRuleInfo) GetId() string
- func (x *AccessRuleInfo) GetUserId() string
- func (*AccessRuleInfo) ProtoMessage()
- func (x *AccessRuleInfo) ProtoReflect() protoreflect.Message
- func (x *AccessRuleInfo) Reset()
- func (x *AccessRuleInfo) String() string
- type AccessRuleWithoutId
- func (*AccessRuleWithoutId) Descriptor() ([]byte, []int)deprecated
- func (x *AccessRuleWithoutId) GetAccessRight() AccessRights
- func (x *AccessRuleWithoutId) GetApplicationId() string
- func (x *AccessRuleWithoutId) GetUserId() string
- func (*AccessRuleWithoutId) ProtoMessage()
- func (x *AccessRuleWithoutId) ProtoReflect() protoreflect.Message
- func (x *AccessRuleWithoutId) Reset()
- func (x *AccessRuleWithoutId) String() string
- type ListOptions
- type RightsClient
- type RightsServer
- type Rights_ListClient
- type Rights_ListServer
- type UnimplementedRightsServer
- func (UnimplementedRightsServer) Create(context.Context, *AccessRuleWithoutId) (*AccessRuleInfo, error)
- func (UnimplementedRightsServer) Delete(context.Context, *AccessRuleId) (*common.EmptyMessage, error)
- func (UnimplementedRightsServer) Get(context.Context, *AccessRuleId) (*AccessRuleInfo, error)
- func (UnimplementedRightsServer) List(*ListOptions, Rights_ListServer) error
- func (UnimplementedRightsServer) Update(context.Context, *AccessRuleIdAndRight) (*AccessRuleIdAndRight, error)
- type UnsafeRightsServer
Constants ¶
This section is empty.
Variables ¶
var ( AccessRights_name = map[int32]string{ 0: "ACCESS_RIGHTS_READ_UNSPECIFIED", 1: "ACCESS_RIGHTS_WRITE", 2: "ACCESS_RIGHTS_DELETE", } AccessRights_value = map[string]int32{ "ACCESS_RIGHTS_READ_UNSPECIFIED": 0, "ACCESS_RIGHTS_WRITE": 1, "ACCESS_RIGHTS_DELETE": 2, } )
Enum value maps for AccessRights.
var File_users_rights_rights_v1_proto protoreflect.FileDescriptor
var Rights_ServiceDesc = grpc.ServiceDesc{ ServiceName: "users.Rights", HandlerType: (*RightsServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Create", Handler: _Rights_Create_Handler, }, { MethodName: "Update", Handler: _Rights_Update_Handler, }, { MethodName: "Delete", Handler: _Rights_Delete_Handler, }, { MethodName: "Get", Handler: _Rights_Get_Handler, }, }, Streams: []grpc.StreamDesc{ { StreamName: "List", Handler: _Rights_List_Handler, ServerStreams: true, }, }, Metadata: "users/rights/rights_v1.proto", }
Rights_ServiceDesc is the grpc.ServiceDesc for Rights service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterRightsServer ¶
func RegisterRightsServer(s grpc.ServiceRegistrar, srv RightsServer)
Types ¶
type AccessRights ¶
type AccessRights int32
const ( AccessRights_ACCESS_RIGHTS_READ_UNSPECIFIED AccessRights = 0 AccessRights_ACCESS_RIGHTS_WRITE AccessRights = 1 AccessRights_ACCESS_RIGHTS_DELETE AccessRights = 2 )
func (AccessRights) Descriptor ¶
func (AccessRights) Descriptor() protoreflect.EnumDescriptor
func (AccessRights) Enum ¶
func (x AccessRights) Enum() *AccessRights
func (AccessRights) EnumDescriptor
deprecated
func (AccessRights) EnumDescriptor() ([]byte, []int)
Deprecated: Use AccessRights.Descriptor instead.
func (AccessRights) Number ¶
func (x AccessRights) Number() protoreflect.EnumNumber
func (AccessRights) String ¶
func (x AccessRights) String() string
func (AccessRights) Type ¶
func (AccessRights) Type() protoreflect.EnumType
type AccessRuleId ¶
type AccessRuleId struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*AccessRuleId) Descriptor
deprecated
func (*AccessRuleId) Descriptor() ([]byte, []int)
Deprecated: Use AccessRuleId.ProtoReflect.Descriptor instead.
func (*AccessRuleId) GetId ¶
func (x *AccessRuleId) GetId() string
func (*AccessRuleId) ProtoMessage ¶
func (*AccessRuleId) ProtoMessage()
func (*AccessRuleId) ProtoReflect ¶
func (x *AccessRuleId) ProtoReflect() protoreflect.Message
func (*AccessRuleId) Reset ¶
func (x *AccessRuleId) Reset()
func (*AccessRuleId) String ¶
func (x *AccessRuleId) String() string
type AccessRuleIdAndRight ¶
type AccessRuleIdAndRight struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` AccessRight AccessRights `protobuf:"varint,3,opt,name=access_right,json=accessRight,proto3,enum=users.AccessRights" json:"access_right,omitempty"` // contains filtered or unexported fields }
func (*AccessRuleIdAndRight) Descriptor
deprecated
func (*AccessRuleIdAndRight) Descriptor() ([]byte, []int)
Deprecated: Use AccessRuleIdAndRight.ProtoReflect.Descriptor instead.
func (*AccessRuleIdAndRight) GetAccessRight ¶
func (x *AccessRuleIdAndRight) GetAccessRight() AccessRights
func (*AccessRuleIdAndRight) GetId ¶
func (x *AccessRuleIdAndRight) GetId() string
func (*AccessRuleIdAndRight) ProtoMessage ¶
func (*AccessRuleIdAndRight) ProtoMessage()
func (*AccessRuleIdAndRight) ProtoReflect ¶
func (x *AccessRuleIdAndRight) ProtoReflect() protoreflect.Message
func (*AccessRuleIdAndRight) Reset ¶
func (x *AccessRuleIdAndRight) Reset()
func (*AccessRuleIdAndRight) String ¶
func (x *AccessRuleIdAndRight) String() string
type AccessRuleInfo ¶
type AccessRuleInfo struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` UserId string `protobuf:"bytes,2,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` ApplicationId string `protobuf:"bytes,3,opt,name=application_id,json=applicationId,proto3" json:"application_id,omitempty"` AccessRight AccessRights `protobuf:"varint,4,opt,name=access_right,json=accessRight,proto3,enum=users.AccessRights" json:"access_right,omitempty"` // contains filtered or unexported fields }
func (*AccessRuleInfo) Descriptor
deprecated
func (*AccessRuleInfo) Descriptor() ([]byte, []int)
Deprecated: Use AccessRuleInfo.ProtoReflect.Descriptor instead.
func (*AccessRuleInfo) GetAccessRight ¶
func (x *AccessRuleInfo) GetAccessRight() AccessRights
func (*AccessRuleInfo) GetApplicationId ¶
func (x *AccessRuleInfo) GetApplicationId() string
func (*AccessRuleInfo) GetId ¶
func (x *AccessRuleInfo) GetId() string
func (*AccessRuleInfo) GetUserId ¶ added in v0.0.4
func (x *AccessRuleInfo) GetUserId() string
func (*AccessRuleInfo) ProtoMessage ¶
func (*AccessRuleInfo) ProtoMessage()
func (*AccessRuleInfo) ProtoReflect ¶
func (x *AccessRuleInfo) ProtoReflect() protoreflect.Message
func (*AccessRuleInfo) Reset ¶
func (x *AccessRuleInfo) Reset()
func (*AccessRuleInfo) String ¶
func (x *AccessRuleInfo) String() string
type AccessRuleWithoutId ¶
type AccessRuleWithoutId struct { UserId string `protobuf:"bytes,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` ApplicationId string `protobuf:"bytes,2,opt,name=application_id,json=applicationId,proto3" json:"application_id,omitempty"` AccessRight AccessRights `protobuf:"varint,3,opt,name=access_right,json=accessRight,proto3,enum=users.AccessRights" json:"access_right,omitempty"` // contains filtered or unexported fields }
func (*AccessRuleWithoutId) Descriptor
deprecated
func (*AccessRuleWithoutId) Descriptor() ([]byte, []int)
Deprecated: Use AccessRuleWithoutId.ProtoReflect.Descriptor instead.
func (*AccessRuleWithoutId) GetAccessRight ¶
func (x *AccessRuleWithoutId) GetAccessRight() AccessRights
func (*AccessRuleWithoutId) GetApplicationId ¶
func (x *AccessRuleWithoutId) GetApplicationId() string
func (*AccessRuleWithoutId) GetUserId ¶
func (x *AccessRuleWithoutId) GetUserId() string
func (*AccessRuleWithoutId) ProtoMessage ¶
func (*AccessRuleWithoutId) ProtoMessage()
func (*AccessRuleWithoutId) ProtoReflect ¶
func (x *AccessRuleWithoutId) ProtoReflect() protoreflect.Message
func (*AccessRuleWithoutId) Reset ¶
func (x *AccessRuleWithoutId) Reset()
func (*AccessRuleWithoutId) String ¶
func (x *AccessRuleWithoutId) String() string
type ListOptions ¶
type ListOptions struct { AppId *applications.AppId `protobuf:"bytes,1,opt,name=app_id,json=appId,proto3" json:"app_id,omitempty"` // contains filtered or unexported fields }
func (*ListOptions) Descriptor
deprecated
func (*ListOptions) Descriptor() ([]byte, []int)
Deprecated: Use ListOptions.ProtoReflect.Descriptor instead.
func (*ListOptions) GetAppId ¶
func (x *ListOptions) GetAppId() *applications.AppId
func (*ListOptions) ProtoMessage ¶
func (*ListOptions) ProtoMessage()
func (*ListOptions) ProtoReflect ¶
func (x *ListOptions) ProtoReflect() protoreflect.Message
func (*ListOptions) Reset ¶
func (x *ListOptions) Reset()
func (*ListOptions) String ¶
func (x *ListOptions) String() string
type RightsClient ¶
type RightsClient interface { Create(ctx context.Context, in *AccessRuleWithoutId, opts ...grpc.CallOption) (*AccessRuleInfo, error) Update(ctx context.Context, in *AccessRuleIdAndRight, opts ...grpc.CallOption) (*AccessRuleIdAndRight, error) Delete(ctx context.Context, in *AccessRuleId, opts ...grpc.CallOption) (*common.EmptyMessage, error) Get(ctx context.Context, in *AccessRuleId, opts ...grpc.CallOption) (*AccessRuleInfo, error) List(ctx context.Context, in *ListOptions, opts ...grpc.CallOption) (Rights_ListClient, error) }
RightsClient is the client API for Rights 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 NewRightsClient ¶
func NewRightsClient(cc grpc.ClientConnInterface) RightsClient
type RightsServer ¶
type RightsServer interface { Create(context.Context, *AccessRuleWithoutId) (*AccessRuleInfo, error) Update(context.Context, *AccessRuleIdAndRight) (*AccessRuleIdAndRight, error) Delete(context.Context, *AccessRuleId) (*common.EmptyMessage, error) Get(context.Context, *AccessRuleId) (*AccessRuleInfo, error) List(*ListOptions, Rights_ListServer) error // contains filtered or unexported methods }
RightsServer is the server API for Rights service. All implementations must embed UnimplementedRightsServer for forward compatibility
type Rights_ListClient ¶
type Rights_ListClient interface { Recv() (*AccessRuleInfo, error) grpc.ClientStream }
type Rights_ListServer ¶
type Rights_ListServer interface { Send(*AccessRuleInfo) error grpc.ServerStream }
type UnimplementedRightsServer ¶
type UnimplementedRightsServer struct { }
UnimplementedRightsServer must be embedded to have forward compatible implementations.
func (UnimplementedRightsServer) Create ¶
func (UnimplementedRightsServer) Create(context.Context, *AccessRuleWithoutId) (*AccessRuleInfo, error)
func (UnimplementedRightsServer) Delete ¶
func (UnimplementedRightsServer) Delete(context.Context, *AccessRuleId) (*common.EmptyMessage, error)
func (UnimplementedRightsServer) Get ¶
func (UnimplementedRightsServer) Get(context.Context, *AccessRuleId) (*AccessRuleInfo, error)
func (UnimplementedRightsServer) List ¶
func (UnimplementedRightsServer) List(*ListOptions, Rights_ListServer) error
func (UnimplementedRightsServer) Update ¶
func (UnimplementedRightsServer) Update(context.Context, *AccessRuleIdAndRight) (*AccessRuleIdAndRight, error)
type UnsafeRightsServer ¶
type UnsafeRightsServer interface {
// contains filtered or unexported methods
}
UnsafeRightsServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to RightsServer will result in compilation errors.