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.



698
699
700
701
702
703
704
705
706
707
708
# File 'lib/models/porcelain.rb', line 698

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.



690
691
692
# File 'lib/models/porcelain.rb', line 690

def id
  @id
end

#nameObject

Unique human-readable name of the SecretStore.



692
693
694
# File 'lib/models/porcelain.rb', line 692

def name
  @name
end

#regionObject

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



694
695
696
# File 'lib/models/porcelain.rb', line 694

def region
  @region
end

#tagsObject

Tags is a map of key, value pairs.



696
697
698
# File 'lib/models/porcelain.rb', line 696

def tags
  @tags
end

Instance Method Details

#to_json(options = {}) ⇒ Object



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

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