Documentation ¶
Index ¶
- Variables
- type Filter
- type PermissionService
- type RelationService
- type Repository
- type Role
- type Service
- func (s Service) Delete(ctx context.Context, id string) error
- func (s Service) Get(ctx context.Context, id string) (Role, error)
- func (s Service) List(ctx context.Context, f Filter) ([]Role, error)
- func (s Service) Update(ctx context.Context, toUpdate Role) (Role, error)
- func (s Service) Upsert(ctx context.Context, toCreate Role) (Role, error)
- type State
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type PermissionService ¶
type PermissionService interface {
Get(ctx context.Context, id string) (permission.Permission, error)
}
type RelationService ¶
type Repository ¶
type Repository interface { Get(ctx context.Context, id string) (Role, error) GetByName(ctx context.Context, orgID, name string) (Role, error) List(ctx context.Context, f Filter) ([]Role, error) Upsert(ctx context.Context, role Role) (Role, error) Update(ctx context.Context, toUpdate Role) (Role, error) Delete(ctx context.Context, roleID string) error }
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func NewService ¶
func NewService(repository Repository, relationService RelationService, permissionService PermissionService) *Service
Click to show internal directories.
Click to hide internal directories.