Example #1
0
 internal SymbolInfo(MT4 conn, SDParser p)
 {
     //
     IsSelected       = p.popBoolean();
     IsFloatingSpread = p.popBoolean();
     //
     SessionDeals      = p.popLong();
     SessionBuyOrders  = p.popLong();
     SessionSellOrders = p.popLong();
     Volume            = p.popLong();
     VolumeHigh        = p.popLong();
     VolumeLow         = p.popLong();
     //
     Digits      = p.popInt();
     Spread      = p.popInt();
     StopsLevel  = p.popInt();
     FreezeLevel = p.popInt();
     //
     ContractPriceCalculationMode = ((PriceCalculationMode[])Enum.GetValues(typeof(PriceCalculationMode)))[p.popInt()];
     TradeMode          = ((TradeMode[])Enum.GetValues(typeof(TradeMode)))[p.popInt()];
     SwapMode           = ((SwapMode[])Enum.GetValues(typeof(SwapMode)))[p.popInt()];
     SwapRollover3Days  = ((DayOfWeek[])Enum.GetValues(typeof(DayOfWeek)))[p.popInt()];
     TradeExecutionMode = ((TradeExecutionMode[])Enum.GetValues(typeof(TradeExecutionMode)))[p.popInt()];
     //
     Time           = conn.ToDate(p.popDouble());
     StartTime      = conn.ToDate(p.popDouble());
     ExpirationTime = conn.ToDate(p.popDouble());
     //
     ExpirationModes = ExpirationModeValues(p.popInt());
     FillingModes    = FillingModeValues(p.popInt());
     OrderModes      = OrderModeValues(p.popInt());
     //
     BaseCurrency   = p.pop();
     ProfitCurrency = p.pop();
     MarginCurrency = p.pop();
     Description    = p.pop();
     Path           = p.pop();
     //
     Bid                         = p.popDouble();
     BidHigh                     = p.popDouble();
     BidLow                      = p.popDouble();
     Ask                         = p.popDouble();
     AskHigh                     = p.popDouble();
     AskLow                      = p.popDouble();
     Last                        = p.popDouble();
     LastHigh                    = p.popDouble();
     LastLow                     = p.popDouble();
     Point                       = p.popDouble();
     TradeTickValue              = p.popDouble();
     TradeTickValueProfit        = p.popDouble();
     TradeTickValueLoss          = p.popDouble();
     TradeTickSize               = p.popDouble();
     TradeContractSize           = p.popDouble();
     MinVolume                   = p.popDouble();
     MaxVolume                   = p.popDouble();
     StepVolume                  = p.popDouble();
     LimitVolume                 = p.popDouble();
     LongSwap                    = p.popDouble();
     ShortSwap                   = p.popDouble();
     InitialMargin               = p.popDouble();
     MaintenanceMargin           = p.popDouble();
     LongMargin                  = p.popDouble();
     ShortMargin                 = p.popDouble();
     LimitMargin                 = p.popDouble();
     StopMargin                  = p.popDouble();
     StopLimitMargin             = p.popDouble();
     SessionVolume               = p.popDouble();
     SessionTurnover             = p.popDouble();
     SessionInterest             = p.popDouble();
     SessionBuyOrdersVolume      = p.popDouble();
     SessionSellOrdersVolume     = p.popDouble();
     SessionOpenPrice            = p.popDouble();
     SessionClosePrice           = p.popDouble();
     SessionAverageWeightedPrice = p.popDouble();
     SessionSettlementPrice      = p.popDouble();
     SessionMinLimitPrice        = p.popDouble();
     SessionMaxLimitPrice        = p.popDouble();
 }
Example #2
0
 public override void SetPriceCalculationMode(PriceCalculationMode mode)
 {
     VerifyResult(_cco.SetPriceCalculationMode((int)mode));
 }