Class: ScimEngine::ComplexTypes::Base
- Inherits:
-
Object
- Object
- ScimEngine::ComplexTypes::Base
- Includes:
- ActiveModel::Model, Errors, Schema::DerivedAttributes
- Defined in:
- app/models/scim_engine/complex_types/base.rb
Overview
This class represents complex types that could be used inside SCIM resources. Each complex type must inherit from this class. They also need to have their own schema defined.
Instance Method Summary collapse
-
#as_json(options = {}) ⇒ Object
Converts the object to its SCIM representation which is always a json representation.
-
#initialize(options = {}) ⇒ Base
constructor
A new instance of Base.
Methods included from Errors
Constructor Details
#initialize(options = {}) ⇒ Base
Returns a new instance of Base.
23 24 25 26 |
# File 'app/models/scim_engine/complex_types/base.rb', line 23 def initialize(={}) super @errors = ActiveModel::Errors.new(self) end |
Instance Method Details
#as_json(options = {}) ⇒ Object
Converts the object to its SCIM representation which is always a json representation
31 32 33 34 |
# File 'app/models/scim_engine/complex_types/base.rb', line 31 def as_json(={}) [:except] ||= ['errors'] super.except() end |