/// <summary> /// Initializes a new instance of the <see cref="MarketOrderTransaction" /> class. /// </summary> /// <param name="Id">The Transaction's Identifier..</param> /// <param name="Time">The date/time when the Transaction was created..</param> /// <param name="UserID">The ID of the user that initiated the creation of the Transaction..</param> /// <param name="AccountID">The ID of the Account the Transaction was created for..</param> /// <param name="BatchID">The ID of the \"batch\" that the Transaction belongs to. Transactions in the same batch are applied to the Account simultaneously..</param> /// <param name="RequestID">The Request ID of the request which generated the transaction..</param> /// <param name="Type">The Type of the Transaction. Always set to \"MARKET_ORDER\" in a MarketOrderTransaction..</param> /// <param name="Instrument">The Market Order's Instrument..</param> /// <param name="Units">The quantity requested to be filled by the Market Order. A posititive number of units results in a long Order, and a negative number of units results in a short Order..</param> /// <param name="TimeInForce">The time-in-force requested for the Market Order. Restricted to FOK or IOC for a MarketOrder..</param> /// <param name="PriceBound">The worst price that the client is willing to have the Market Order filled at..</param> /// <param name="PositionFill">Specification of how Positions in the Account are modified when the Order is filled..</param> /// <param name="TradeClose">TradeClose.</param> /// <param name="LongPositionCloseout">LongPositionCloseout.</param> /// <param name="ShortPositionCloseout">ShortPositionCloseout.</param> /// <param name="MarginCloseout">MarginCloseout.</param> /// <param name="DelayedTradeClose">DelayedTradeClose.</param> /// <param name="Reason">The reason that the Market Order was created.</param> /// <param name="ClientExtensions">ClientExtensions.</param> /// <param name="TakeProfitOnFill">TakeProfitOnFill.</param> /// <param name="StopLossOnFill">StopLossOnFill.</param> /// <param name="TrailingStopLossOnFill">TrailingStopLossOnFill.</param> /// <param name="TradeClientExtensions">TradeClientExtensions.</param> public MarketOrderTransaction(string Id = default(string), string Time = default(string), int?UserID = default(int?), string AccountID = default(string), string BatchID = default(string), string RequestID = default(string), TypeEnum?Type = default(TypeEnum?), string Instrument = default(string), string Units = default(string), TimeInForceEnum?TimeInForce = default(TimeInForceEnum?), string PriceBound = default(string), PositionFillEnum?PositionFill = default(PositionFillEnum?), MarketOrderTradeClose TradeClose = default(MarketOrderTradeClose), MarketOrderPositionCloseout LongPositionCloseout = default(MarketOrderPositionCloseout), MarketOrderPositionCloseout ShortPositionCloseout = default(MarketOrderPositionCloseout), MarketOrderMarginCloseout MarginCloseout = default(MarketOrderMarginCloseout), MarketOrderDelayedTradeClose DelayedTradeClose = default(MarketOrderDelayedTradeClose), ReasonEnum?Reason = default(ReasonEnum?), ClientExtensions ClientExtensions = default(ClientExtensions), TakeProfitDetails TakeProfitOnFill = default(TakeProfitDetails), StopLossDetails StopLossOnFill = default(StopLossDetails), TrailingStopLossDetails TrailingStopLossOnFill = default(TrailingStopLossDetails), ClientExtensions TradeClientExtensions = default(ClientExtensions)) { this.Id = Id; this.Time = Time; this.UserID = UserID; this.AccountID = AccountID; this.BatchID = BatchID; this.RequestID = RequestID; this.Type = Type; this.Instrument = Instrument; this.Units = Units; this.TimeInForce = TimeInForce; this.PriceBound = PriceBound; this.PositionFill = PositionFill; this.TradeClose = TradeClose; this.LongPositionCloseout = LongPositionCloseout; this.ShortPositionCloseout = ShortPositionCloseout; this.MarginCloseout = MarginCloseout; this.DelayedTradeClose = DelayedTradeClose; this.Reason = Reason; this.ClientExtensions = ClientExtensions; this.TakeProfitOnFill = TakeProfitOnFill; this.StopLossOnFill = StopLossOnFill; this.TrailingStopLossOnFill = TrailingStopLossOnFill; this.TradeClientExtensions = TradeClientExtensions; }
/// <summary> /// Initializes a new instance of the <see cref="MarketOrder" /> class. /// </summary> /// <param name="Id">The Order's identifier, unique within the Order's Account..</param> /// <param name="CreateTime">The time when the Order was created..</param> /// <param name="State">The current state of the Order..</param> /// <param name="ClientExtensions">ClientExtensions.</param> /// <param name="Type">The type of the Order. Always set to \"MARKET\" for Market Orders..</param> /// <param name="Instrument">The Market Order's Instrument..</param> /// <param name="Units">The quantity requested to be filled by the Market Order. A posititive number of units results in a long Order, and a negative number of units results in a short Order..</param> /// <param name="TimeInForce">The time-in-force requested for the Market Order. Restricted to FOK or IOC for a MarketOrder..</param> /// <param name="PriceBound">The worst price that the client is willing to have the Market Order filled at..</param> /// <param name="PositionFill">Specification of how Positions in the Account are modified when the Order is filled..</param> /// <param name="TradeClose">TradeClose.</param> /// <param name="LongPositionCloseout">LongPositionCloseout.</param> /// <param name="ShortPositionCloseout">ShortPositionCloseout.</param> /// <param name="MarginCloseout">MarginCloseout.</param> /// <param name="DelayedTradeClose">DelayedTradeClose.</param> /// <param name="TakeProfitOnFill">TakeProfitOnFill.</param> /// <param name="StopLossOnFill">StopLossOnFill.</param> /// <param name="TrailingStopLossOnFill">TrailingStopLossOnFill.</param> /// <param name="TradeClientExtensions">TradeClientExtensions.</param> /// <param name="FillingTransactionID">ID of the Transaction that filled this Order (only provided when the Order's state is FILLED).</param> /// <param name="FilledTime">Date/time when the Order was filled (only provided when the Order's state is FILLED).</param> /// <param name="TradeOpenedID">Trade ID of Trade opened when the Order was filled (only provided when the Order's state is FILLED and a Trade was opened as a result of the fill).</param> /// <param name="TradeReducedID">Trade ID of Trade reduced when the Order was filled (only provided when the Order's state is FILLED and a Trade was reduced as a result of the fill).</param> /// <param name="TradeClosedIDs">Trade IDs of Trades closed when the Order was filled (only provided when the Order's state is FILLED and one or more Trades were closed as a result of the fill).</param> /// <param name="CancellingTransactionID">ID of the Transaction that cancelled the Order (only provided when the Order's state is CANCELLED).</param> /// <param name="CancelledTime">Date/time when the Order was cancelled (only provided when the state of the Order is CANCELLED).</param> public MarketOrder(string Id = default(string), string CreateTime = default(string), StateEnum?State = default(StateEnum?), ClientExtensions ClientExtensions = default(ClientExtensions), TypeEnum?Type = default(TypeEnum?), string Instrument = default(string), string Units = default(string), TimeInForceEnum?TimeInForce = default(TimeInForceEnum?), string PriceBound = default(string), PositionFillEnum?PositionFill = default(PositionFillEnum?), MarketOrderTradeClose TradeClose = default(MarketOrderTradeClose), MarketOrderPositionCloseout LongPositionCloseout = default(MarketOrderPositionCloseout), MarketOrderPositionCloseout ShortPositionCloseout = default(MarketOrderPositionCloseout), MarketOrderMarginCloseout MarginCloseout = default(MarketOrderMarginCloseout), MarketOrderDelayedTradeClose DelayedTradeClose = default(MarketOrderDelayedTradeClose), TakeProfitDetails TakeProfitOnFill = default(TakeProfitDetails), StopLossDetails StopLossOnFill = default(StopLossDetails), TrailingStopLossDetails TrailingStopLossOnFill = default(TrailingStopLossDetails), ClientExtensions TradeClientExtensions = default(ClientExtensions), string FillingTransactionID = default(string), string FilledTime = default(string), string TradeOpenedID = default(string), string TradeReducedID = default(string), List <string> TradeClosedIDs = default(List <string>), string CancellingTransactionID = default(string), string CancelledTime = default(string)) { this.Id = Id; this.CreateTime = CreateTime; this.State = State; this.ClientExtensions = ClientExtensions; this.Type = Type; this.Instrument = Instrument; this.Units = Units; this.TimeInForce = TimeInForce; this.PriceBound = PriceBound; this.PositionFill = PositionFill; this.TradeClose = TradeClose; this.LongPositionCloseout = LongPositionCloseout; this.ShortPositionCloseout = ShortPositionCloseout; this.MarginCloseout = MarginCloseout; this.DelayedTradeClose = DelayedTradeClose; this.TakeProfitOnFill = TakeProfitOnFill; this.StopLossOnFill = StopLossOnFill; this.TrailingStopLossOnFill = TrailingStopLossOnFill; this.TradeClientExtensions = TradeClientExtensions; this.FillingTransactionID = FillingTransactionID; this.FilledTime = FilledTime; this.TradeOpenedID = TradeOpenedID; this.TradeReducedID = TradeReducedID; this.TradeClosedIDs = TradeClosedIDs; this.CancellingTransactionID = CancellingTransactionID; this.CancelledTime = CancelledTime; }