Lean  $LEAN_TAG$
QuantConnect.Brokerages.FxcmBrokerageModel Class Reference

Provides FXCM specific properties More...

Inheritance diagram for QuantConnect.Brokerages.FxcmBrokerageModel:
[legend]

Public Member Functions

 FxcmBrokerageModel (AccountType accountType=AccountType.Margin)
 Initializes a new instance of the DefaultBrokerageModel class More...
 
override bool CanSubmitOrder (Security security, Order order, out BrokerageMessageEvent message)
 Returns true if the brokerage could accept this order. This takes into account order type, security type, and order size limits. More...
 
override bool CanUpdateOrder (Security security, Order order, UpdateOrderRequest request, out BrokerageMessageEvent message)
 Returns true if the brokerage would allow updating the order as specified by the request More...
 
override IBenchmark GetBenchmark (SecurityManager securities)
 Get the benchmark for this model More...
 
override IFeeModel GetFeeModel (Security security)
 Gets a new fee model that represents this brokerage's fee structure More...
 
override ISettlementModel GetSettlementModel (Security security)
 Gets a new settlement model for the security More...
 
- Public Member Functions inherited from QuantConnect.Brokerages.DefaultBrokerageModel
 DefaultBrokerageModel (AccountType accountType=AccountType.Margin)
 Initializes a new instance of the DefaultBrokerageModel class More...
 
virtual bool CanExecuteOrder (Security security, Order order)
 Returns true if the brokerage would be able to execute this order at this time assuming market prices are sufficient for the fill to take place. This is used to emulate the brokerage fills in backtesting and paper trading. For example some brokerages may not perform executions during extended market hours. This is not intended to be checking whether or not the exchange is open, that is handled in the Security.Exchange property. More...
 
virtual void ApplySplit (List< OrderTicket > tickets, Split split)
 Applies the split to the specified order ticket More...
 
virtual decimal GetLeverage (Security security)
 Gets the brokerage's leverage for the specified security More...
 
virtual IFillModel GetFillModel (Security security)
 Gets a new fill model that represents this brokerage's fill behavior More...
 
virtual ISlippageModel GetSlippageModel (Security security)
 Gets a new slippage model that represents this brokerage's fill slippage behavior More...
 
ISettlementModel GetSettlementModel (Security security, AccountType accountType)
 Gets a new settlement model for the security More...
 
virtual IBuyingPowerModel GetBuyingPowerModel (Security security)
 Gets a new buying power model for the security, returning the default model with the security's configured leverage. For cash accounts, leverage = 1 is used. More...
 
virtual IShortableProvider GetShortableProvider (Security security)
 Gets the shortable provider More...
 
virtual IMarginInterestRateModel GetMarginInterestRateModel (Security security)
 Gets a new margin interest rate model for the security More...
 
IBuyingPowerModel GetBuyingPowerModel (Security security, AccountType accountType)
 Gets a new buying power model for the security More...
 

Public Attributes

override IReadOnlyDictionary< SecurityType, string > DefaultMarkets => DefaultMarketMap
 Gets a map of the default markets to be used for each security type More...
 
- Public Attributes inherited from QuantConnect.Brokerages.DefaultBrokerageModel
virtual decimal RequiredFreeBuyingPowerPercent => 0m
 Gets the brokerages model percentage factor used to determine the required unused buying power for the account. From 1 to 0. Example: 0 means no unused buying power is required. 0.5 means 50% of the buying power should be left unused. More...
 

Static Public Attributes

static new readonly IReadOnlyDictionary< SecurityType, string > DefaultMarketMap
 The default markets for the fxcm brokerage More...
 
- Static Public Attributes inherited from QuantConnect.Brokerages.DefaultBrokerageModel
static readonly IReadOnlyDictionary< SecurityType, string > DefaultMarketMap
 The default markets for the backtesting brokerage More...
 

Additional Inherited Members

- Static Public Member Functions inherited from QuantConnect.Brokerages.DefaultBrokerageModel
static bool IsValidOrderSize (Security security, decimal orderQuantity, out BrokerageMessageEvent message)
 Checks if the order quantity is valid, it means, the order size is bigger than the minimum size allowed More...
 
- Properties inherited from QuantConnect.Brokerages.DefaultBrokerageModel
virtual AccountType AccountType [get]
 Gets or sets the account type used by this model More...
 
virtual IReadOnlyDictionary< SecurityType, string > DefaultMarkets [get]
 Gets a map of the default markets to be used for each security type More...
 
- Properties inherited from QuantConnect.Brokerages.IBrokerageModel
AccountType AccountType [get]
 Gets the account type used by this model More...
 
decimal RequiredFreeBuyingPowerPercent [get]
 Gets the brokerages model percentage factor used to determine the required unused buying power for the account. From 1 to 0. Example: 0 means no unused buying power is required. 0.5 means 50% of the buying power should be left unused. More...
 
IReadOnlyDictionary< SecurityType, string > DefaultMarkets [get]
 Gets a map of the default markets to be used for each security type More...
 

Detailed Description

Provides FXCM specific properties

Definition at line 30 of file FxcmBrokerageModel.cs.

Constructor & Destructor Documentation

◆ FxcmBrokerageModel()

QuantConnect.Brokerages.FxcmBrokerageModel.FxcmBrokerageModel ( AccountType  accountType = AccountType.Margin)

Initializes a new instance of the DefaultBrokerageModel class

Parameters
accountTypeThe type of account to be modelled, defaults to AccountType.Margin

Definition at line 61 of file FxcmBrokerageModel.cs.

Member Function Documentation

◆ CanSubmitOrder()

override bool QuantConnect.Brokerages.FxcmBrokerageModel.CanSubmitOrder ( Security  security,
Order  order,
out BrokerageMessageEvent  message 
)
virtual

Returns true if the brokerage could accept this order. This takes into account order type, security type, and order size limits.

For example, a brokerage may have no connectivity at certain times, or an order rate/size limit

Parameters
security
orderThe order to be processed
messageIf this function returns false, a brokerage message detailing why the order may not be submitted
Returns
True if the brokerage could process the order, false otherwise

Reimplemented from QuantConnect.Brokerages.DefaultBrokerageModel.

Definition at line 77 of file FxcmBrokerageModel.cs.

Here is the call graph for this function:

◆ CanUpdateOrder()

override bool QuantConnect.Brokerages.FxcmBrokerageModel.CanUpdateOrder ( Security  security,
Order  order,
UpdateOrderRequest  request,
out BrokerageMessageEvent  message 
)
virtual

Returns true if the brokerage would allow updating the order as specified by the request

Parameters
securityThe security of the order
orderThe order to be updated
requestThe requested update to be made to the order
messageIf this function returns false, a brokerage message detailing why the order may not be updated
Returns
True if the brokerage would allow updating the order, false otherwise

Reimplemented from QuantConnect.Brokerages.DefaultBrokerageModel.

Definition at line 141 of file FxcmBrokerageModel.cs.

Here is the call graph for this function:

◆ GetBenchmark()

override IBenchmark QuantConnect.Brokerages.FxcmBrokerageModel.GetBenchmark ( SecurityManager  securities)
virtual

Get the benchmark for this model

Parameters
securitiesSecurityService to create the security with if needed
Returns
The benchmark for this brokerage

Reimplemented from QuantConnect.Brokerages.DefaultBrokerageModel.

Definition at line 170 of file FxcmBrokerageModel.cs.

Here is the call graph for this function:

◆ GetFeeModel()

override IFeeModel QuantConnect.Brokerages.FxcmBrokerageModel.GetFeeModel ( Security  security)
virtual

Gets a new fee model that represents this brokerage's fee structure

Parameters
securityThe security to get a fee model for
Returns
The new fee model for this brokerage

Reimplemented from QuantConnect.Brokerages.DefaultBrokerageModel.

Definition at line 181 of file FxcmBrokerageModel.cs.

◆ GetSettlementModel()

override ISettlementModel QuantConnect.Brokerages.FxcmBrokerageModel.GetSettlementModel ( Security  security)
virtual

Gets a new settlement model for the security

Parameters
securityThe security to get a settlement model for
Returns
The settlement model for this brokerage

Reimplemented from QuantConnect.Brokerages.DefaultBrokerageModel.

Definition at line 191 of file FxcmBrokerageModel.cs.

Member Data Documentation

◆ DefaultMarketMap

new readonly IReadOnlyDictionary<SecurityType, string> QuantConnect.Brokerages.FxcmBrokerageModel.DefaultMarketMap
static
Initial value:
= new Dictionary<SecurityType, string>
{
{SecurityType.Base, Market.USA},
{SecurityType.Equity, Market.USA},
{SecurityType.Option, Market.USA},
{SecurityType.Forex, Market.FXCM},
{SecurityType.Cfd, Market.FXCM}
}.ToReadOnlyDictionary()

The default markets for the fxcm brokerage

Definition at line 35 of file FxcmBrokerageModel.cs.

◆ DefaultMarkets

override IReadOnlyDictionary<SecurityType, string> QuantConnect.Brokerages.FxcmBrokerageModel.DefaultMarkets => DefaultMarketMap

Gets a map of the default markets to be used for each security type

Definition at line 54 of file FxcmBrokerageModel.cs.


The documentation for this class was generated from the following file: