Class: Rafflesia::ArchiveArtifactRecord
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::ArchiveArtifactRecord
- Defined in:
- lib/rafflesia/artifacts/archive_artifact_record.rb
Constant Summary collapse
- HASH_ATTRS =
{ archive_path: :archive_path, artifact_kind: :artifact_kind, association_id: :association_id, extension: :extension, group_key: :group_key, map_id: :map_id, message: :message, name: :name, object: :object, sha256: :sha_256, size_bytes: :size_bytes, status: :status, structure_id: :structure_id }.freeze
Instance Attribute Summary collapse
-
#archive_path ⇒ Object
Returns the value of attribute archive_path.
-
#artifact_kind ⇒ Object
Returns the value of attribute artifact_kind.
-
#association_id ⇒ Object
Returns the value of attribute association_id.
-
#extension ⇒ Object
Returns the value of attribute extension.
-
#group_key ⇒ Object
Returns the value of attribute group_key.
-
#map_id ⇒ Object
Returns the value of attribute map_id.
-
#message ⇒ Object
Returns the value of attribute message.
-
#name ⇒ Object
Returns the value of attribute name.
-
#object ⇒ Object
Returns the value of attribute object.
-
#sha_256 ⇒ Object
Returns the value of attribute sha_256.
-
#size_bytes ⇒ Object
Returns the value of attribute size_bytes.
-
#status ⇒ Object
Returns the value of attribute status.
-
#structure_id ⇒ Object
Returns the value of attribute structure_id.
Instance Method Summary collapse
-
#initialize(json) ⇒ ArchiveArtifactRecord
constructor
A new instance of ArchiveArtifactRecord.
Constructor Details
#initialize(json) ⇒ ArchiveArtifactRecord
Returns a new instance of ArchiveArtifactRecord.
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 39 def initialize(json) super() hash = self.class.normalize(json) @archive_path = hash[:archive_path] @artifact_kind = hash[:artifact_kind] @association_id = hash[:association_id] @extension = hash[:extension] @group_key = hash[:group_key] @map_id = hash[:map_id] @message = hash[:message] @name = hash[:name] @object = hash[:object] ? Rafflesia::ObjectRef.new(hash[:object]) : nil @sha_256 = hash[:sha256] @size_bytes = hash[:size_bytes] @status = hash[:status] @structure_id = hash[:structure_id] end |
Instance Attribute Details
#archive_path ⇒ Object
Returns the value of attribute archive_path.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def archive_path @archive_path end |
#artifact_kind ⇒ Object
Returns the value of attribute artifact_kind.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def artifact_kind @artifact_kind end |
#association_id ⇒ Object
Returns the value of attribute association_id.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def association_id @association_id end |
#extension ⇒ Object
Returns the value of attribute extension.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def extension @extension end |
#group_key ⇒ Object
Returns the value of attribute group_key.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def group_key @group_key end |
#map_id ⇒ Object
Returns the value of attribute map_id.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def map_id @map_id end |
#message ⇒ Object
Returns the value of attribute message.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def @message end |
#name ⇒ Object
Returns the value of attribute name.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def name @name end |
#object ⇒ Object
Returns the value of attribute object.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def object @object end |
#sha_256 ⇒ Object
Returns the value of attribute sha_256.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def sha_256 @sha_256 end |
#size_bytes ⇒ Object
Returns the value of attribute size_bytes.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def size_bytes @size_bytes end |
#status ⇒ Object
Returns the value of attribute status.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def status @status end |
#structure_id ⇒ Object
Returns the value of attribute structure_id.
24 25 26 |
# File 'lib/rafflesia/artifacts/archive_artifact_record.rb', line 24 def structure_id @structure_id end |