Class: Xtb::Http::ProfitCalculation
- Defined in:
- lib/xtb/http/profit_calculation.rb
Overview
Constant Summary collapse
- ProfitCalculationResponse =
Data.define(:profit)
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(close_price, cmd, open_price, symbol, volume) ⇒ ProfitCalculation
constructor
A new instance of ProfitCalculation.
Methods inherited from Command
Constructor Details
#initialize(close_price, cmd, open_price, symbol, volume) ⇒ ProfitCalculation
Returns a new instance of ProfitCalculation.
14 15 16 17 18 19 20 21 22 |
# File 'lib/xtb/http/profit_calculation.rb', line 14 def initialize(close_price, cmd, open_price, symbol, volume) @close_price = close_price @cmd = cmd @open_price = open_price @symbol = symbol @volume = volume super() end |
Instance Method Details
#call ⇒ Object
24 25 26 |
# File 'lib/xtb/http/profit_calculation.rb', line 24 def call ProfitCalculationResponse.new(**super.return_data) end |