Class: SDM::AWSStore

Inherits:
Object
  • Object
show all
Defined in:
lib/models/porcelain.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id: nil, name: nil, region: nil, tags: nil) ⇒ AWSStore

Returns a new instance of AWSStore.



708
709
710
711
712
713
714
715
716
717
718
# File 'lib/models/porcelain.rb', line 708

def initialize(
  id: nil,
  name: nil,
  region: nil,
  tags: nil
)
  @id = id == nil ? "" : id
  @name = name == nil ? "" : name
  @region = region == nil ? "" : region
  @tags = tags == nil ? SDM::_porcelain_zero_value_tags() : tags
end

Instance Attribute Details

#idObject

Unique identifier of the SecretStore.



700
701
702
# File 'lib/models/porcelain.rb', line 700

def id
  @id
end

#nameObject

Unique human-readable name of the SecretStore.



702
703
704
# File 'lib/models/porcelain.rb', line 702

def name
  @name
end

#regionObject

The AWS region to target e.g. us-east-1



704
705
706
# File 'lib/models/porcelain.rb', line 704

def region
  @region
end

#tagsObject

Tags is a map of key, value pairs.



706
707
708
# File 'lib/models/porcelain.rb', line 706

def tags
  @tags
end

Instance Method Details

#to_json(options = {}) ⇒ Object



720
721
722
723
724
725
726
# File 'lib/models/porcelain.rb', line 720

def to_json(options = {})
  hash = {}
  self.instance_variables.each do |var|
    hash[var.id2name.delete_prefix("@")] = self.instance_variable_get var
  end
  hash.to_json
end