dxFeed .Net API  5.8.0
dxFeed .Net API library intended to provide market data access for DX clients
Public Member Functions | Static Public Member Functions | Static Public Attributes | Properties | Private Member Functions | Static Private Member Functions | Private Attributes | Static Private Attributes
com.dxfeed.ipf.InstrumentProfileField Class Reference

Defines standard fields of InstrumentProfile and provides data access methods. Please see Instrument Profile Format documentation for complete description. More...

Collaboration diagram for com.dxfeed.ipf.InstrumentProfileField:
[legend]

Public Member Functions

override string ToString ()
 Returns string representation of field. More...
 
string GetField (InstrumentProfile ip)
 Returns value of this field for specified profile in textual representation. More...
 
void SetField (InstrumentProfile ip, string value)
 Sets value of this field (in textual representation) to specified profile. More...
 
Type GetFieldType ()
 Returns type of this field. More...
 
bool IsNumericField ()
 Returns "true" if this field supports numeric representation of a value. More...
 
double GetNumericField (InstrumentProfile ip)
 Returns value of this field for specified profile in numeric representation. More...
 
void SetNumericField (InstrumentProfile ip, double value)
 Sets value of this field (in numeric representation) to specified profile. More...
 

Static Public Member Functions

static InstrumentProfileField Find (string name)
 Returns field for specified name or null if field is not found. More...
 
static string FormatNumber (double d)
 Format number More...
 
static double ParseNumber (string s)
 Parse number from string. More...
 
static string FormatDate (int d)
 Convert unix time to specified date fromat and returns its string representation. More...
 
static int ParseDate (string s)
 Parse date from string. More...
 

Static Public Attributes

static readonly InstrumentProfileField TYPE = new InstrumentProfileField(F_TYPE)
 
static readonly InstrumentProfileField SYMBOL = new InstrumentProfileField(F_SYMBOL)
 
static readonly InstrumentProfileField DESCRIPTION = new InstrumentProfileField(F_DESCRIPTION)
 
static readonly InstrumentProfileField LOCAL_SYMBOL = new InstrumentProfileField(F_LOCAL_SYMBOL)
 
static readonly InstrumentProfileField LOCAL_DESCRIPTION = new InstrumentProfileField(F_LOCAL_DESCRIPTION)
 
static readonly InstrumentProfileField COUNTRY = new InstrumentProfileField(F_COUNTRY)
 
static readonly InstrumentProfileField OPOL = new InstrumentProfileField(F_OPOL)
 
static readonly InstrumentProfileField EXCHANGE_DATA = new InstrumentProfileField(F_EXCHANGE_DATA)
 
static readonly InstrumentProfileField EXCHANGES = new InstrumentProfileField(F_EXCHANGES)
 
static readonly InstrumentProfileField CURRENCY = new InstrumentProfileField(F_CURRENCY)
 
static readonly InstrumentProfileField BASE_CURRENCY = new InstrumentProfileField(F_BASE_CURRENCY)
 
static readonly InstrumentProfileField CFI = new InstrumentProfileField(F_CFI)
 
static readonly InstrumentProfileField ISIN = new InstrumentProfileField(F_ISIN)
 
static readonly InstrumentProfileField SEDOL = new InstrumentProfileField(F_SEDOL)
 
static readonly InstrumentProfileField CUSIP = new InstrumentProfileField(F_CUSIP)
 
static readonly InstrumentProfileField ICB = new InstrumentProfileField(F_ICB)
 
static readonly InstrumentProfileField SIC = new InstrumentProfileField(F_SIC)
 
static readonly InstrumentProfileField MULTIPLIER = new InstrumentProfileField(F_MULTIPLIER)
 
static readonly InstrumentProfileField PRODUCT = new InstrumentProfileField(F_PRODUCT)
 
static readonly InstrumentProfileField UNDERLYING = new InstrumentProfileField(F_UNDERLYING)
 
static readonly InstrumentProfileField SPC = new InstrumentProfileField(F_SPC)
 
static readonly InstrumentProfileField ADDITIONAL_UNDERLYINGS = new InstrumentProfileField(F_ADDITIONAL_UNDERLYINGS)
 
static readonly InstrumentProfileField MMY = new InstrumentProfileField(F_MMY)
 
static readonly InstrumentProfileField EXPIRATION = new InstrumentProfileField(F_EXPIRATION)
 
static readonly InstrumentProfileField LAST_TRADE = new InstrumentProfileField(F_LAST_TRADE)
 
static readonly InstrumentProfileField STRIKE = new InstrumentProfileField(F_STRIKE)
 
static readonly InstrumentProfileField OPTION_TYPE = new InstrumentProfileField(F_OPTION_TYPE)
 
static readonly InstrumentProfileField EXPIRATION_STYLE = new InstrumentProfileField(F_EXPIRATION_STYLE)
 
static readonly InstrumentProfileField SETTLEMENT_STYLE = new InstrumentProfileField(F_SETTLEMENT_STYLE)
 
static readonly InstrumentProfileField PRICE_INCREMENTS = new InstrumentProfileField(F_PRICE_INCREMENTS)
 
static readonly InstrumentProfileField TRADING_HOURS = new InstrumentProfileField(F_TRADING_HOURS)
 

Properties

string Name [get, private set]
 Get name of instrument profile field. More...
 
static InstrumentProfileField [] Values [get]
 Get all default instrument profile fields. More...
 

Private Member Functions

 InstrumentProfileField (string name)
 

Static Private Member Functions

static string FormatNumberImpl (double d)
 Format number implementztion. More...
 
static DateFormat GetDateFormat ()
 Returns date formatter instance. More...
 

Private Attributes

const string F_TYPE = "TYPE"
 
const string F_SYMBOL = "SYMBOL"
 
const string F_DESCRIPTION = "DESCRIPTION"
 
const string F_LOCAL_SYMBOL = "LOCAL_SYMBOL"
 
const string F_LOCAL_DESCRIPTION = "LOCAL_DESCRIPTION"
 
const string F_COUNTRY = "COUNTRY"
 
const string F_OPOL = "OPOL"
 
const string F_EXCHANGE_DATA = "EXCHANGE_DATA"
 
const string F_EXCHANGES = "EXCHANGES"
 
const string F_CURRENCY = "CURRENCY"
 
const string F_BASE_CURRENCY = "BASE_CURRENCY"
 
const string F_CFI = "CFI"
 
const string F_ISIN = "ISIN"
 
const string F_SEDOL = "SEDOL"
 
const string F_CUSIP = "CUSIP"
 
const string F_ICB = "ICB"
 
const string F_SIC = "SIC"
 
const string F_MULTIPLIER = "MULTIPLIER"
 
const string F_PRODUCT = "PRODUCT"
 
const string F_UNDERLYING = "UNDERLYING"
 
const string F_SPC = "SPC"
 
const string F_ADDITIONAL_UNDERLYINGS = "ADDITIONAL_UNDERLYINGS"
 
const string F_MMY = "MMY"
 
const string F_EXPIRATION = "EXPIRATION"
 
const string F_LAST_TRADE = "LAST_TRADE"
 
const string F_STRIKE = "STRIKE"
 
const string F_OPTION_TYPE = "OPTION_TYPE"
 
const string F_EXPIRATION_STYLE = "EXPIRATION_STYLE"
 
const string F_SETTLEMENT_STYLE = "SETTLEMENT_STYLE"
 
const string F_PRICE_INCREMENTS = "PRICE_INCREMENTS"
 
const string F_TRADING_HOURS = "TRADING_HOURS"
 

Static Private Attributes

static Dictionary< string, InstrumentProfileFieldfieldsMap = new Dictionary<string, InstrumentProfileField>()
 
static readonly ThreadLocal< NumberFormatInfo > numberFormatter = new ThreadLocal<NumberFormatInfo>()
 
static readonly ThreadLocal< DateFormatdateFormatter = new ThreadLocal<DateFormat>()
 
static readonly string [] formattedNumbers = new string[20000]
 
static readonly string [] formattedDates = new string[30000]
 
static readonly ConcurrentDictionary< string, double > parsedNumbers = new ConcurrentDictionary<string, double>()
 
static readonly ConcurrentDictionary< string, int > parsedDates = new ConcurrentDictionary<string, int>()
 
static readonly long DAY = 24 * 3600 * 1000
 

Detailed Description

Defines standard fields of InstrumentProfile and provides data access methods. Please see Instrument Profile Format documentation for complete description.

Constructor & Destructor Documentation

◆ InstrumentProfileField()

com.dxfeed.ipf.InstrumentProfileField.InstrumentProfileField ( string  name)
inlineprivate

Member Function Documentation

◆ Find()

static InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.Find ( string  name)
inlinestatic

Returns field for specified name or null if field is not found.

Parameters
nameName of field to find.
Returns
Field for specified name or null if field is not found.
Exceptions
System.ArgumentNullExceptionIf name is null.

◆ FormatDate()

static string com.dxfeed.ipf.InstrumentProfileField.FormatDate ( int  d)
inlinestatic

Convert unix time to specified date fromat and returns its string representation.

Parameters
dDate time in unix time.
Returns
String representation of date tinme.
Exceptions
System.FormatException
System.InvalidOperationExceptionIf number formatter error occurs.

◆ FormatNumber()

static string com.dxfeed.ipf.InstrumentProfileField.FormatNumber ( double  d)
inlinestatic

Format number

Parameters
dThe number to format.
Returns
Strig representation of number in specified format.
Exceptions
System.InvalidOperationExceptionCan't format number.

◆ FormatNumberImpl()

static string com.dxfeed.ipf.InstrumentProfileField.FormatNumberImpl ( double  d)
inlinestaticprivate

Format number implementztion.

Parameters
dNumber to format.
Returns
String representation of number.
Exceptions
System.InvalidOperationExceptionIf number formatter error occurs.

◆ GetDateFormat()

static DateFormat com.dxfeed.ipf.InstrumentProfileField.GetDateFormat ( )
inlinestaticprivate

Returns date formatter instance.

Returns
Date formatter instance.
Exceptions
System.InvalidOperationExceptionIf number formatter error occurs.

◆ GetField()

string com.dxfeed.ipf.InstrumentProfileField.GetField ( InstrumentProfile  ip)
inline

Returns value of this field for specified profile in textual representation.

Parameters
ipProfile fot which get field.
Returns
Value of this field for specified profile in textual representation.
Exceptions
System.InvalidOperationExceptionCan't format certain field.

◆ GetFieldType()

Type com.dxfeed.ipf.InstrumentProfileField.GetFieldType ( )
inline

Returns type of this field.

Returns
Type of this field.

◆ GetNumericField()

double com.dxfeed.ipf.InstrumentProfileField.GetNumericField ( InstrumentProfile  ip)
inline

Returns value of this field for specified profile in numeric representation.

Parameters
ipProfile from get field.
Returns
Value of this field for specified profile in numeric representation.
Exceptions
System.ArgumentExceptionIf this field has no numeric representation.

◆ IsNumericField()

bool com.dxfeed.ipf.InstrumentProfileField.IsNumericField ( )
inline

Returns "true" if this field supports numeric representation of a value.

Returns
"true" if this field supports numeric representation of a value.

◆ ParseDate()

static int com.dxfeed.ipf.InstrumentProfileField.ParseDate ( string  s)
inlinestatic

Parse date from string.

Parameters
sString representation of date.
Returns
Exceptions
System.ArgumentNullException
System.InvalidOperationExceptionIf number formatter error occurs.
System.FormatException

◆ ParseNumber()

static double com.dxfeed.ipf.InstrumentProfileField.ParseNumber ( string  s)
inlinestatic

Parse number from string.

Parameters
sString representation of number.
Returns
Double number.
Exceptions
System.ArgumentNullException
System.FormatException

◆ SetField()

void com.dxfeed.ipf.InstrumentProfileField.SetField ( InstrumentProfile  ip,
string  value 
)
inline

Sets value of this field (in textual representation) to specified profile.

Parameters
ipProfile to set field.
valueValue that set into field.
Exceptions
System.InvalidOperationExceptionIf text uses wrong format or contains invalid values.

◆ SetNumericField()

void com.dxfeed.ipf.InstrumentProfileField.SetNumericField ( InstrumentProfile  ip,
double  value 
)
inline

Sets value of this field (in numeric representation) to specified profile.

Parameters
ipProfile tos set value.
valueValue ehich set to field.
Exceptions
System.ArgumentExceptionIf this field has no numeric representation

◆ ToString()

override string com.dxfeed.ipf.InstrumentProfileField.ToString ( )
inline

Returns string representation of field.

Returns
String representation of field.

Field Documentation

◆ ADDITIONAL_UNDERLYINGS

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.ADDITIONAL_UNDERLYINGS = new InstrumentProfileField(F_ADDITIONAL_UNDERLYINGS)
static

◆ BASE_CURRENCY

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.BASE_CURRENCY = new InstrumentProfileField(F_BASE_CURRENCY)
static

◆ CFI

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.CFI = new InstrumentProfileField(F_CFI)
static

◆ COUNTRY

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.COUNTRY = new InstrumentProfileField(F_COUNTRY)
static

◆ CURRENCY

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.CURRENCY = new InstrumentProfileField(F_CURRENCY)
static

◆ CUSIP

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.CUSIP = new InstrumentProfileField(F_CUSIP)
static

◆ dateFormatter

readonly ThreadLocal<DateFormat> com.dxfeed.ipf.InstrumentProfileField.dateFormatter = new ThreadLocal<DateFormat>()
staticprivate

◆ DAY

readonly long com.dxfeed.ipf.InstrumentProfileField.DAY = 24 * 3600 * 1000
staticprivate

◆ DESCRIPTION

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.DESCRIPTION = new InstrumentProfileField(F_DESCRIPTION)
static

◆ EXCHANGE_DATA

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.EXCHANGE_DATA = new InstrumentProfileField(F_EXCHANGE_DATA)
static

◆ EXCHANGES

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.EXCHANGES = new InstrumentProfileField(F_EXCHANGES)
static

◆ EXPIRATION

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.EXPIRATION = new InstrumentProfileField(F_EXPIRATION)
static

◆ EXPIRATION_STYLE

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.EXPIRATION_STYLE = new InstrumentProfileField(F_EXPIRATION_STYLE)
static

◆ F_ADDITIONAL_UNDERLYINGS

const string com.dxfeed.ipf.InstrumentProfileField.F_ADDITIONAL_UNDERLYINGS = "ADDITIONAL_UNDERLYINGS"
private

◆ F_BASE_CURRENCY

const string com.dxfeed.ipf.InstrumentProfileField.F_BASE_CURRENCY = "BASE_CURRENCY"
private

◆ F_CFI

const string com.dxfeed.ipf.InstrumentProfileField.F_CFI = "CFI"
private

◆ F_COUNTRY

const string com.dxfeed.ipf.InstrumentProfileField.F_COUNTRY = "COUNTRY"
private

◆ F_CURRENCY

const string com.dxfeed.ipf.InstrumentProfileField.F_CURRENCY = "CURRENCY"
private

◆ F_CUSIP

const string com.dxfeed.ipf.InstrumentProfileField.F_CUSIP = "CUSIP"
private

◆ F_DESCRIPTION

const string com.dxfeed.ipf.InstrumentProfileField.F_DESCRIPTION = "DESCRIPTION"
private

◆ F_EXCHANGE_DATA

const string com.dxfeed.ipf.InstrumentProfileField.F_EXCHANGE_DATA = "EXCHANGE_DATA"
private

◆ F_EXCHANGES

const string com.dxfeed.ipf.InstrumentProfileField.F_EXCHANGES = "EXCHANGES"
private

◆ F_EXPIRATION

const string com.dxfeed.ipf.InstrumentProfileField.F_EXPIRATION = "EXPIRATION"
private

◆ F_EXPIRATION_STYLE

const string com.dxfeed.ipf.InstrumentProfileField.F_EXPIRATION_STYLE = "EXPIRATION_STYLE"
private

◆ F_ICB

const string com.dxfeed.ipf.InstrumentProfileField.F_ICB = "ICB"
private

◆ F_ISIN

const string com.dxfeed.ipf.InstrumentProfileField.F_ISIN = "ISIN"
private

◆ F_LAST_TRADE

const string com.dxfeed.ipf.InstrumentProfileField.F_LAST_TRADE = "LAST_TRADE"
private

◆ F_LOCAL_DESCRIPTION

const string com.dxfeed.ipf.InstrumentProfileField.F_LOCAL_DESCRIPTION = "LOCAL_DESCRIPTION"
private

◆ F_LOCAL_SYMBOL

const string com.dxfeed.ipf.InstrumentProfileField.F_LOCAL_SYMBOL = "LOCAL_SYMBOL"
private

◆ F_MMY

const string com.dxfeed.ipf.InstrumentProfileField.F_MMY = "MMY"
private

◆ F_MULTIPLIER

const string com.dxfeed.ipf.InstrumentProfileField.F_MULTIPLIER = "MULTIPLIER"
private

◆ F_OPOL

const string com.dxfeed.ipf.InstrumentProfileField.F_OPOL = "OPOL"
private

◆ F_OPTION_TYPE

const string com.dxfeed.ipf.InstrumentProfileField.F_OPTION_TYPE = "OPTION_TYPE"
private

◆ F_PRICE_INCREMENTS

const string com.dxfeed.ipf.InstrumentProfileField.F_PRICE_INCREMENTS = "PRICE_INCREMENTS"
private

◆ F_PRODUCT

const string com.dxfeed.ipf.InstrumentProfileField.F_PRODUCT = "PRODUCT"
private

◆ F_SEDOL

const string com.dxfeed.ipf.InstrumentProfileField.F_SEDOL = "SEDOL"
private

◆ F_SETTLEMENT_STYLE

const string com.dxfeed.ipf.InstrumentProfileField.F_SETTLEMENT_STYLE = "SETTLEMENT_STYLE"
private

◆ F_SIC

const string com.dxfeed.ipf.InstrumentProfileField.F_SIC = "SIC"
private

◆ F_SPC

const string com.dxfeed.ipf.InstrumentProfileField.F_SPC = "SPC"
private

◆ F_STRIKE

const string com.dxfeed.ipf.InstrumentProfileField.F_STRIKE = "STRIKE"
private

◆ F_SYMBOL

const string com.dxfeed.ipf.InstrumentProfileField.F_SYMBOL = "SYMBOL"
private

◆ F_TRADING_HOURS

const string com.dxfeed.ipf.InstrumentProfileField.F_TRADING_HOURS = "TRADING_HOURS"
private

◆ F_TYPE

const string com.dxfeed.ipf.InstrumentProfileField.F_TYPE = "TYPE"
private

◆ F_UNDERLYING

const string com.dxfeed.ipf.InstrumentProfileField.F_UNDERLYING = "UNDERLYING"
private

◆ fieldsMap

Dictionary<string, InstrumentProfileField> com.dxfeed.ipf.InstrumentProfileField.fieldsMap = new Dictionary<string, InstrumentProfileField>()
staticprivate

◆ formattedDates

readonly string [] com.dxfeed.ipf.InstrumentProfileField.formattedDates = new string[30000]
staticprivate

◆ formattedNumbers

readonly string [] com.dxfeed.ipf.InstrumentProfileField.formattedNumbers = new string[20000]
staticprivate

◆ ICB

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.ICB = new InstrumentProfileField(F_ICB)
static

◆ ISIN

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.ISIN = new InstrumentProfileField(F_ISIN)
static

◆ LAST_TRADE

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.LAST_TRADE = new InstrumentProfileField(F_LAST_TRADE)
static

◆ LOCAL_DESCRIPTION

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.LOCAL_DESCRIPTION = new InstrumentProfileField(F_LOCAL_DESCRIPTION)
static

◆ LOCAL_SYMBOL

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.LOCAL_SYMBOL = new InstrumentProfileField(F_LOCAL_SYMBOL)
static

◆ MMY

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.MMY = new InstrumentProfileField(F_MMY)
static

◆ MULTIPLIER

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.MULTIPLIER = new InstrumentProfileField(F_MULTIPLIER)
static

◆ numberFormatter

readonly ThreadLocal<NumberFormatInfo> com.dxfeed.ipf.InstrumentProfileField.numberFormatter = new ThreadLocal<NumberFormatInfo>()
staticprivate

◆ OPOL

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.OPOL = new InstrumentProfileField(F_OPOL)
static

◆ OPTION_TYPE

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.OPTION_TYPE = new InstrumentProfileField(F_OPTION_TYPE)
static

◆ parsedDates

readonly ConcurrentDictionary<string, int> com.dxfeed.ipf.InstrumentProfileField.parsedDates = new ConcurrentDictionary<string, int>()
staticprivate

◆ parsedNumbers

readonly ConcurrentDictionary<string, double> com.dxfeed.ipf.InstrumentProfileField.parsedNumbers = new ConcurrentDictionary<string, double>()
staticprivate

◆ PRICE_INCREMENTS

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.PRICE_INCREMENTS = new InstrumentProfileField(F_PRICE_INCREMENTS)
static

◆ PRODUCT

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.PRODUCT = new InstrumentProfileField(F_PRODUCT)
static

◆ SEDOL

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.SEDOL = new InstrumentProfileField(F_SEDOL)
static

◆ SETTLEMENT_STYLE

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.SETTLEMENT_STYLE = new InstrumentProfileField(F_SETTLEMENT_STYLE)
static

◆ SIC

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.SIC = new InstrumentProfileField(F_SIC)
static

◆ SPC

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.SPC = new InstrumentProfileField(F_SPC)
static

◆ STRIKE

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.STRIKE = new InstrumentProfileField(F_STRIKE)
static

◆ SYMBOL

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.SYMBOL = new InstrumentProfileField(F_SYMBOL)
static

◆ TRADING_HOURS

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.TRADING_HOURS = new InstrumentProfileField(F_TRADING_HOURS)
static

◆ TYPE

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.TYPE = new InstrumentProfileField(F_TYPE)
static

◆ UNDERLYING

readonly InstrumentProfileField com.dxfeed.ipf.InstrumentProfileField.UNDERLYING = new InstrumentProfileField(F_UNDERLYING)
static

Property Documentation

◆ Name

string com.dxfeed.ipf.InstrumentProfileField.Name
getprivate set

Get name of instrument profile field.

◆ Values

InstrumentProfileField [] com.dxfeed.ipf.InstrumentProfileField.Values
staticget

Get all default instrument profile fields.


The documentation for this class was generated from the following file: