Search in sources :

Example 1 with AASAssetKindDataType

use of opc.i4aas.AASAssetKindDataType in project FAAAST-Service by FraunhoferIOSB.

the class AASAssetInformationTypeImplBase method getAssetKind.

@Mandatory
@Override
public AASAssetKindDataType getAssetKind() {
    UaVariable node = getAssetKindNode();
    if (node == null) {
        return null;
    }
    Variant value = node.getValue().getValue();
    return (AASAssetKindDataType) value.asEnum(AASAssetKindDataType.class);
}
Also used : Variant(com.prosysopc.ua.stack.builtintypes.Variant) UaVariable(com.prosysopc.ua.nodes.UaVariable) AASAssetKindDataType(opc.i4aas.AASAssetKindDataType) Mandatory(com.prosysopc.ua.nodes.Mandatory)

Example 2 with AASAssetKindDataType

use of opc.i4aas.AASAssetKindDataType in project FAAAST-Service by FraunhoferIOSB.

the class AASAssetInformationTypeNodeBase method getAssetKind.

@Mandatory
@Override
public AASAssetKindDataType getAssetKind() {
    UaVariable node = getAssetKindNode();
    if (node == null) {
        throw new RuntimeException("Mandatory node AssetKind does not exist");
    }
    Variant value = node.getValue().getValue();
    return (AASAssetKindDataType) value.asEnum(AASAssetKindDataType.class);
}
Also used : Variant(com.prosysopc.ua.stack.builtintypes.Variant) UaVariable(com.prosysopc.ua.nodes.UaVariable) AASAssetKindDataType(opc.i4aas.AASAssetKindDataType) Mandatory(com.prosysopc.ua.nodes.Mandatory)

Aggregations

Mandatory (com.prosysopc.ua.nodes.Mandatory)2 UaVariable (com.prosysopc.ua.nodes.UaVariable)2 Variant (com.prosysopc.ua.stack.builtintypes.Variant)2 AASAssetKindDataType (opc.i4aas.AASAssetKindDataType)2