Class Calendar
java.lang.Object
com.semedy.reasoner.api.symboltable.ExternalDataType
com.semedy.reasoner.symboltable.encoder.Calendar
- All Implemented Interfaces:
Comparable<Object>
- Author:
- juergen
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic longstatic longstatic long -
Constructor Summary
ConstructorsConstructorDescriptionCalendar()Calendar(TemporalAccessor parsedInputObject) Calendar(ZonedDateTime zonedDateTime) -
Method Summary
Modifier and TypeMethodDescriptionintProvide a flexible comparator so that it works in relational builtins.createValue(ByteBuffer buf, int pos) Create an instance from the byte representation.directDecode(long code) Decode the code (if possible)
The encoding of the standard types looks as following:
_direct = 1L << 63; indicates that the code is direct encoded
_shortstring = 1L << 62; bit 62 must not be used for another encoding
_inttype = 2L << 59
_floattype = 3L << 59
_booleantype = 4L << 59longEncode the value of this as a long (if possible) delivers 0 if it is not possiblebyte[]getBytes()Create a byte representation
Used in symbol table to write this byte representation to fileintgetDay()bytegetId()return unique id of external data type (50..100)intgetMonth()Returns a string representation of value.static TemporalAccessorgetTemporalAccessor(String data) longgetValue()return the valueparse value of data type out of StringMethods inherited from class com.semedy.reasoner.api.symboltable.ExternalDataType
equals, getKey, hashCode, toString
-
Field Details
-
_calendarType
public static long _calendarType -
_mask
public static long _mask -
_reasoning
public static long _reasoning
-
-
Constructor Details
-
Calendar
-
Calendar
public Calendar() -
Calendar
-
Calendar
-
Calendar
-
-
Method Details
-
getTemporalAccessor
-
getZonedDateTime
-
getDay
public int getDay() -
getMonth
public int getMonth() -
getId
public byte getId()Description copied from class:ExternalDataTypereturn unique id of external data type (50..100)- Specified by:
getIdin classExternalDataType- Returns:
- unique id of external data type
-
parse
Description copied from class:ExternalDataTypeparse value of data type out of String- Specified by:
parsein classExternalDataType- Returns:
-
getString
Description copied from class:ExternalDataTypeReturns a string representation of value.
This string representation must be parseable by "parse"- Specified by:
getStringin classExternalDataType
-
getValue
Description copied from class:ExternalDataTypereturn the value- Specified by:
getValuein classExternalDataType- Returns:
-
directEncode
Description copied from class:ExternalDataTypeEncode the value of this as a long (if possible) delivers 0 if it is not possible- Specified by:
directEncodein classExternalDataType- Returns:
- Throws:
DatatypeConfigurationException
-
directDecode
Description copied from class:ExternalDataTypeDecode the code (if possible)
The encoding of the standard types looks as following:
_direct = 1L << 63; indicates that the code is direct encoded
_shortstring = 1L << 62; bit 62 must not be used for another encoding
_inttype = 2L << 59
_floattype = 3L << 59
_booleantype = 4L << 59- Specified by:
directDecodein classExternalDataType- Throws:
DatatypeConfigurationException
-
getBytes
public byte[] getBytes()Description copied from class:ExternalDataTypeCreate a byte representation
Used in symbol table to write this byte representation to file- Overrides:
getBytesin classExternalDataType- Returns:
-
createValue
Description copied from class:ExternalDataTypeCreate an instance from the byte representation.
Used in symbol table to recreate the object.- Overrides:
createValuein classExternalDataType- Returns:
- external data type
-
compareTo
Provide a flexible comparator so that it works in relational builtins.- Specified by:
compareToin interfaceComparable<Object>
-
getTimeInMilliSeconds
public long getTimeInMilliSeconds()
-