Documentation ¶
Index ¶
- type Permission
- func (p *Permission) AddPolicies(rules [][]string) (bool, error)
- func (p *Permission) AddPolicyForRoleInDomain(domain, role, object, action string) (bool, error)
- func (p *Permission) FilterDataArray(data []any, actions []string, domain string, roles []string, fieldName string) ([]any, error)
- func (p *Permission) GetPolicyForObjectInDomain(domain, object string) [][]string
- func (p *Permission) GetPolicyForRoleInDomain(domain, role string) ([][]string, error)
- func (p *Permission) HasPermissionForRoleInDomain(domain, role, object, action string) (bool, error)
- func (p *Permission) RemovePolicies(rules [][]string) (bool, error)
- func (p *Permission) RemovePoliciesForObjectInDomain(domain, object string) (bool, error)
- func (p *Permission) RemovePolicyForRoleInDomain(domain, role, object, action string) (bool, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Permission ¶
type Permission struct {
// contains filtered or unexported fields
}
func GetPermission ¶
func GetPermission() *Permission
func (*Permission) AddPolicies ¶
func (p *Permission) AddPolicies(rules [][]string) (bool, error)
func (*Permission) AddPolicyForRoleInDomain ¶
func (p *Permission) AddPolicyForRoleInDomain(domain, role, object, action string) (bool, error)
func (*Permission) FilterDataArray ¶
func (*Permission) GetPolicyForObjectInDomain ¶
func (p *Permission) GetPolicyForObjectInDomain(domain, object string) [][]string
func (*Permission) GetPolicyForRoleInDomain ¶
func (p *Permission) GetPolicyForRoleInDomain(domain, role string) ([][]string, error)
func (*Permission) HasPermissionForRoleInDomain ¶
func (p *Permission) HasPermissionForRoleInDomain(domain, role, object, action string) (bool, error)
func (*Permission) RemovePolicies ¶
func (p *Permission) RemovePolicies(rules [][]string) (bool, error)
func (*Permission) RemovePoliciesForObjectInDomain ¶
func (p *Permission) RemovePoliciesForObjectInDomain(domain, object string) (bool, error)
func (*Permission) RemovePolicyForRoleInDomain ¶
func (p *Permission) RemovePolicyForRoleInDomain(domain, role, object, action string) (bool, error)
Click to show internal directories.
Click to hide internal directories.