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 | Package Attributes | Properties | Private Member Functions | Static Private Member Functions | Private Attributes
com.dxfeed.api.candle.CandleSymbol Class Reference

Symbol that should be used with DXFeedSubscription class to subscribe for IDxCandle events. DXFeedSubscription also accepts a string representation of the candle symbol for subscription. More...

Collaboration diagram for com.dxfeed.api.candle.CandleSymbol:
[legend]

Public Member Functions

override string ToString ()
 Returns string representation of this symbol. The string representation can be transformed back into symbol object using ValueOf(string) method. More...
 
override bool Equals (object obj)
 Indicates whether this symbol is the same as another one. More...
 
override int GetHashCode ()
 Returns hash code of this symbol. More...
 
string ToFullString ()
 Returns full string representation of this symbol. In this case default attributes are not ignored. More...
 
bool IsDefault ()
 Checks this candle symbol have all default attributes. More...
 

Static Public Member Functions

static CandleSymbol ValueOf (string symbol)
 Converts the given string symbol into the candle symbol object. More...
 
static CandleSymbol ValueOf (string symbol, ICandleSymbolAttribute attribute)
 Converts the given string symbol into the candle symbol object with the specified attribute set. More...
 
static CandleSymbol ValueOf (string symbol, ICandleSymbolAttribute attribute, params ICandleSymbolAttribute[] attributes)
 Converts the given string symbol into the candle symbol object with the specified attributes set. More...
 

Package Attributes

CandleExchange exchange
 
CandlePrice price
 
CandleSession session
 
CandlePeriod period
 
CandleAlignment alignment
 

Properties

string BaseSymbol [get]
 Returns base market symbol without attributes. More...
 
char ExchangeCode [get]
 Returns exchange attribute of this symbol. More...
 
int PriceId [get]
 Returns price type attribute of this symbol. More...
 
int SessionId [get]
 Returns session attribute of this symbol. More...
 
int PeriodId [get]
 Returns aggregation period of this symbol. More...
 
double PeriodValue [get]
 Returns aggregation period value of this symbol. More...
 
int AlignmentId [get]
 Returns alignment attribute of this symbol. More...
 

Private Member Functions

 CandleSymbol (string symbol)
 
 CandleSymbol (string symbol, ICandleSymbolAttribute attribute)
 
 CandleSymbol (string symbol, ICandleSymbolAttribute attribute, params ICandleSymbolAttribute[] attributes)
 
void InitTransientFields ()
 
void ReadObject (StreamingContext context)
 

Static Private Member Functions

static string ChangeAttributes (string symbol, ICandleSymbolAttribute attribute, params ICandleSymbolAttribute[] attributes)
 
static string ChangeAttribute (string symbol, ICandleSymbolAttribute attribute)
 
static string Normalize (string symbol)
 

Private Attributes

readonly string symbol
 
string baseSymbol
 

Detailed Description

Symbol that should be used with DXFeedSubscription class to subscribe for IDxCandle events. DXFeedSubscription also accepts a string representation of the candle symbol for subscription.

String representation

The string representation of the candle symbol consist of a baseSymbol followed by an optional '&' with an exchange code letter and followed by a list of comma-separated key=value pairs in curly braces:

<baseSymbol> [ '&' <exchange> ] '{' <key1>=<value1> [ ',' <key2>=<value2> [ ',' ... ]] '}'

Properties of the candle symbol correspond to the keys in the string representation in the following way:

Keys in the candle symbol are case-sensitive, while values are not. The ValueOf(string) method parses any valid string representation into a candle symbol object. The result of the candle symbol ToString() method is always normalized: keys are ordered lexicographically, values are in lower-case and are abbreviated to their shortest possible form.

Constructor & Destructor Documentation

◆ CandleSymbol() [1/3]

com.dxfeed.api.candle.CandleSymbol.CandleSymbol ( string  symbol)
inlineprivate

◆ CandleSymbol() [2/3]

com.dxfeed.api.candle.CandleSymbol.CandleSymbol ( string  symbol,
ICandleSymbolAttribute  attribute 
)
inlineprivate

◆ CandleSymbol() [3/3]

com.dxfeed.api.candle.CandleSymbol.CandleSymbol ( string  symbol,
ICandleSymbolAttribute  attribute,
params ICandleSymbolAttribute []  attributes 
)
inlineprivate

Member Function Documentation

◆ ChangeAttribute()

static string com.dxfeed.api.candle.CandleSymbol.ChangeAttribute ( string  symbol,
ICandleSymbolAttribute  attribute 
)
inlinestaticprivate

◆ ChangeAttributes()

static string com.dxfeed.api.candle.CandleSymbol.ChangeAttributes ( string  symbol,
ICandleSymbolAttribute  attribute,
params ICandleSymbolAttribute []  attributes 
)
inlinestaticprivate

◆ Equals()

override bool com.dxfeed.api.candle.CandleSymbol.Equals ( object  obj)
inline

Indicates whether this symbol is the same as another one.

Parameters
obj
Returns
true if this symbol is the same as another one.

◆ GetHashCode()

override int com.dxfeed.api.candle.CandleSymbol.GetHashCode ( )
inline

Returns hash code of this symbol.

Returns
hash code of this symbol.

◆ InitTransientFields()

void com.dxfeed.api.candle.CandleSymbol.InitTransientFields ( )
inlineprivate

◆ IsDefault()

bool com.dxfeed.api.candle.CandleSymbol.IsDefault ( )
inline

Checks this candle symbol have all default attributes.

Returns
"true" if all attributes is default, otherwise returns false.

◆ Normalize()

static string com.dxfeed.api.candle.CandleSymbol.Normalize ( string  symbol)
inlinestaticprivate

◆ ReadObject()

void com.dxfeed.api.candle.CandleSymbol.ReadObject ( StreamingContext  context)
inlineprivate

◆ ToFullString()

string com.dxfeed.api.candle.CandleSymbol.ToFullString ( )
inline

Returns full string representation of this symbol. In this case default attributes are not ignored.

Returns
String representation of this symbol.

◆ ToString()

override string com.dxfeed.api.candle.CandleSymbol.ToString ( )
inline

Returns string representation of this symbol. The string representation can be transformed back into symbol object using ValueOf(string) method.

Returns
string representation of this symbol.

◆ ValueOf() [1/3]

static CandleSymbol com.dxfeed.api.candle.CandleSymbol.ValueOf ( string  symbol)
inlinestatic

Converts the given string symbol into the candle symbol object.

Parameters
symbolthe string symbol.
Returns
the candle symbol object.

◆ ValueOf() [2/3]

static CandleSymbol com.dxfeed.api.candle.CandleSymbol.ValueOf ( string  symbol,
ICandleSymbolAttribute  attribute 
)
inlinestatic

Converts the given string symbol into the candle symbol object with the specified attribute set.

Parameters
symbolthe string symbol.
attributethe attribute to set.
Returns
the candle symbol object.

◆ ValueOf() [3/3]

static CandleSymbol com.dxfeed.api.candle.CandleSymbol.ValueOf ( string  symbol,
ICandleSymbolAttribute  attribute,
params ICandleSymbolAttribute []  attributes 
)
inlinestatic

Converts the given string symbol into the candle symbol object with the specified attributes set.

Parameters
symbolthe string symbol.
attributethe attribute to set.
attributesmore attributes to set.
Returns
the candle symbol object.

Field Documentation

◆ alignment

CandleAlignment com.dxfeed.api.candle.CandleSymbol.alignment
package

◆ baseSymbol

string com.dxfeed.api.candle.CandleSymbol.baseSymbol
private

◆ exchange

CandleExchange com.dxfeed.api.candle.CandleSymbol.exchange
package

◆ period

CandlePeriod com.dxfeed.api.candle.CandleSymbol.period
package

◆ price

CandlePrice com.dxfeed.api.candle.CandleSymbol.price
package

◆ session

CandleSession com.dxfeed.api.candle.CandleSymbol.session
package

◆ symbol

readonly string com.dxfeed.api.candle.CandleSymbol.symbol
private

Property Documentation

◆ AlignmentId

int com.dxfeed.api.candle.CandleSymbol.AlignmentId
get

Returns alignment attribute of this symbol.

◆ BaseSymbol

string com.dxfeed.api.candle.CandleSymbol.BaseSymbol
get

Returns base market symbol without attributes.

◆ ExchangeCode

char com.dxfeed.api.candle.CandleSymbol.ExchangeCode
get

Returns exchange attribute of this symbol.

◆ PeriodId

int com.dxfeed.api.candle.CandleSymbol.PeriodId
get

Returns aggregation period of this symbol.

◆ PeriodValue

double com.dxfeed.api.candle.CandleSymbol.PeriodValue
get

Returns aggregation period value of this symbol.

◆ PriceId

int com.dxfeed.api.candle.CandleSymbol.PriceId
get

Returns price type attribute of this symbol.

◆ SessionId

int com.dxfeed.api.candle.CandleSymbol.SessionId
get

Returns session attribute of this symbol.


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