Order position group: hedged/netting side and lifecycle flags.

Constructors

Properties

Accessors

Methods

Constructors

  • Constructs an empty position group (reduceOnly/closePosition false).

    Returns OrderPosition

Properties

closePosition: boolean

Whether the order closes the entire position.

reduceOnly: boolean

Whether the order may only reduce an existing position.

Accessors

  • get positionSide(): undefined | string
  • The position side wire string ("LONG"/"SHORT"), or undefined.

    Returns undefined | string

  • set positionSide(value): void
  • Sets the position side from its wire string.

    Errors

    Throws ParamError when value is not "LONG"/"SHORT".

    Parameters

    • value:
          | undefined
          | null
          | "LONG"
          | "SHORT"

    Returns void

Methods

  • Returns void

  • Returns a deep copy of this position group.

    Returns OrderPosition

  • Returns void