Class: SDM::GrantedRoleEntitlement
- Inherits:
-
Object
- Object
- SDM::GrantedRoleEntitlement
- Defined in:
- lib/models/porcelain.rb
Overview
GrantedRoleEntitlement represents an individual resource entitlement granted through a Role.
Instance Attribute Summary collapse
-
#group_id ⇒ Object
The unique identifier of the group associated with this entitlement, if any.
-
#last_accessed ⇒ Object
The most recent time at which any account in the organization accessed this resource.
-
#mapped_identities ⇒ Object
The mapped identity privileges for this entitlement, such as Kubernetes group memberships.
-
#resource_id ⇒ Object
The unique identifier of the Resource to which the role grants access.
Instance Method Summary collapse
-
#initialize(group_id: nil, last_accessed: nil, mapped_identities: nil, resource_id: nil) ⇒ GrantedRoleEntitlement
constructor
A new instance of GrantedRoleEntitlement.
- #to_json(options = {}) ⇒ Object
Constructor Details
#initialize(group_id: nil, last_accessed: nil, mapped_identities: nil, resource_id: nil) ⇒ GrantedRoleEntitlement
Returns a new instance of GrantedRoleEntitlement.
8128 8129 8130 8131 8132 8133 8134 8135 8136 8137 8138 |
# File 'lib/models/porcelain.rb', line 8128 def initialize( group_id: nil, last_accessed: nil, mapped_identities: nil, resource_id: nil ) @group_id = group_id == nil ? "" : group_id @last_accessed = last_accessed == nil ? nil : last_accessed @mapped_identities = mapped_identities == nil ? nil : mapped_identities @resource_id = resource_id == nil ? "" : resource_id end |
Instance Attribute Details
#group_id ⇒ Object
The unique identifier of the group associated with this entitlement, if any.
8119 8120 8121 |
# File 'lib/models/porcelain.rb', line 8119 def group_id @group_id end |
#last_accessed ⇒ Object
The most recent time at which any account in the organization accessed this resource. Empty if the resource has never been accessed.
8122 8123 8124 |
# File 'lib/models/porcelain.rb', line 8122 def last_accessed @last_accessed end |
#mapped_identities ⇒ Object
The mapped identity privileges for this entitlement, such as Kubernetes group memberships.
8124 8125 8126 |
# File 'lib/models/porcelain.rb', line 8124 def mapped_identities @mapped_identities end |
#resource_id ⇒ Object
The unique identifier of the Resource to which the role grants access.
8126 8127 8128 |
# File 'lib/models/porcelain.rb', line 8126 def resource_id @resource_id end |
Instance Method Details
#to_json(options = {}) ⇒ Object
8140 8141 8142 8143 8144 8145 8146 |
# File 'lib/models/porcelain.rb', line 8140 def to_json( = {}) hash = {} self.instance_variables.each do |var| hash[var.id2name.delete_prefix("@")] = self.instance_variable_get var end hash.to_json end |