Class: Colombo::Client

Inherits:
Object
  • Object
show all
Includes:
Request
Defined in:
lib/colombo/client.rb

Instance Method Summary collapse

Methods included from Request

#request

Constructor Details

#initialize(options = {}) ⇒ Client

Returns a new instance of Client.



10
11
12
13
14
15
16
17
# File 'lib/colombo/client.rb', line 10

def initialize(options={})

  merge_options = Colombo.options.merge(options)
  Configuration::VALID_CONFIG_KEYS.each do |key|
    self.send("#{key}=", merge_options[key])
  end

end

Instance Method Details

#droplet(droplet_id) ⇒ Object



19
20
21
# File 'lib/colombo/client.rb', line 19

def droplet(droplet_id)
  Droplet.find(self, droplet_id)
end

#dropletsObject



23
24
25
# File 'lib/colombo/client.rb', line 23

def droplets
  Droplets.new(self)
end

#images(options = {}) ⇒ Object



31
32
33
# File 'lib/colombo/client.rb', line 31

def images(options={})
  Images.new(self, options)
end

#regionsObject



27
28
29
# File 'lib/colombo/client.rb', line 27

def regions
  Regions.new(self)
end

#sizesObject



35
36
37
# File 'lib/colombo/client.rb', line 35

def sizes
  Sizes.new(self)
end

#ssh_keysObject



39
40
41
# File 'lib/colombo/client.rb', line 39

def ssh_keys
  SshKeys.new(self)
end