Package com.storedobject.chart
Class SerialDate
java.lang.Object
com.storedobject.chart.SerialDate
- All Implemented Interfaces:
AbstractDataProvider<LocalDate>,ComponentPart,ComponentProperty
Implementation of serially increasing/decreasing date values as data.
- Author:
- Syam
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.storedobject.chart.AbstractDataProvider
AbstractDataProvider.NumberComparator -
Constructor Summary
ConstructorsConstructorDescriptionSerialDate(LocalDate start, LocalDate end) Constructor.SerialDate(LocalDate start, LocalDate end, int step) Constructor.SerialDate(LocalDate start, LocalDate end, int step, ChronoUnit stepUnit) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionfinal DataTypeGet the value type of the data.final intGet the current serial number (Serial number used for internal purposes only).final voidsetSerial(int serial) Set a serial number (Serial number used for internal purposes only).stream()Data provided by this provider as a stream.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.storedobject.chart.AbstractDataProvider
asList, create, create, encode, encodeJSON, getComparator, getId, getMax, getMin, getName, validateMethods inherited from interface com.storedobject.chart.ComponentPart
className, getRenderingIndex, setName, setRenderingIndex
-
Constructor Details
-
SerialDate
-
SerialDate
-
SerialDate
Constructor.- Parameters:
start- Starting value.end- Ending value.step- Step value.stepUnit- Unit of the step.
-
-
Method Details
-
stream
Description copied from interface:AbstractDataProviderData provided by this provider as a stream.Note: The
Streamshould be reproducible after a terminal operation.- Specified by:
streamin interfaceAbstractDataProvider<LocalDate>- Returns:
- Stream of data values.
-
getDataType
Description copied from interface:AbstractDataProviderGet the value type of the data.- Specified by:
getDataTypein interfaceAbstractDataProvider<LocalDate>- Returns:
- Value type.
-
setSerial
public final void setSerial(int serial) Description copied from interface:ComponentPartSet a serial number (Serial number used for internal purposes only). The implementation of this method must be in such a way that the serial number set here must be returned by theComponentPart.getSerial()method.- Specified by:
setSerialin interfaceComponentPart- Parameters:
serial- Serial number to set.
-
getSerial
public final int getSerial()Description copied from interface:ComponentPartGet the current serial number (Serial number used for internal purposes only). The serial number set by theComponentPart.setSerial(int)method should be returned by this method.- Specified by:
getSerialin interfaceComponentPart- Returns:
- Current serial number.
-