Class: Aws::Partitions::Region
- Inherits:
-
Object
- Object
- Aws::Partitions::Region
- Defined in:
- lib/aws-partitions/region.rb
Instance Attribute Summary collapse
-
#description ⇒ String
readonly
A short description of this region.
-
#name ⇒ String
readonly
The name of this region, e.g.
-
#partition_name ⇒ String
readonly
The partition this region exists in, e.g.
-
#services ⇒ Set<String>
readonly
The list of services available in this region.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Region
constructor
private
A new instance of Region.
Constructor Details
#initialize(options = {}) ⇒ Region
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Region.
14 15 16 17 18 19 |
# File 'lib/aws-partitions/region.rb', line 14 def initialize( = {}) @name = [:name] @description = [:description] @partition_name = [:partition_name] @services = [:services] end |
Instance Attribute Details
#description ⇒ String (readonly)
Returns A short description of this region.
25 26 27 |
# File 'lib/aws-partitions/region.rb', line 25 def description @description end |
#name ⇒ String (readonly)
Returns The name of this region, e.g. “us-east-1”.
22 23 24 |
# File 'lib/aws-partitions/region.rb', line 22 def name @name end |
#partition_name ⇒ String (readonly)
Returns The partition this region exists in, e.g. “aws”, “aws-cn”, “aws-us-gov”.
29 30 31 |
# File 'lib/aws-partitions/region.rb', line 29 def partition_name @partition_name end |
#services ⇒ Set<String> (readonly)
Returns The list of services available in this region. Service names are the module names as used by the AWS SDK for Ruby.
34 35 36 |
# File 'lib/aws-partitions/region.rb', line 34 def services @services end |
Class Method Details
.build(region_name, region, partition) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
39 40 41 42 43 44 45 46 |
# File 'lib/aws-partitions/region.rb', line 39 def build(region_name, region, partition) Region.new( name: region_name, description: region['description'], partition_name: partition['partition'], services: region_services(region_name, partition) ) end |