Enum DataType
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classDataType.Companion
-
Enum Constant Summary
Enum Constants Enum Constant Description NONEEmpty data block. Usually used for request frames; code = 0x00
BOOLBoolean typ. 1 for true, 0 for false; code = 0x01
CHAR8Contains a 1byte number; code = 0x02
UCHAR8Contains a 1byte number (unsigned); code = 0x03
INT16Contains a 2byte number; code = 0x04
UINT16Contains a 2byte number; code = 0x05
INT32Contains a 4byte number; code = 0x06
UINT32Contains a 4byte number (unsigned); code = 0x07
INT64Contains a 8byte number; code = 0x08
UINT64Contains a 8byte number (unsigned); code = 0x09
FLOAT32Contains a 4byte floating point number; code = 0x0A
DOUBLE64Contains a 8byte floating point number; code = 0x0B
BITFIELDUnknown, 1byte long. It seems never to be used. According to the name it gives a bit pattern; code = 0x0C
STRINGUTF-8 (I think ...) encoded text; code = 0x0D
CONTAINERA block that contains other blocks; code = 0x0E
TIMESTAMPA timestamp since 01.01.1970 00:00h UTC in seconds and nanoseconds; code = 0x0F
BYTEARRAYBinary data; code = 0x10
ERRORTransmits error codes; code = 0xFF
UNKNOWNNot an official E3DC DataType. Used to represent Unknown types; code = 0xFE
-
Method Summary
Modifier and Type Method Description final BooleanisByteType()Checks if the type is a valid Byte type. final BooleanisShortType()Checks if the type is a valid Short type. final BooleanisIntType()Checks if the type is a valid Int type. final BooleanisLongType()Checks if the type is a valid Long type. final DataTypevalueOf(String value)Returns the enum constant of this type with the specified name. final Array<DataType>values()Returns an array containing the constants of this enum type, in the order they're declared. final BytegetCode()final EnumEntries<DataType>getEntries()Possible data types that can be used in Data objects. -
-
Method Detail
-
isByteType
final Boolean isByteType()
Checks if the type is a valid Byte type.
-
isShortType
final Boolean isShortType()
Checks if the type is a valid Short type.
- Returns:
true if code is INT16, UINT16 or isByteType is true. false otherwise
- Since:
2.0
-
isIntType
final Boolean isIntType()
Checks if the type is a valid Int type.
- Returns:
true if code is INT32, UINT32 or isShortType is true. false otherwise
- Since:
2.0
-
isLongType
final Boolean isLongType()
Checks if the type is a valid Long type.
-
valueOf
final DataType valueOf(String value)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
- Parameters:
value- Code in the data block that identifies the data type
-
values
final Array<DataType> values()
Returns an array containing the constants of this enum type, in the order they're declared.
This method may be used to iterate over the constants.
-
getEntries
final EnumEntries<DataType> getEntries()
Possible data types that can be used in Data objects.
- Since:
2.0
-
-
-
-