module Trader::GameBackend::SFM
Constants
- FACTOR
Public Instance Methods
decode(_amount)
click to toggle source
# File lib/trade-o-matic/adapters/game_backend/sfm.rb, line 17 def decode(_amount) return nil if _amount.nil? _amount.to_f / FACTOR end
encode(_amount)
click to toggle source
# File lib/trade-o-matic/adapters/game_backend/sfm.rb, line 12 def encode(_amount) return nil if _amount.nil? (_amount * FACTOR).to_i end
quote(_volume, _price)
click to toggle source
# File lib/trade-o-matic/adapters/game_backend/sfm.rb, line 8 def quote(_volume, _price) (_volume * _price) / FACTOR end