RiskTransactionCommissionRule

StockSharp.Algo.Risk

Die Basisklasse für Risikoregeln, Tracking-Provision für eigene Transaktionen.

Erbt von: RiskRule

Eigenschaften

Commission
public decimal Commission { get; set; }
value = riskTransactionCommissionRule.Commission
riskTransactionCommissionRule.Commission = value

Begrenzung der Kommission.

Methoden

GetTitle
protected override string GetTitle()
result = riskTransactionCommissionRule.GetTitle()

Titel holen.

IsMatch
protected abstract bool IsMatch(ExecutionMessage execMsg)
result = riskTransactionCommissionRule.IsMatch(execMsg)

Bestimmen Sie, ob die Provision auf diese Regel anwendbar ist.

execMsg
ExecutionMessage

Rückgabe: Prüfergebnis.

LoadAsync
public override Task LoadAsync(SettingsStorage storage, CancellationToken cancellationToken)
result = riskTransactionCommissionRule.LoadAsync(storage, cancellationToken)

Asynchronously loads the state of the object from the specified SettingsStorage.

storage
The SettingsStorage instance from which to load the data.
cancellationToken
A token to monitor for cancellation requests.

Rückgabe: A task that represents the asynchronous load operation.

ProcessMessage
public override bool ProcessMessage(Message message)
result = riskTransactionCommissionRule.ProcessMessage(message)

Um die Nachricht für die Berechnung der Transaktionsverzögerung zu verarbeiten, werden Nachrichten von OrderRegisterMessage, OrderReplaceMessage, OrderCancelMessage und ExecutionMessage akzeptiert.

message
Nachricht.

Rückgabe: Die Transaktionsverzögerung. Wenn es unmöglich ist, die Verzögerung zu berechnen, wird zurückgegeben.

Reset
public override void Reset()
riskTransactionCommissionRule.Reset()

Zustand zurücksetzen.

SaveAsync
public override Task SaveAsync(SettingsStorage storage, CancellationToken cancellationToken)
result = riskTransactionCommissionRule.SaveAsync(storage, cancellationToken)

Asynchronously saves the state of the object to the specified SettingsStorage.

storage
The SettingsStorage instance to which to save the data.
cancellationToken
A token to monitor for cancellation requests.

Rückgabe: A task that represents the asynchronous save operation.