Class: Ddr::Auth::Roles::RoleType

Inherits:
Object
  • Object
show all
Defined in:
lib/ddr/auth/roles/role_type.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(title, description, permissions) ⇒ RoleType

Returns a new instance of RoleType.



9
10
11
12
13
14
# File 'lib/ddr/auth/roles/role_type.rb', line 9

def initialize(title, description, permissions)
  @title = title.freeze
  @description = description.freeze
  @permissions = permissions.freeze
  freeze
end

Instance Attribute Details

#descriptionObject (readonly)

Returns the value of attribute description.



6
7
8
# File 'lib/ddr/auth/roles/role_type.rb', line 6

def description
  @description
end

#permissionsObject (readonly)

Returns the value of attribute permissions.



6
7
8
# File 'lib/ddr/auth/roles/role_type.rb', line 6

def permissions
  @permissions
end

#titleObject (readonly) Also known as: label

Returns the value of attribute title.



6
7
8
# File 'lib/ddr/auth/roles/role_type.rb', line 6

def title
  @title
end

Instance Method Details

#to_sObject



16
17
18
# File 'lib/ddr/auth/roles/role_type.rb', line 16

def to_s
  title
end