public class CandleExchange extends Object implements CandleSymbolAttribute<CandleExchange>, Serializable
CandleSymbol defines exchange identifier where data is
taken from to build the candles.
MarketEventSymbols.getExchangeCode and
changeExchangeCode methods.| Modifier and Type | Field and Description |
|---|---|
static CandleExchange |
COMPOSITE
Composite exchange where data is taken from all exchanges.
|
static CandleExchange |
DEFAULT
Default exchange is
COMPOSITE. |
| Modifier and Type | Method and Description |
|---|---|
String |
changeAttributeForSymbol(String symbol)
Returns candle event symbol string with this exchange set.
|
void |
checkInAttributeImpl(CandleSymbol candleSymbol)
Internal method that initializes attribute in the candle symbol.
|
boolean |
equals(Object o)
Indicates whether this exchange attribute is the same as another one.
|
static CandleExchange |
getAttributeForSymbol(String symbol)
Returns exchange attribute object of the given candle symbol string.
|
char |
getExchangeCode()
Returns exchange code.
|
int |
hashCode()
Returns hash code of this exchange attribute.
|
protected Object |
readResolve() |
String |
toString()
Returns string representation of this exchange.
|
static CandleExchange |
valueOf(char exchangeCode)
Returns exchange attribute object that corresponds to the specified exchange code character.
|
public static final CandleExchange COMPOSITE
public static final CandleExchange DEFAULT
COMPOSITE.public char getExchangeCode()
'\0' for COMPOSITE exchange.public String toString()
"COMPOSITE" for COMPOSITE exchange or
exchange character otherwise.public boolean equals(Object o)
public int hashCode()
public String changeAttributeForSymbol(String symbol)
changeAttributeForSymbol in interface CandleSymbolAttribute<CandleExchange>symbol - original candle event symbol.public void checkInAttributeImpl(CandleSymbol candleSymbol)
checkInAttributeImpl in interface CandleSymbolAttribute<CandleExchange>candleSymbol - candle symbol.IllegalStateException - if used outside of internal initialization logic.public static CandleExchange valueOf(char exchangeCode)
exchangeCode - exchange code character.public static CandleExchange getAttributeForSymbol(String symbol)
DEFAULT if the symbol does not have exchange attribute.symbol - candle symbol string.protected Object readResolve() throws ObjectStreamException
ObjectStreamExceptionCopyright © 2002–2023 Devexperts LLC. All rights reserved.