Class: Scimitar::Schema::Rbac::Application

Inherits:
Base
  • Object
show all
Defined in:
lib/scimitar/rbac/schema/application.rb

Overview

SCIM schema for the Application resource. Applications represent target systems / Service Providers (SPs). Entitlements are application-specific (each belongs to one application).

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeApplication

Returns a new instance of Application.



10
11
12
13
14
15
16
17
# File 'lib/scimitar/rbac/schema/application.rb', line 10

def initialize
  super(
    name:            "Application",
    id:              self.class.id,
    description:     "Represents a target application (service provider) in the RBAC model.",
    scim_attributes: self.class.scim_attributes
  )
end

Class Method Details

.idObject



19
20
21
# File 'lib/scimitar/rbac/schema/application.rb', line 19

def self.id
  "urn:ietf:params:scim:schemas:extension:rbac:2.0:Application"
end

.scim_attributesObject



23
24
25
26
27
28
29
30
31
32
# File 'lib/scimitar/rbac/schema/application.rb', line 23

def self.scim_attributes
  @scim_attributes ||= [
    Scimitar::Schema::Attribute.new(name: "displayName", type: "string", required: true),
    Scimitar::Schema::Attribute.new(name: "description", type: "string"),
    Scimitar::Schema::Attribute.new(name: "active",      type: "boolean"),

    Scimitar::Schema::Attribute.new(name: "entitlements", multiValued: true,
      complexType: Scimitar::ComplexTypes::Rbac::EntitlementAssignment, mutability: "readOnly"),
  ]
end