module Trader
Constants
- VERSION
Public Class Methods
account(_backend, _credentials)
click to toggle source
# File lib/trade-o-matic.rb, line 51 def self.account(_backend, _credentials) exchange(_backend).login(_credentials) end
exchange(_backend)
click to toggle source
# File lib/trade-o-matic.rb, line 43 def self.exchange(_backend) Exchange.new BackendFactory.build(_backend) end
game()
click to toggle source
# File lib/trade-o-matic.rb, line 61 def self.game require 'trade-o-matic/adapters/game_backend' GameBackend.new end
market(_backend, _pair, _quote=nil)
click to toggle source
# File lib/trade-o-matic.rb, line 47 def self.market(_backend, _pair, _quote=nil) exchange(_backend).market_for(_pair, _quote) end
setup_game_backend(&_block)
click to toggle source
# File lib/trade-o-matic.rb, line 55 def self.setup_game_backend(&_block) require 'trade-o-matic/adapters/game_backend' GameBackend::Configuration.tap &_block nil end