class Fog::AWS::IAM::AccessKeys
Public Class Methods
new(attributes = {})
click to toggle source
Calls superclass method
# File lib/fog/aws/models/iam/access_keys.rb, line 10 def initialize(attributes = {}) @username = attributes[:username] super end
Public Instance Methods
all()
click to toggle source
# File lib/fog/aws/models/iam/access_keys.rb, line 15 def all data = service.list_access_keys('UserName'=> @username).body['AccessKeys'] # AWS response doesn't contain the UserName, this injects it data.each {|access_key| access_key['UserName'] = @username } load(data) end
get(identity)
click to toggle source
# File lib/fog/aws/models/iam/access_keys.rb, line 22 def get(identity) self.all.select {|access_key| access_key.id == identity}.first end
new(attributes = {})
click to toggle source
Calls superclass method
# File lib/fog/aws/models/iam/access_keys.rb, line 26 def new(attributes = {}) super({ :username => @username }.merge!(attributes)) end