Class: Fog::AWS::ElasticBeanstalk::Applications

Inherits:
Collection
  • Object
show all
Defined in:
lib/fog/aws/models/beanstalk/applications.rb

Instance Method Summary collapse

Instance Method Details

#all(application_names = []) ⇒ Object



9
10
11
12
# File 'lib/fog/aws/models/beanstalk/applications.rb', line 9

def all(application_names=[])
  data = service.describe_applications(application_names).body['DescribeApplicationsResult']['Applications']
  load(data) # data is an array of attribute hashes
end

#get(application_name) ⇒ Object



14
15
16
17
18
# File 'lib/fog/aws/models/beanstalk/applications.rb', line 14

def get(application_name)
  if data = service.describe_applications([application_name]).body['DescribeApplicationsResult']['Applications'].first
    new(data)
  end
end