rbac

package
v0.0.0-...-a14a4d2 Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Manager

type Manager struct {
	mock.Mock
}

Manager is an autogenerated mock type for the Manager type

func NewManager

func NewManager(t interface {
	mock.TestingT
	Cleanup(func())
}) *Manager

NewManager creates a new instance of Manager. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.

func (*Manager) CreatePermission

func (_m *Manager) CreatePermission(ctx context.Context, rp *model.RolePermission) (int64, error)

CreatePermission provides a mock function with given fields: ctx, rp

func (*Manager) CreateRbacPolicy

func (_m *Manager) CreateRbacPolicy(ctx context.Context, pp *model.PermissionPolicy) (int64, error)

CreateRbacPolicy provides a mock function with given fields: ctx, pp

func (*Manager) DeletePermission

func (_m *Manager) DeletePermission(ctx context.Context, id int64) error

DeletePermission provides a mock function with given fields: ctx, id

func (*Manager) DeletePermissionsByRole

func (_m *Manager) DeletePermissionsByRole(ctx context.Context, roleType string, roleID int64) error

DeletePermissionsByRole provides a mock function with given fields: ctx, roleType, roleID

func (*Manager) DeleteRbacPolicy

func (_m *Manager) DeleteRbacPolicy(ctx context.Context, id int64) error

DeleteRbacPolicy provides a mock function with given fields: ctx, id

func (*Manager) GetPermissionsByRole

func (_m *Manager) GetPermissionsByRole(ctx context.Context, roleType string, roleID int64) ([]*model.UniversalRolePermission, error)

GetPermissionsByRole provides a mock function with given fields: ctx, roleType, roleID

func (*Manager) ListPermissions

func (_m *Manager) ListPermissions(ctx context.Context, query *q.Query) ([]*model.RolePermission, error)

ListPermissions provides a mock function with given fields: ctx, query

func (*Manager) ListRbacPolicies

func (_m *Manager) ListRbacPolicies(ctx context.Context, query *q.Query) ([]*model.PermissionPolicy, error)

ListRbacPolicies provides a mock function with given fields: ctx, query

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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