Difference between revisions of "Extensions.DiagDataBrowsingPlus.McdDataType"

From emotive
Jump to navigation Jump to search
Line 42: Line 42:
 
|- {{TableRow1}}
 
|- {{TableRow1}}
 
| '''eA_UINT64''' ||  @McdDataType:UINT64 || Data type is MCDDataType::eA_UINT64 (simple data type).
 
| '''eA_UINT64''' ||  @McdDataType:UINT64 || Data type is MCDDataType::eA_UINT64 (simple data type).
|- {{TableRow2}}
 
| '''eA_UINT8''' || @McdDataType:UINT8 || Data type is MCDDataType::eA_UINT8 (simple data type).
 
|- {{TableRow1}}
 
| '''eA_UNICODE2STRING''' ||  @McdDataType:UNICODE2STRING || Data type is MCDDataType::eA_UNICODE2STRING (simple data type).
 
 
|- {{TableRow2}}
 
|- {{TableRow2}}
 
| '''eA_UINT8''' || @McdDataType:UINT8 || Data type is MCDDataType::eA_UINT8 (simple data type).
 
| '''eA_UINT8''' || @McdDataType:UINT8 || Data type is MCDDataType::eA_UINT8 (simple data type).
Line 80: Line 76:
 
|}
 
|}
  
 +
==Literal==
 +
The syntax for [[Literals| Literals for complex data types]] should be used, where the '''member value''' is one of the values in the list.
 +
 +
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
 +
@@McdDataType:{ASCIISTRING|BITFIELD|BOOLEAN|BYTEFIELD|FLOAT32|FLOAT64|INT16|INT32|UINT64|INT8|UINT16|UINT32|UINT64|UINT8|UNICODE2STRING|DTC|END_OF_PDU|ENVDATA|ENVDATADESC|FIELD|KEY|LENGTHKEY|MULTIPLEXER|NO_TYPE|STRUCT_FIELD|STRUCTURE|TABLE|TABLE_ROW|TEXTTABLE}
 +
</syntaxhighlight>
  
 
{{ConversionTable |
 
{{ConversionTable |
Line 85: Line 87:
 
String=Returns the name of the enumeration value. | StringSample=<tt>String s = ToString(McdDataTypeVariable); // Returns the name of the enumeration value.
 
String=Returns the name of the enumeration value. | StringSample=<tt>String s = ToString(McdDataTypeVariable); // Returns the name of the enumeration value.
 
}}
 
}}
 +
 +
==Sample==
 +
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
 +
DiagDataBrowsingPlus.McdDataType McdDataTypeVariable1 = @McdDataType:ASCIISTRING;
 +
</syntaxhighlight>

Revision as of 09:46, 19 October 2018

Classification

Name McdDataType
Short Description is an enumeration type
Class Simple Data Type
Base Data Type SimpleType
Default Value eA_ASCIISTRING
Provide a Literal Yes
SpecifiedBy ISO 13209-3
Standard Compliant Yes

Description

McdDataType is an enumeration type describing the ASAM data types used by the MVCI/ODX system.

Its members have the following semantics:

  • <init> : diagDataPlus:McdDataTypeLiteral[0..1]

This optional element stands for the hard-coded initialisation value of the identifier at declaration time.

McdDataTypes has the following enumeration values:

Value Literal Description
eA_ASCIISTRING @McdDataType:ASCIISTRING Data type is MCDDataType::eA_ASCIISTRING (simple data type).
eA_BITFIELD @McdDataType:BITFIELD Data type is MCDDataType::eA_BITFIELD (simple data type).
eA_BOOLEAN @McdDataType:BOOLEAN Data type is MCDDataType::eA_BOOLEAN (simple data type).
eA_BYTEFIELD @McdDataType:BYTEFIELD Data type is MCDDataType::eA_BYTEFIELD (simple data type).
eA_FLOAT32 @McdDataType:FLOAT32 Data type is MCDDataType::eA_FLOAT32 (simple data type).
eA_FLOAT64 @McdDataType:FLOAT64 Data type is MCDDataType::eA_FLOAT64 (simple data type).
eA_INT16 @McdDataType:INT16 Data type is MCDDataType::eA_INT16 (simple data type).
eA_INT32 @McdDataType:INT32 Data type is MCDDataType::eA_INT32 (simple data type).
eA_INT64 @McdDataType:INT64 Data type is MCDDataType::eA_INT64 (simple data type).
eA_INT8 @McdDataType:INT8 Data type is MCDDataType::eA_INT8 (simple data type).
eA_UINT16 @McdDataType:UINT16 Data type is MCDDataType::eA_UINT16 (simple data type).
eA_UINT32 @McdDataType:UINT32 Data type is MCDDataType::eA_UINT32 (simple data type).
eA_UINT64 @McdDataType:UINT64 Data type is MCDDataType::eA_UINT64 (simple data type).
eA_UINT8 @McdDataType:UINT8 Data type is MCDDataType::eA_UINT8 (simple data type).
eA_UNICODE2STRING @McdDataType:UNICODE2STRING Data type is MCDDataType::eA_UNICODE2STRING (simple data type).
eDTC @McdDataType:DTC Data type is MCDDataType::eDTC (simple data type).
eEND_OF_PDU @McdDataType:END_OF_PDU Data type is MCDDataType::eeEND_OF_PDU (complex data type).
eENVDATA @McdDataType:ENVDATA Data type is MCDDataType::eENVDATA (complex data type).
eENVDATADESC @McdDataType:ENVDATADESC Data type is MCDDataType::eENVDATADESC (complex data type).
eFIELD @McdDataType:FIELD Data type is MCDDataType::eFIELD (complex data type).
eKEY @McdDataType:KEY Data type is MCDDataType::eKEY (simple data type).
eLENGTHKEY @McdDataType:LENGTHKEY Data type is MCDDataType::eLENGTHKEY (simple data type) which is only allowed in request.
eMULTIPLEXER @McdDataType:MULTIPLEXER Data type is MCDDataType::eMULTIPLEXER (complex data type).
eNO_TYPE @McdDataType:NO_TYPE No explicit data type.
eSTRUCT_FIELD @McdDataType:STRUCT_FIELD Data type is MCDDataType::eSTRUCT_FIELD (complex data type) can only used inside complex Com Params.
eSTRUCTURE @McdDataType:STRUCTURE Data type is MCDDataType::eSTRUCTURE (complex data type).
eTABLE @McdDataType:TABLE Data type is MCDDataType::eTable (complex data type).
eTABLE_ROW @McdDataType:TABLE_ROW Data type is MCDDataType::eTABLE-ROW (complex data type).
eTEXTTABLE @McdDataType:TEXTTABLE Data type is MCDDataType::eTEXTTABLE (simple data type).

Literal

The syntax for Literals for complex data types should be used, where the member value is one of the values in the list.

@@McdDataType:{ASCIISTRING|BITFIELD|BOOLEAN|BYTEFIELD|FLOAT32|FLOAT64|INT16|INT32|UINT64|INT8|UINT16|UINT32|UINT64|UINT8|UNICODE2STRING|DTC|END_OF_PDU|ENVDATA|ENVDATADESC|FIELD|KEY|LENGTHKEY|MULTIPLEXER|NO_TYPE|STRUCT_FIELD|STRUCTURE|TABLE|TABLE_ROW|TEXTTABLE}

Core Conversion

The following table shows the rules for conversion to another data type:

Conversion Result Sample
ToBoolean Undefined (should not be used)
ToInteger Returns the index of the value in the enumeration (smallest index is 0). Integer i = ToInteger(McdDataTypeVariable); // Returns the index of the value in the enumeration.
ToFloat Undefined (should not be used)
ToString Returns the name of the enumeration value. String s = ToString(McdDataTypeVariable); // Returns the name of the enumeration value.
ToByteField Undefined (should not be used)

Sample

DiagDataBrowsingPlus.McdDataType McdDataTypeVariable1 = @McdDataType:ASCIISTRING;