Class PositionFinancialDataSet
- java.lang.Object
-
- de.gsi.dataset.spi.AbstractStylable<D>
-
- de.gsi.dataset.spi.AbstractDataSet<PositionFinancialDataSet>
-
- de.gsi.financial.samples.service.order.PositionFinancialDataSet
-
- All Implemented Interfaces:
de.gsi.chart.renderer.spi.financial.PositionFinancialRendererPaintAfterEP.PositionRenderedAware,de.gsi.dataset.DataSet,de.gsi.dataset.DataSetMetaData,de.gsi.dataset.event.EventSource,ExecutionPlatformListener,java.io.Serializable,java.util.EventListener
public class PositionFinancialDataSet extends de.gsi.dataset.spi.AbstractDataSet<PositionFinancialDataSet> implements ExecutionPlatformListener, de.gsi.chart.renderer.spi.financial.PositionFinancialRendererPaintAfterEP.PositionRenderedAware
Example of Trading Position DataSet. Depended on the Trading Platform Position / Order Domain Objects.
The example includes:
- merging positions for same entry or exit time, and
- mapping position domain object to renderer required domain object PositionRendered, and
- full example of the position listener mechanism.
- Author:
- afischer
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description PositionFinancialDataSet(java.lang.String instrument, de.gsi.dataset.spi.financial.OhlcvDataSet ohlcvDataSet, de.gsi.dataset.spi.financial.api.attrs.AttributeModel context)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description doubleget(int dimIndex, int index)intgetDataCount()de.gsi.chart.renderer.spi.financial.PositionFinancialRendererPaintAfterEP.PositionRenderedgetPositionByTime(long corr)voidorderCancelled(OrderEvent event)The order was cancelledvoidorderFilled(OrderEvent event)The order was filledde.gsi.dataset.DataSetset(de.gsi.dataset.DataSet other, boolean copy)-
Methods inherited from class de.gsi.dataset.spi.AbstractDataSet
addDataLabel, addDataStyle, autoNotification, binarySearch, binarySearch, clearMetaInfo, copyAxisDescription, copyDataLabelsAndStyles, copyMetaData, equalDataLabels, equalEditConstraints, equalErrorValues, equalMetaData, equals, equals, equalValues, fireInvalidated, getAxisDescriptions, getDataLabel, getDataLabelMap, getDataStyleMap, getDimension, getEditConstraints, getErrorList, getIndex, getInfoList, getMetaInfo, getName, getStyle, getThis, getValue, getValues, getWarningList, hashCode, isVisible, lock, recomputeLimits, removeDataLabel, removeStyle, setEditConstraints, setName, setVisible, toString, updateEventListener
-
-
-
-
Method Detail
-
getPositionByTime
public de.gsi.chart.renderer.spi.financial.PositionFinancialRendererPaintAfterEP.PositionRendered getPositionByTime(long corr)
- Specified by:
getPositionByTimein interfacede.gsi.chart.renderer.spi.financial.PositionFinancialRendererPaintAfterEP.PositionRenderedAware
-
get
public double get(int dimIndex, int index)- Specified by:
getin interfacede.gsi.dataset.DataSet
-
getDataCount
public int getDataCount()
- Specified by:
getDataCountin interfacede.gsi.dataset.DataSet
-
set
public de.gsi.dataset.DataSet set(de.gsi.dataset.DataSet other, boolean copy)- Specified by:
setin interfacede.gsi.dataset.DataSet
-
orderFilled
public void orderFilled(OrderEvent event)
Description copied from interface:ExecutionPlatformListenerThe order was filled- Specified by:
orderFilledin interfaceExecutionPlatformListener- Parameters:
event- OrderEvent
-
orderCancelled
public void orderCancelled(OrderEvent event)
Description copied from interface:ExecutionPlatformListenerThe order was cancelled- Specified by:
orderCancelledin interfaceExecutionPlatformListener- Parameters:
event- OrderEvent
-
-