Documentation ¶
Index ¶
- type CompositionWriter
- type GroupPermissionsProvider
- type GroupProvider
- func (_m *GroupProvider) Create(ctx context.Context, createdBy int64, name string, description *ntypes.String) (*model.GroupEntity, error)
- func (_m *GroupProvider) DeleteOneByID(_a0 context.Context, _a1 int64) (int64, error)
- func (_m *GroupProvider) Find(_a0 context.Context, _a1 *model.GroupFindExpr) ([]*model.GroupEntity, error)
- func (_m *GroupProvider) FindByUserID(_a0 context.Context, _a1 int64) ([]*model.GroupEntity, error)
- func (_m *GroupProvider) FindOneByID(_a0 context.Context, _a1 int64) (*model.GroupEntity, error)
- func (_m *GroupProvider) Insert(_a0 context.Context, _a1 *model.GroupEntity) (*model.GroupEntity, error)
- func (_m *GroupProvider) IsGranted(_a0 context.Context, _a1 int64, _a2 charon.Permission) (bool, error)
- func (_m *GroupProvider) SetPermissions(_a0 context.Context, _a1 int64, _a2 ...charon.Permission) (int64, int64, error)
- func (_m *GroupProvider) UpdateOneByID(_a0 context.Context, _a1 int64, _a2 *model.GroupPatch) (*model.GroupEntity, error)
- type PermissionProvider
- func (_m *PermissionProvider) Find(ctx context.Context, criteria *model.PermissionFindExpr) ([]*model.PermissionEntity, error)
- func (_m *PermissionProvider) FindByGroupID(ctx context.Context, groupID int64) ([]*model.PermissionEntity, error)
- func (_m *PermissionProvider) FindByUserID(ctx context.Context, userID int64) ([]*model.PermissionEntity, error)
- func (_m *PermissionProvider) FindOneByID(ctx context.Context, id int64) (*model.PermissionEntity, error)
- func (_m *PermissionProvider) Insert(ctx context.Context, entity *model.PermissionEntity) (*model.PermissionEntity, error)
- func (_m *PermissionProvider) InsertMissing(ctx context.Context, permissions charon.Permissions) (int64, error)
- func (_m *PermissionProvider) Register(ctx context.Context, permissions charon.Permissions) (int64, int64, int64, error)
- type PermissionRegistry
- type RefreshTokenProvider
- func (_m *RefreshTokenProvider) Create(_a0 context.Context, _a1 *model.RefreshTokenEntity) (*model.RefreshTokenEntity, error)
- func (_m *RefreshTokenProvider) Find(_a0 context.Context, _a1 *model.RefreshTokenFindExpr) ([]*model.RefreshTokenEntity, error)
- func (_m *RefreshTokenProvider) FindOneByToken(_a0 context.Context, _a1 string) (*model.RefreshTokenEntity, error)
- func (_m *RefreshTokenProvider) FindOneByTokenAndUserID(ctx context.Context, token string, userID int64) (*model.RefreshTokenEntity, error)
- func (_m *RefreshTokenProvider) UpdateOneByToken(_a0 context.Context, _a1 string, _a2 *model.RefreshTokenPatch) (*model.RefreshTokenEntity, error)
- type Rows
- type UserGroupsProvider
- func (_m *UserGroupsProvider) DeleteByUserID(ctx context.Context, id int64) (int64, error)
- func (_m *UserGroupsProvider) Exists(ctx context.Context, userID int64, groupID int64) (bool, error)
- func (_m *UserGroupsProvider) Find(ctx context.Context, expr *model.UserGroupsFindExpr) ([]*model.UserGroupsEntity, error)
- func (_m *UserGroupsProvider) Insert(ctx context.Context, ent *model.UserGroupsEntity) (*model.UserGroupsEntity, error)
- func (_m *UserGroupsProvider) Set(ctx context.Context, userID int64, groupIDs []int64) (int64, int64, error)
- type UserPermissionsProvider
- type UserProvider
- func (_m *UserProvider) ChangePassword(ctx context.Context, id int64, password string) error
- func (_m *UserProvider) Count(_a0 context.Context) (int64, error)
- func (_m *UserProvider) Create(_a0 context.Context, _a1 *model.UserEntity) (*model.UserEntity, error)
- func (_m *UserProvider) CreateSuperuser(ctx context.Context, username string, password []byte, FirstName string, ...) (*model.UserEntity, error)
- func (_m *UserProvider) DeleteOneByID(_a0 context.Context, _a1 int64) (int64, error)
- func (_m *UserProvider) Exists(_a0 context.Context, _a1 int64) (bool, error)
- func (_m *UserProvider) Find(_a0 context.Context, _a1 *model.UserFindExpr) ([]*model.UserEntity, error)
- func (_m *UserProvider) FindOneByID(_a0 context.Context, _a1 int64) (*model.UserEntity, error)
- func (_m *UserProvider) FindOneByUsername(_a0 context.Context, _a1 string) (*model.UserEntity, error)
- func (_m *UserProvider) Insert(_a0 context.Context, _a1 *model.UserEntity) (*model.UserEntity, error)
- func (_m *UserProvider) IsGranted(ctx context.Context, id int64, permission charon.Permission) (bool, error)
- func (_m *UserProvider) RegistrationConfirmation(ctx context.Context, id int64, confirmationToken string) (int64, error)
- func (_m *UserProvider) SetPermissions(ctx context.Context, id int64, permissions ...charon.Permission) (int64, int64, error)
- func (_m *UserProvider) UpdateLastLoginAt(ctx context.Context, id int64) (int64, error)
- func (_m *UserProvider) UpdateOneByID(_a0 context.Context, _a1 int64, _a2 *model.UserPatch) (*model.UserEntity, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CompositionWriter ¶
CompositionWriter is an autogenerated mock type for the CompositionWriter type
func (*CompositionWriter) WriteComposition ¶
func (_m *CompositionWriter) WriteComposition(_a0 string, _a1 *model.Composer, _a2 *model.CompositionOpts) error
WriteComposition provides a mock function with given fields: _a0, _a1, _a2
type GroupPermissionsProvider ¶
GroupPermissionsProvider is an autogenerated mock type for the GroupPermissionsProvider type
func (*GroupPermissionsProvider) Insert ¶
func (_m *GroupPermissionsProvider) Insert(_a0 context.Context, _a1 *model.GroupPermissionsEntity) (*model.GroupPermissionsEntity, error)
Insert provides a mock function with given fields: _a0, _a1
type GroupProvider ¶
GroupProvider is an autogenerated mock type for the GroupProvider type
func (*GroupProvider) Create ¶
func (_m *GroupProvider) Create(ctx context.Context, createdBy int64, name string, description *ntypes.String) (*model.GroupEntity, error)
Create provides a mock function with given fields: ctx, createdBy, name, description
func (*GroupProvider) DeleteOneByID ¶
DeleteOneByID provides a mock function with given fields: _a0, _a1
func (*GroupProvider) Find ¶
func (_m *GroupProvider) Find(_a0 context.Context, _a1 *model.GroupFindExpr) ([]*model.GroupEntity, error)
Find provides a mock function with given fields: _a0, _a1
func (*GroupProvider) FindByUserID ¶
func (_m *GroupProvider) FindByUserID(_a0 context.Context, _a1 int64) ([]*model.GroupEntity, error)
FindByUserID provides a mock function with given fields: _a0, _a1
func (*GroupProvider) FindOneByID ¶
func (_m *GroupProvider) FindOneByID(_a0 context.Context, _a1 int64) (*model.GroupEntity, error)
FindOneByID provides a mock function with given fields: _a0, _a1
func (*GroupProvider) Insert ¶
func (_m *GroupProvider) Insert(_a0 context.Context, _a1 *model.GroupEntity) (*model.GroupEntity, error)
Insert provides a mock function with given fields: _a0, _a1
func (*GroupProvider) IsGranted ¶
func (_m *GroupProvider) IsGranted(_a0 context.Context, _a1 int64, _a2 charon.Permission) (bool, error)
IsGranted provides a mock function with given fields: _a0, _a1, _a2
func (*GroupProvider) SetPermissions ¶
func (_m *GroupProvider) SetPermissions(_a0 context.Context, _a1 int64, _a2 ...charon.Permission) (int64, int64, error)
SetPermissions provides a mock function with given fields: _a0, _a1, _a2
func (*GroupProvider) UpdateOneByID ¶
func (_m *GroupProvider) UpdateOneByID(_a0 context.Context, _a1 int64, _a2 *model.GroupPatch) (*model.GroupEntity, error)
UpdateOneByID provides a mock function with given fields: _a0, _a1, _a2
type PermissionProvider ¶
PermissionProvider is an autogenerated mock type for the PermissionProvider type
func (*PermissionProvider) Find ¶
func (_m *PermissionProvider) Find(ctx context.Context, criteria *model.PermissionFindExpr) ([]*model.PermissionEntity, error)
Find provides a mock function with given fields: ctx, criteria
func (*PermissionProvider) FindByGroupID ¶
func (_m *PermissionProvider) FindByGroupID(ctx context.Context, groupID int64) ([]*model.PermissionEntity, error)
FindByGroupID provides a mock function with given fields: ctx, groupID
func (*PermissionProvider) FindByUserID ¶
func (_m *PermissionProvider) FindByUserID(ctx context.Context, userID int64) ([]*model.PermissionEntity, error)
FindByUserID provides a mock function with given fields: ctx, userID
func (*PermissionProvider) FindOneByID ¶
func (_m *PermissionProvider) FindOneByID(ctx context.Context, id int64) (*model.PermissionEntity, error)
FindOneByID provides a mock function with given fields: ctx, id
func (*PermissionProvider) Insert ¶
func (_m *PermissionProvider) Insert(ctx context.Context, entity *model.PermissionEntity) (*model.PermissionEntity, error)
Insert provides a mock function with given fields: ctx, entity
func (*PermissionProvider) InsertMissing ¶
func (_m *PermissionProvider) InsertMissing(ctx context.Context, permissions charon.Permissions) (int64, error)
InsertMissing provides a mock function with given fields: ctx, permissions
type PermissionRegistry ¶
PermissionRegistry is an autogenerated mock type for the PermissionRegistry type
func (*PermissionRegistry) Exists ¶
func (_m *PermissionRegistry) Exists(ctx context.Context, permission charon.Permission) bool
Exists provides a mock function with given fields: ctx, permission
type RefreshTokenProvider ¶
RefreshTokenProvider is an autogenerated mock type for the RefreshTokenProvider type
func (*RefreshTokenProvider) Create ¶
func (_m *RefreshTokenProvider) Create(_a0 context.Context, _a1 *model.RefreshTokenEntity) (*model.RefreshTokenEntity, error)
Create provides a mock function with given fields: _a0, _a1
func (*RefreshTokenProvider) Find ¶
func (_m *RefreshTokenProvider) Find(_a0 context.Context, _a1 *model.RefreshTokenFindExpr) ([]*model.RefreshTokenEntity, error)
Find provides a mock function with given fields: _a0, _a1
func (*RefreshTokenProvider) FindOneByToken ¶
func (_m *RefreshTokenProvider) FindOneByToken(_a0 context.Context, _a1 string) (*model.RefreshTokenEntity, error)
FindOneByToken provides a mock function with given fields: _a0, _a1
func (*RefreshTokenProvider) FindOneByTokenAndUserID ¶
func (_m *RefreshTokenProvider) FindOneByTokenAndUserID(ctx context.Context, token string, userID int64) (*model.RefreshTokenEntity, error)
FindOneByTokenAndUserID provides a mock function with given fields: ctx, token, userID
func (*RefreshTokenProvider) UpdateOneByToken ¶
func (_m *RefreshTokenProvider) UpdateOneByToken(_a0 context.Context, _a1 string, _a2 *model.RefreshTokenPatch) (*model.RefreshTokenEntity, error)
UpdateOneByToken provides a mock function with given fields: _a0, _a1, _a2
type Rows ¶
Rows is an autogenerated mock type for the Rows type
func (*Rows) ColumnTypes ¶
func (_m *Rows) ColumnTypes() ([]*sql.ColumnType, error)
ColumnTypes provides a mock function with given fields:
func (*Rows) NextResultSet ¶
NextResultSet provides a mock function with given fields:
type UserGroupsProvider ¶
UserGroupsProvider is an autogenerated mock type for the UserGroupsProvider type
func (*UserGroupsProvider) DeleteByUserID ¶
DeleteByUserID provides a mock function with given fields: ctx, id
func (*UserGroupsProvider) Exists ¶
func (_m *UserGroupsProvider) Exists(ctx context.Context, userID int64, groupID int64) (bool, error)
Exists provides a mock function with given fields: ctx, userID, groupID
func (*UserGroupsProvider) Find ¶
func (_m *UserGroupsProvider) Find(ctx context.Context, expr *model.UserGroupsFindExpr) ([]*model.UserGroupsEntity, error)
Find provides a mock function with given fields: ctx, expr
func (*UserGroupsProvider) Insert ¶
func (_m *UserGroupsProvider) Insert(ctx context.Context, ent *model.UserGroupsEntity) (*model.UserGroupsEntity, error)
Insert provides a mock function with given fields: ctx, ent
type UserPermissionsProvider ¶
UserPermissionsProvider is an autogenerated mock type for the UserPermissionsProvider type
func (*UserPermissionsProvider) DeleteByUserID ¶
DeleteByUserID provides a mock function with given fields: _a0, _a1
func (*UserPermissionsProvider) Insert ¶
func (_m *UserPermissionsProvider) Insert(_a0 context.Context, _a1 *model.UserPermissionsEntity) (*model.UserPermissionsEntity, error)
Insert provides a mock function with given fields: _a0, _a1
type UserProvider ¶
UserProvider is an autogenerated mock type for the UserProvider type
func (*UserProvider) ChangePassword ¶
ChangePassword provides a mock function with given fields: ctx, id, password
func (*UserProvider) Count ¶
func (_m *UserProvider) Count(_a0 context.Context) (int64, error)
Count provides a mock function with given fields: _a0
func (*UserProvider) Create ¶
func (_m *UserProvider) Create(_a0 context.Context, _a1 *model.UserEntity) (*model.UserEntity, error)
Create provides a mock function with given fields: _a0, _a1
func (*UserProvider) CreateSuperuser ¶
func (_m *UserProvider) CreateSuperuser(ctx context.Context, username string, password []byte, FirstName string, LastName string) (*model.UserEntity, error)
CreateSuperuser provides a mock function with given fields: ctx, username, password, FirstName, LastName
func (*UserProvider) DeleteOneByID ¶
DeleteOneByID provides a mock function with given fields: _a0, _a1
func (*UserProvider) Find ¶
func (_m *UserProvider) Find(_a0 context.Context, _a1 *model.UserFindExpr) ([]*model.UserEntity, error)
Find provides a mock function with given fields: _a0, _a1
func (*UserProvider) FindOneByID ¶
func (_m *UserProvider) FindOneByID(_a0 context.Context, _a1 int64) (*model.UserEntity, error)
FindOneByID provides a mock function with given fields: _a0, _a1
func (*UserProvider) FindOneByUsername ¶
func (_m *UserProvider) FindOneByUsername(_a0 context.Context, _a1 string) (*model.UserEntity, error)
FindOneByUsername provides a mock function with given fields: _a0, _a1
func (*UserProvider) Insert ¶
func (_m *UserProvider) Insert(_a0 context.Context, _a1 *model.UserEntity) (*model.UserEntity, error)
Insert provides a mock function with given fields: _a0, _a1
func (*UserProvider) IsGranted ¶
func (_m *UserProvider) IsGranted(ctx context.Context, id int64, permission charon.Permission) (bool, error)
IsGranted provides a mock function with given fields: ctx, id, permission
func (*UserProvider) RegistrationConfirmation ¶
func (_m *UserProvider) RegistrationConfirmation(ctx context.Context, id int64, confirmationToken string) (int64, error)
RegistrationConfirmation provides a mock function with given fields: ctx, id, confirmationToken
func (*UserProvider) SetPermissions ¶
func (_m *UserProvider) SetPermissions(ctx context.Context, id int64, permissions ...charon.Permission) (int64, int64, error)
SetPermissions provides a mock function with given fields: ctx, id, permissions
func (*UserProvider) UpdateLastLoginAt ¶
UpdateLastLoginAt provides a mock function with given fields: ctx, id
func (*UserProvider) UpdateOneByID ¶
func (_m *UserProvider) UpdateOneByID(_a0 context.Context, _a1 int64, _a2 *model.UserPatch) (*model.UserEntity, error)
UpdateOneByID provides a mock function with given fields: _a0, _a1, _a2