Module: Troles::Common::Api::Core
- Defined in:
- lib/troles/common/api/core.rb
Defined Under Namespace
Modules: ClassMethods
Instance Method Summary collapse
-
#roles ⇒ Troles::Operations
Access to the Troles operations API.
-
#roles=(*new_roles) ⇒ Object
Sets the roles of the subject (see #set_roles).
-
#static_roles? ⇒ true, false
If this role subject instance should have static (immutable) roles.
- #troles_config ⇒ Object
Instance Method Details
#roles ⇒ Troles::Operations
Access to the Troles operations API
11 12 13 |
# File 'lib/troles/common/api/core.rb', line 11 def roles @roles ||= Troles::Operations.new(self) end |
#roles=(*new_roles) ⇒ Object
Sets the roles of the subject (see #set_roles)
17 18 19 |
# File 'lib/troles/common/api/core.rb', line 17 def roles= *new_roles roles.set_roles new_roles end |
#static_roles? ⇒ true, false
If this role subject instance should have static (immutable) roles
23 24 25 |
# File 'lib/troles/common/api/core.rb', line 23 def static_roles? false end |
#troles_config ⇒ Object
27 28 29 |
# File 'lib/troles/common/api/core.rb', line 27 def troles_config self.class.troles_config end |