Class: Rafflesia::DatasetOntologyBindingListData
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::DatasetOntologyBindingListData
- Defined in:
- lib/rafflesia/ontology/dataset_ontology_binding_list_data.rb
Constant Summary collapse
- HASH_ATTRS =
{ data: :data, has_more: :has_more, object: :object, ontology_digest: :ontology_digest, ontology_version: :ontology_version }.freeze
Instance Attribute Summary collapse
-
#data ⇒ Object
Returns the value of attribute data.
-
#has_more ⇒ Object
Returns the value of attribute has_more.
-
#object ⇒ Object
Returns the value of attribute object.
-
#ontology_digest ⇒ Object
Returns the value of attribute ontology_digest.
-
#ontology_version ⇒ Object
Returns the value of attribute ontology_version.
Instance Method Summary collapse
-
#initialize(json) ⇒ DatasetOntologyBindingListData
constructor
A new instance of DatasetOntologyBindingListData.
Constructor Details
#initialize(json) ⇒ DatasetOntologyBindingListData
Returns a new instance of DatasetOntologyBindingListData.
23 24 25 26 27 28 29 30 31 |
# File 'lib/rafflesia/ontology/dataset_ontology_binding_list_data.rb', line 23 def initialize(json) super() hash = self.class.normalize(json) @data = (hash[:data] || []).map { |item| item ? Rafflesia::DatasetOntologyBinding.new(item) : nil } @has_more = hash[:has_more] @object = hash[:object] @ontology_digest = hash[:ontology_digest] @ontology_version = hash[:ontology_version] end |
Instance Attribute Details
#data ⇒ Object
Returns the value of attribute data.
16 17 18 |
# File 'lib/rafflesia/ontology/dataset_ontology_binding_list_data.rb', line 16 def data @data end |
#has_more ⇒ Object
Returns the value of attribute has_more.
16 17 18 |
# File 'lib/rafflesia/ontology/dataset_ontology_binding_list_data.rb', line 16 def has_more @has_more end |
#object ⇒ Object
Returns the value of attribute object.
16 17 18 |
# File 'lib/rafflesia/ontology/dataset_ontology_binding_list_data.rb', line 16 def object @object end |
#ontology_digest ⇒ Object
Returns the value of attribute ontology_digest.
16 17 18 |
# File 'lib/rafflesia/ontology/dataset_ontology_binding_list_data.rb', line 16 def ontology_digest @ontology_digest end |
#ontology_version ⇒ Object
Returns the value of attribute ontology_version.
16 17 18 |
# File 'lib/rafflesia/ontology/dataset_ontology_binding_list_data.rb', line 16 def ontology_version @ontology_version end |