class AWS::EC2::AvailabilityZone

Represents an EC2 availability zone. You can use this class to get information about the state of an availability zone that is available to your account.

@attr_reader [String,nil] region_name Returns the region name

of the availability zone.

@attr_reader [Symbol] state Returns the state of the availability

zone, e.g. +:available+.

@attr_reader [Array<String>] messages Returns a list of messages about the

Availability Zone.

Attributes

name[R]

@return [String] Returns the name of the availability zone,

e.g. "us-east-1a".
to_s[R]

@return [String] Returns the name of the availability zone,

e.g. "us-east-1a".
to_str[R]

@return [String] Returns the name of the availability zone,

e.g. "us-east-1a".

Public Class Methods

new(name, options = {}) click to toggle source

@param [String] name The name of the availability zone.

# File lib/aws/ec2/availability_zone.rb, line 33
def initialize name, options = {}
  @name = name
  if options[:region]
    options[:region_name] = options[:region].name
    
  end
  super
end

Protected Class Methods

inflected_name() click to toggle source
# File lib/aws/ec2/availability_zone.rb, line 80
def self.inflected_name
  "zone"
end

Public Instance Methods

region() click to toggle source

@return [Region] Returns the region of this availability zone.

# File lib/aws/ec2/availability_zone.rb, line 65
def region
  Region.new(self.region_name, :config => config)
end

Protected Instance Methods

describe_call_name() click to toggle source
# File lib/aws/ec2/availability_zone.rb, line 70
def describe_call_name
  :describe_availability_zones
end
inflected_name() click to toggle source
# File lib/aws/ec2/availability_zone.rb, line 75
def inflected_name
  self.class.inflected_name
end