Class: Rafflesia::OntologySnapshotData
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::OntologySnapshotData
- Defined in:
- lib/rafflesia/ontology/ontology_snapshot_data.rb
Constant Summary collapse
- HASH_ATTRS =
{ available_digests: :available_digests, connectivity_classifications: :connectivity_classifications, coordinate_systems: :coordinate_systems, description: :description, entity_types: :entity_types, id: :id, identifier_namespaces: :identifier_namespaces, object: :object, ontology_digest: :ontology_digest, ontology_version: :ontology_version, relations: :relations, relationship_count: :relationship_count, semantic_digest: :semantic_digest, snapshot_digest: :snapshot_digest, source_digest: :source_digest, units: :units, url: :url, value_kinds: :value_kinds }.freeze
Instance Attribute Summary collapse
-
#available_digests ⇒ Object
Returns the value of attribute available_digests.
-
#connectivity_classifications ⇒ Object
Returns the value of attribute connectivity_classifications.
-
#coordinate_systems ⇒ Object
Returns the value of attribute coordinate_systems.
-
#description ⇒ Object
Returns the value of attribute description.
-
#entity_types ⇒ Object
Returns the value of attribute entity_types.
-
#id ⇒ Object
Returns the value of attribute id.
-
#identifier_namespaces ⇒ Object
Returns the value of attribute identifier_namespaces.
-
#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.
-
#relations ⇒ Object
Returns the value of attribute relations.
-
#relationship_count ⇒ Object
Returns the value of attribute relationship_count.
-
#semantic_digest ⇒ Object
Returns the value of attribute semantic_digest.
-
#snapshot_digest ⇒ Object
Returns the value of attribute snapshot_digest.
-
#source_digest ⇒ Object
Returns the value of attribute source_digest.
-
#units ⇒ Object
Returns the value of attribute units.
-
#url ⇒ Object
Returns the value of attribute url.
-
#value_kinds ⇒ Object
Returns the value of attribute value_kinds.
Instance Method Summary collapse
-
#initialize(json) ⇒ OntologySnapshotData
constructor
A new instance of OntologySnapshotData.
Constructor Details
#initialize(json) ⇒ OntologySnapshotData
Returns a new instance of OntologySnapshotData.
49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 49 def initialize(json) super() hash = self.class.normalize(json) @available_digests = (hash[:available_digests] || []) @connectivity_classifications = (hash[:connectivity_classifications] || []).map { |item| item ? Rafflesia::OntologyConnectivityClassificationData.new(item) : nil } @coordinate_systems = (hash[:coordinate_systems] || []).map { |item| item ? Rafflesia::OntologyVocabularyData.new(item) : nil } @description = hash[:description] @entity_types = (hash[:entity_types] || []).map { |item| item ? Rafflesia::OntologyVocabularyData.new(item) : nil } @id = hash[:id] @identifier_namespaces = (hash[:identifier_namespaces] || []).map { |item| item ? Rafflesia::OntologyVocabularyData.new(item) : nil } @object = hash[:object] @ontology_digest = hash[:ontology_digest] @ontology_version = hash[:ontology_version] @relations = (hash[:relations] || []).map { |item| item ? Rafflesia::OntologyRelationData.new(item) : nil } @relationship_count = hash[:relationship_count] @semantic_digest = hash[:semantic_digest] @snapshot_digest = hash[:snapshot_digest] @source_digest = hash[:source_digest] @units = (hash[:units] || []).map { |item| item ? Rafflesia::OntologyVocabularyData.new(item) : nil } @url = hash[:url] @value_kinds = (hash[:value_kinds] || []).map { |item| item ? Rafflesia::OntologyVocabularyData.new(item) : nil } end |
Instance Attribute Details
#available_digests ⇒ Object
Returns the value of attribute available_digests.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def available_digests @available_digests end |
#connectivity_classifications ⇒ Object
Returns the value of attribute connectivity_classifications.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def connectivity_classifications @connectivity_classifications end |
#coordinate_systems ⇒ Object
Returns the value of attribute coordinate_systems.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def coordinate_systems @coordinate_systems end |
#description ⇒ Object
Returns the value of attribute description.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def description @description end |
#entity_types ⇒ Object
Returns the value of attribute entity_types.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def entity_types @entity_types end |
#id ⇒ Object
Returns the value of attribute id.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def id @id end |
#identifier_namespaces ⇒ Object
Returns the value of attribute identifier_namespaces.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def identifier_namespaces @identifier_namespaces end |
#object ⇒ Object
Returns the value of attribute object.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def object @object end |
#ontology_digest ⇒ Object
Returns the value of attribute ontology_digest.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def ontology_digest @ontology_digest end |
#ontology_version ⇒ Object
Returns the value of attribute ontology_version.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def ontology_version @ontology_version end |
#relations ⇒ Object
Returns the value of attribute relations.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def relations @relations end |
#relationship_count ⇒ Object
Returns the value of attribute relationship_count.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def relationship_count @relationship_count end |
#semantic_digest ⇒ Object
Returns the value of attribute semantic_digest.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def semantic_digest @semantic_digest end |
#snapshot_digest ⇒ Object
Returns the value of attribute snapshot_digest.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def snapshot_digest @snapshot_digest end |
#source_digest ⇒ Object
Returns the value of attribute source_digest.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def source_digest @source_digest end |
#units ⇒ Object
Returns the value of attribute units.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def units @units end |
#url ⇒ Object
Returns the value of attribute url.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def url @url end |
#value_kinds ⇒ Object
Returns the value of attribute value_kinds.
29 30 31 |
# File 'lib/rafflesia/ontology/ontology_snapshot_data.rb', line 29 def value_kinds @value_kinds end |