Class: Rafflesia::ArtifactImportResult
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::ArtifactImportResult
- Defined in:
- lib/rafflesia/artifacts/artifact_import_result.rb
Constant Summary collapse
- HASH_ATTRS =
{ accession: :accession, artifact_doi: :artifact_doi, artifact_id: :artifact_id, kind: :kind, message: :message, object: :object, paper_doi: :paper_doi, paper_id: :paper_id, path: :path, source: :source, status: :status, structure_id: :structure_id, url: :url }.freeze
Instance Attribute Summary collapse
-
#accession ⇒ Object
Returns the value of attribute accession.
-
#artifact_doi ⇒ Object
Returns the value of attribute artifact_doi.
-
#artifact_id ⇒ Object
Returns the value of attribute artifact_id.
-
#kind ⇒ Object
Returns the value of attribute kind.
-
#message ⇒ Object
Returns the value of attribute message.
-
#object ⇒ Object
Returns the value of attribute object.
-
#paper_doi ⇒ Object
Returns the value of attribute paper_doi.
-
#paper_id ⇒ Object
Returns the value of attribute paper_id.
-
#path ⇒ Object
Returns the value of attribute path.
-
#source ⇒ Object
Returns the value of attribute source.
-
#status ⇒ Object
Returns the value of attribute status.
-
#structure_id ⇒ Object
Returns the value of attribute structure_id.
-
#url ⇒ Object
Returns the value of attribute url.
Instance Method Summary collapse
-
#initialize(json) ⇒ ArtifactImportResult
constructor
A new instance of ArtifactImportResult.
Constructor Details
#initialize(json) ⇒ ArtifactImportResult
Returns a new instance of ArtifactImportResult.
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 39 def initialize(json) super() hash = self.class.normalize(json) @accession = hash[:accession] @artifact_doi = hash[:artifact_doi] @artifact_id = hash[:artifact_id] @kind = hash[:kind] @message = hash[:message] @object = hash[:object] ? Rafflesia::ObjectRef.new(hash[:object]) : nil @paper_doi = hash[:paper_doi] @paper_id = hash[:paper_id] @path = hash[:path] @source = hash[:source] @status = hash[:status] @structure_id = hash[:structure_id] @url = hash[:url] end |
Instance Attribute Details
#accession ⇒ Object
Returns the value of attribute accession.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def accession @accession end |
#artifact_doi ⇒ Object
Returns the value of attribute artifact_doi.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def artifact_doi @artifact_doi end |
#artifact_id ⇒ Object
Returns the value of attribute artifact_id.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def artifact_id @artifact_id end |
#kind ⇒ Object
Returns the value of attribute kind.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def kind @kind end |
#message ⇒ Object
Returns the value of attribute message.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def @message end |
#object ⇒ Object
Returns the value of attribute object.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def object @object end |
#paper_doi ⇒ Object
Returns the value of attribute paper_doi.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def paper_doi @paper_doi end |
#paper_id ⇒ Object
Returns the value of attribute paper_id.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def paper_id @paper_id end |
#path ⇒ Object
Returns the value of attribute path.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def path @path end |
#source ⇒ Object
Returns the value of attribute source.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def source @source end |
#status ⇒ Object
Returns the value of attribute status.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def status @status end |
#structure_id ⇒ Object
Returns the value of attribute structure_id.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def structure_id @structure_id end |
#url ⇒ Object
Returns the value of attribute url.
24 25 26 |
# File 'lib/rafflesia/artifacts/artifact_import_result.rb', line 24 def url @url end |