Positions Class

Represents a collection of Position objects that access market position information for specified symbols, position types, and accounts when using an PositionsProvider component.

The Updated event is called whenever a change occurs in the referenced data.

Namespace: tsdata.trading

Properties

   Additional properties, methods, and events are described in the classes listed under Inheritance Hierarchy (see below).

  Name Type Description
Public property Count int Gets the total number of positions in the current Positions collection.
Public property Position[index] object Gets the Position object associated with the specified index.
Public property Position[symbol,account] object Gets the Position object based on the specified symbol and account.
Public property Position[positionID] object Gets the Position object based on the specified positionID string.
Public property TryPosition[symbol,account] object Gets the Position object, if present, based on the specified symbol and account, otherwise return a null.
Public property TryPosition[positionID] object Gets the Position object, if present, based on the specified positionID string, otherwise return a null.
Methods
  Name Description
Public property Contains(pos) True if the specified position is contained in the collection, otherwise False.
Events
  Name Description
 Public event Updated Occurs whenever any Position in the collection is updated.  See PositionUpdatedEventArgs for the properties returned by the handler's args parameter.
Inheritance Hierarchy

elsystem.Object

tsdata.trading.Positions