Sha256: b424950ae7c15168f3454d7523741599c02a7b7d54f093902a38373dd131cfff

Contents?: true

Size: 339 Bytes

Versions: 3

Compression:

Stored size: 339 Bytes

Contents

class Ec2Tools
  autoload :EC2, 'ec2_tools/ec2'
  autoload :Config, 'ec2_tools/config'
  
  @ec2 = nil
  
  def initialize(config_file = nil)
    @ec2 = EC2.new(Config.load(config_file))
  end
  
  def method_missing(name, *args)
    define_method(:name) do |_args|
      @ec2.send(name, _args)
    end
    self.send(name, args)
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
ec2_tools-0.2.1 lib/ec2_tools.rb
ec2_tools-0.2.0 lib/ec2_tools.rb
ec2_tools-0.1.0 lib/ec2_tools.rb