PositionSnapshotHolder

StockSharp.Messages

PositionChangeMessage snapshots holder.

Inherits: BaseLogReceiver

Constructors

PositionSnapshotHolder()

Initializes a new instance of the PositionSnapshotHolder.

Methods

GetAllSnapshots() : IEnumerable<PositionChangeMessage>

Get cloned copies of all current position snapshots.

Process(PositionChangeMessage) : PositionChangeMessage

Process PositionChangeMessage change.

posMsg
PositionChangeMessage change.

Returns: Position snapshot copy.

ResetSnapshot(string, SecurityId, string, Sides?, string, string, TPlusLimits?)

Reset snapshot for the specified position key.

portfolioName
Portfolio name. Use to clear all snapshots.
securityId
Security ID.
strategyId
Strategy ID.
side
Side.
clientCode
Client code.
depoName
Depo name.
limitType
Limit type.
TryGetSnapshot(string, SecurityId, string, Sides?, string, string, TPlusLimits?, PositionChangeMessage) : bool

Try get snapshot for the specified position key.

portfolioName
Portfolio name.
securityId
Security ID.
strategyId
Strategy ID.
side
Side.
clientCode
Client code.
depoName
Depo name.
limitType
Limit type.
snapshot
Snapshot if exists, otherwise .

Returns: true if snapshot exists; otherwise false.

TryGetSnapshot(PositionChangeMessage, PositionChangeMessage) : bool

Try get snapshot for the specified position message.

posMsg
Position message to extract key from.
snapshot
Snapshot if exists, otherwise .

Returns: true if snapshot exists; otherwise false.