示例#1
0
 /// <summary>
 /// To create the initialized order object for sell.
 /// </summary>
 /// <param name="strategy">Strategy.</param>
 /// <param name="price">Price.</param>
 /// <param name="volume">The volume. If <see langword="null" /> value is passed, then <see cref="Strategy.Volume"/> value is used.</param>
 /// <returns>The initialized order object.</returns>
 /// <remarks>
 /// The order is not registered, only the object is created.
 /// </remarks>
 public static Order SellAtLimit(this Strategy strategy, decimal price, decimal?volume = null)
 {
     return(strategy.CreateOrder(Sides.Sell, price, volume));
 }
示例#2
0
 /// <summary>
 /// To create the initialized order object of sell order at market price.
 /// </summary>
 /// <param name="strategy">Strategy.</param>
 /// <param name="volume">The volume. If <see langword="null" /> value is passed, then <see cref="Strategy.Volume"/> value is used.</param>
 /// <returns>The initialized order object.</returns>
 /// <remarks>
 /// The order is not registered, only the object is created.
 /// </remarks>
 public static Order SellAtMarket(this Strategy strategy, decimal?volume = null)
 {
     return(strategy.CreateOrder(Sides.Sell, null, volume));
 }
示例#3
0
		/// <summary>
		/// To create initialized object of buy order at market price.
		/// </summary>
		/// <param name="strategy">Strategy.</param>
		/// <param name="volume">The volume. If <see langword="null" /> value is passed, then <see cref="Strategy.Volume"/> value is used.</param>
		/// <returns>The initialized order object.</returns>
		/// <remarks>
		/// The order is not registered, only the object is created.
		/// </remarks>
		public static Order BuyAtMarket(this Strategy strategy, decimal? volume = null)
		{
			return strategy.CreateOrder(Sides.Buy, null, volume);
		}
示例#4
0
		/// <summary>
		/// To create the initialized order object for buy.
		/// </summary>
		/// <param name="strategy">Strategy.</param>
		/// <param name="price">Price.</param>
		/// <param name="volume">The volume. If <see langword="null" /> value is passed, then <see cref="Strategy.Volume"/> value is used.</param>
		/// <returns>The initialized order object.</returns>
		/// <remarks>
		/// The order is not registered, only the object is created.
		/// </remarks>
		public static Order BuyAtLimit(this Strategy strategy, decimal price, decimal? volume = null)
		{
			return strategy.CreateOrder(Sides.Buy, price, volume);
		}
示例#5
0
 /// <summary>
 /// Создать инициализированный объект заявки на покупку по рыночной цене.
 /// </summary>
 /// <remarks>
 /// Заявка не регистрируется, а только создается объект.
 /// </remarks>
 /// <param name="strategy">Стратегия.</param>
 /// <param name="volume">Объем. Если передается значение 0, то используется значение <see cref="Strategy.Volume"/>.</param>
 /// <returns>Инициализированный объект заявки.</returns>
 public static Order BuyAtMarket(this Strategy strategy, decimal volume = 0)
 {
     return(strategy.CreateOrder(Sides.Buy, 0, volume));
 }