Class: KeycloakAdmin::RoleRepresentation

Inherits:
Representation show all
Defined in:
lib/keycloak-admin/representation/role_representation.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Methods inherited from Representation

#as_json, from_json, #to_json

Methods included from CamelJson

#camelize

Instance Attribute Details

#client_roleObject

Returns the value of attribute client_role.



4
5
6
# File 'lib/keycloak-admin/representation/role_representation.rb', line 4

def client_role
  @client_role
end

#compositeObject

Returns the value of attribute composite.



4
5
6
# File 'lib/keycloak-admin/representation/role_representation.rb', line 4

def composite
  @composite
end

#container_idObject

Returns the value of attribute container_id.



4
5
6
# File 'lib/keycloak-admin/representation/role_representation.rb', line 4

def container_id
  @container_id
end

#idObject

Returns the value of attribute id.



4
5
6
# File 'lib/keycloak-admin/representation/role_representation.rb', line 4

def id
  @id
end

#nameObject

Returns the value of attribute name.



4
5
6
# File 'lib/keycloak-admin/representation/role_representation.rb', line 4

def name
  @name
end

Class Method Details

.from_hash(hash) ⇒ Object



10
11
12
13
14
15
16
17
18
# File 'lib/keycloak-admin/representation/role_representation.rb', line 10

def self.from_hash(hash)
  role             = new
  role.id          = hash["id"]
  role.name        = hash["name"]
  role.composite   = hash["composite"]
  role.client_role = hash["clientRole"]
  role.container_id = hash["containerId"]
  role
end