ModulePermissions class

Annotation to declare module permissions

Example:

@ModulePermissions([
  ScopedPermission(Permission.dataRead),
  ScopedPermission(Permission.serviceCall, 'auth.*'),
])
class ProfileModule extends AppModule { }

Constructors

ModulePermissions(List<ScopedPermission> permissions)
const

Properties

hashCode int
The hash code for this object.
no setterinherited
permissions List<ScopedPermission>
List of permissions granted to this module
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

allows(Permission type, [String? resource]) bool
Check if this permission set allows a specific action
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited