Difference between revisions of "Extensions.ComInterface.ConnectionStatus"
Jump to navigation
Jump to search
(Created by Ngoc Tran.) |
(Edited by Ngoc Tran.) |
||
Line 5: | Line 5: | ||
== Description == | == Description == | ||
'''ConnectionStatus''' represents the MCDInterfaceStatus enumerations that are mapped to the PDU module states. | '''ConnectionStatus''' represents the MCDInterfaceStatus enumerations that are mapped to the PDU module states. | ||
− | {{Important|If the '''ConnectionStatus''' declaration is not explicitly initialized (omitted <init> element), the default value will be Current. }} | + | {{Important|If the '''ConnectionStatus''' declaration is not explicitly initialized (omitted <init> element : comIf:ConnectionStatusLiteral[0..1]), the default value will be Current. }} |
'''ConnectionStatus''' has the following enumeration values: | '''ConnectionStatus''' has the following enumeration values: |
Revision as of 06:44, 14 October 2019
Classification
Name | ConnectionStatus |
Short Description | Represents the MCDInterfaceStatus enumerations that are mapped to the PDU module states. |
Class | Simple Data Type |
Base Data Type | SimpleType |
Default Value | AVAILABLE |
Provide a Literal | Yes |
SpecifiedBy | ISO 13209-4 |
Standard Compliant | Yes |
Description
ConnectionStatus represents the MCDInterfaceStatus enumerations that are mapped to the PDU module states.
![]() |
Important: If the ConnectionStatus declaration is not explicitly initialized (omitted <init> element : comIf:ConnectionStatusLiteral[0..1]), the default value will be Current. |
ConnectionStatus has the following enumeration values:
Value | Literal | Description |
---|---|---|
AVAILABLE | @ConnectionStatus:AVAILABLE | The interfaces which are available in the underlying system (Case of MCD server:MCDInterfaceStatus = NOT_RADY or AVAILABLE). |
CONNECTED | @ConnectionStatus:CONNECTED | The interfaces which are connected to the underlying system (Case of MCD server: MCDInterfaceStatus = READY). |
NOT_AVAILABLE | @ConnectionStatus:NOT_AVAILABLE | The interfaces which are not available in the underlying system (Case of MCD server: MCDInterfaceStatus = NOT_AVAILABLE). |
Order Relation
ConnectionStatus values may occur as operands of comparisons (cf. Part 2 of ISO 13209, relational operations). For this case, the following order relation will apply:
NOT_AVAILABLE < AVAILABLE < CONNECTED
Literal
The syntax for Literals for simple data types will be used, where the member value is one of the values in the list.
@ConnectionStatus:NOT_AVAILABLE|AVAILABLE|CONNECTED
Core Conversion
The following table shows the rules for conversion to another data type:
Conversion | Result | Sample |
ToBoolean | Undefined (should not be used) | |
ToInteger | Return the index of the value in the ConnectionStatus enumeration (smallest index is 0) | Integer val = ToInteger(@ConnectionStatus:NOT_AVAILABLE); // Returns 0 |
ToFloat | Undefined (should not be used) | |
ToString | The resulting string will be the name of the enumeration value | String s = ToString(@ConnectionStatus:CONNECTED); // Returns "CONNECTED" |
ToByteField | Undefined (should not be used) |
Sample
ConInterface.ConnectionStatus connectionStatusVariable = @ConnectionStatus:AVAILABLE;