Class: Rafflesia::RepositoryRef
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Rafflesia::RepositoryRef
- Defined in:
- lib/rafflesia/foundry/repository_ref.rb
Constant Summary collapse
- HASH_ATTRS =
{ full_name: :full_name, id: :id, kind: :kind, namespace: :namespace, object: :object, slug: :slug }.freeze
Instance Attribute Summary collapse
-
#full_name ⇒ Object
Returns the value of attribute full_name.
-
#id ⇒ Object
Returns the value of attribute id.
-
#kind ⇒ Object
Returns the value of attribute kind.
-
#namespace ⇒ Object
Returns the value of attribute namespace.
-
#object ⇒ Object
Returns the value of attribute object.
-
#slug ⇒ Object
Returns the value of attribute slug.
Instance Method Summary collapse
-
#initialize(json) ⇒ RepositoryRef
constructor
A new instance of RepositoryRef.
Constructor Details
#initialize(json) ⇒ RepositoryRef
Returns a new instance of RepositoryRef.
25 26 27 28 29 30 31 32 33 34 |
# File 'lib/rafflesia/foundry/repository_ref.rb', line 25 def initialize(json) super() hash = self.class.normalize(json) @full_name = hash[:full_name] @id = hash[:id] @kind = hash[:kind] @namespace = hash[:namespace] @object = hash[:object] @slug = hash[:slug] end |
Instance Attribute Details
#full_name ⇒ Object
Returns the value of attribute full_name.
17 18 19 |
# File 'lib/rafflesia/foundry/repository_ref.rb', line 17 def full_name @full_name end |
#id ⇒ Object
Returns the value of attribute id.
17 18 19 |
# File 'lib/rafflesia/foundry/repository_ref.rb', line 17 def id @id end |
#kind ⇒ Object
Returns the value of attribute kind.
17 18 19 |
# File 'lib/rafflesia/foundry/repository_ref.rb', line 17 def kind @kind end |
#namespace ⇒ Object
Returns the value of attribute namespace.
17 18 19 |
# File 'lib/rafflesia/foundry/repository_ref.rb', line 17 def namespace @namespace end |
#object ⇒ Object
Returns the value of attribute object.
17 18 19 |
# File 'lib/rafflesia/foundry/repository_ref.rb', line 17 def object @object end |
#slug ⇒ Object
Returns the value of attribute slug.
17 18 19 |
# File 'lib/rafflesia/foundry/repository_ref.rb', line 17 def slug @slug end |