Method: Fog::Compute::AWS::Subnets#all
- Defined in:
- lib/fog/aws/models/compute/subnets.rb
#all(filters = filters) ⇒ Object
Returns an array of all Subnets that have been created
AWS.subnets.all
Returns
Returns an array of all VPCs
>> AWS.subnets.all <Fog::AWS::Compute::Subnet filters={} [ subnet_id=subnet-someId, state=, vpc_id=vpc-someId cidr_block=someIpRange available_ip_address_count=someInt tagset=nil ] >
60 61 62 63 64 65 66 67 68 |
# File 'lib/fog/aws/models/compute/subnets.rb', line 60 def all(filters = filters) unless filters.is_a?(Hash) Fog::Logger.warning("all with #{filters.class} param is deprecated, use all('subnet-id' => []) instead [light_black](#{caller.first})[/]") filters = {'subnet-id' => [*filters]} end self.filters = filters data = connection.describe_subnets(filters).body load(data['subnetSet']) end |