MasterInstrument

<< Click to Display Table of Contents >>

Navigation:  NinjaScript > Language Reference > Common > Instruments > Instrument >

MasterInstrument

Previous page Return to chapter overview Next page

Definition

An instrument's configuration settings.  These are settings and properties which are defined in the Instrument window.

 

Warning:  The properties in this class should NOT be accessed within the OnStateChange() method before the State has reached State.DataLoaded.

 

 

Methods and Properties

Compare()

Returns an int value compares two price values with respect to the Instrument tick size

Currency

The currency that the instrument traded in

Description

A  written representation of a given instrument

Dividends

A collection of dividends for stock instruments

Exchanges

A collection of exchanges configured for an instrument

FormatPrice()

Returns a string representing the price formatted to the nearest tick size

InstrumentType

The type of instrument

MergePolicy

The Merge Policy that is configured for the current master instrument.

Name

The name of the instrument.

GetNextExpiry()

Returns a DateTime structure representing the next futures expiry for a given date

PointValue

Currency value of 1 full point of movement

RolloverCollection

A collection of expiration dates and offsets for futures instruments

RoundToTickSize()

Rounds the value up to the nearest valid value

RoundDownToTickSize()

Rounds the value down to the nearest valid value

Splits

A collection of splits for stock instruments

TickSize

The smallest movement in price configured

Url

A web url where contract details have been collected