Class: Rafflesia::MountUpsertData

Inherits:
Types::BaseModel
  • Object
show all
Defined in:
lib/rafflesia/registry/mount_upsert_data.rb

Constant Summary collapse

HASH_ATTRS =
{
  mount: :mount,
  view: :view
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ MountUpsertData

Returns a new instance of MountUpsertData.



17
18
19
20
21
22
# File 'lib/rafflesia/registry/mount_upsert_data.rb', line 17

def initialize(json)
  super()
  hash = self.class.normalize(json)
  @mount = hash[:mount] ? Rafflesia::RegistryMount.new(hash[:mount]) : nil
  @view = hash[:view] ? Rafflesia::CatalogView.new(hash[:view]) : nil
end

Instance Attribute Details

#mountObject

Returns the value of attribute mount.



13
14
15
# File 'lib/rafflesia/registry/mount_upsert_data.rb', line 13

def mount
  @mount
end

#viewObject

Returns the value of attribute view.



13
14
15
# File 'lib/rafflesia/registry/mount_upsert_data.rb', line 13

def view
  @view
end