Exemplo n.º 1
0
        /// <summary>
        /// Gets the amount of buying power reserved to maintain the specified position
        /// </summary>
        /// <param name="context">A context object containing the security</param>
        /// <returns>The reserved buying power in account currency</returns>
        public virtual ReservedBuyingPowerForPosition GetReservedBuyingPowerForPosition(ReservedBuyingPowerForPositionContext context)
        {
            var maintenanceMargin = GetMaintenanceMargin(context.Security);

            return(context.ResultInAccountCurrency(maintenanceMargin));
        }
Exemplo n.º 2
0
 /// <summary>
 /// Gets the amount of buying power reserved to maintain the specified position
 /// </summary>
 /// <param name="context">A context object containing the security</param>
 /// <returns>The reserved buying power in account currency</returns>
 public override ReservedBuyingPowerForPosition GetReservedBuyingPowerForPosition(ReservedBuyingPowerForPositionContext context)
 {
     // Always returns 0. Since we're purchasing currencies outright, the position doesn't consume buying power
     return(context.ResultInAccountCurrency(0m));
 }