Class AasField
java.lang.Object
de.iip_ecosphere.platform.configuration.aas.AbstractAasElement
de.iip_ecosphere.platform.configuration.aas.AasField
- Direct Known Subclasses:
AasOperation
Represents a field in an
AasType.- Author:
- Holger Eichelberger, SSE
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Stringprivate Stringprivate String[]private booleanprivate intprivate AasSmeTypeprivate intprivate String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the optional aspect this field is assigned to.Returns the optional example explanation.String[]Returns the optional example value(s).getIvmlValueType(boolean log) Returns the value type as IVML type.private static de.iip_ecosphere.platform.support.logging.LoggerReturns the logger instance for this class.intReturns whether the lower cardinality.Returns the submodelelement type.intReturns whether the upper cardinality.Returns the value type.booleanReturns whether the field has a specified cardinality.booleanReturns whether this field has a value type defined.static booleanisBasicType(String type) Returns whether the giventypeis considered to be a known, basic type.booleanReturns whether the field is multi-valued, i.e., with multi-value counting suffix.(package private) static StringmapPropertyType(String valueType, String dflt) Maps a fieldvalueTypefor AAS properties.(package private) voidDefines the aspect this field is assigned to.(package private) voidsetCardinality(int lowerUpper) Defines the lower and upper cardinality to the same value.(package private) voidsetCardinality(int lowerCardinality, int upperCardinality) Defines the lower and upper cardinality.(package private) voidsetExampleExplanation(String exampleExplanation) Defines the optional example explanation.(package private) voidsetExampleValues(String... value) Defines the optional example value(s).(package private) voidsetIdShort(String idShort, boolean isMultiValued) Defines the idShort.(package private) voidsetSmeType(AasSmeType smeType) Defines the submodelelement type.(package private) voidsetValueType(String valueType) Defines the value type.Methods inherited from class de.iip_ecosphere.platform.configuration.aas.AbstractAasElement
getDescription, getDisplayName, getIdShort, getIsCaseOf, getSemanticId, hasMultiSemanticIds, isGeneric, setDescription, setDisplayName, setGeneric, setIdShort, setIsCaseOf, setMultiSemanticIds, setSemanticId, toString
-
Field Details
-
BASIC_TYPES
-
smeType
-
isMultiValued
private boolean isMultiValued -
valueType
-
exampleValues
-
exampleExplanation
-
lowerCardinality
private int lowerCardinality -
upperCardinality
private int upperCardinality -
aspect
-
-
Constructor Details
-
AasField
AasField()Creates an instance. -
AasField
AasField(AasField field) Copies values offield.- Parameters:
field- the source element
-
-
Method Details
-
setSmeType
Defines the submodelelement type.- Parameters:
smeType- the submodelelement type
-
getSmeType
Returns the submodelelement type.- Returns:
- the submodelelement type
-
setIdShort
Defines the idShort.- Parameters:
idShort- the idShort without multi-value counting suffix.isMultiValued- whether the field is multi-valued
-
isMultiValued
public boolean isMultiValued()Returns whether the field is multi-valued, i.e., with multi-value counting suffix.- Returns:
truefor multi-valued,falseelse
-
getAspect
Returns the optional aspect this field is assigned to.- Returns:
- the aspect, may be null for none
-
setAspect
Defines the aspect this field is assigned to.- Parameters:
aspect- the aspect, may be null for none
-
setValueType
Defines the value type.- Parameters:
valueType- the value type
-
hasValueType
public boolean hasValueType()Returns whether this field has a value type defined.- Returns:
truefor defined,falsefor not defined
-
setExampleValues
Defines the optional example value(s).- Parameters:
value- the example value(s)
-
getExampleValues
Returns the optional example value(s).- Returns:
- the example values
-
setExampleExplanation
Defines the optional example explanation.- Parameters:
exampleExplanation- the example explanation
-
getExampleExplanation
Returns the optional example explanation.- Returns:
- the example explanation
-
setCardinality
void setCardinality(int lowerUpper) Defines the lower and upper cardinality to the same value.- Parameters:
lowerUpper- the lower and upper cardinality, the minimum integer for none
-
setCardinality
void setCardinality(int lowerCardinality, int upperCardinality) Defines the lower and upper cardinality.- Parameters:
lowerCardinality- the lower cardinality, the minimum integer for noneupperCardinality- the upper cardinality, the minimum integer for none
-
getLowerCardinality
public int getLowerCardinality()Returns whether the lower cardinality.- Returns:
- the upper cardinality, the minimum integer for none
-
getUpperCardinality
public int getUpperCardinality()Returns whether the upper cardinality.- Returns:
- the upper cardinality, the minimum integer for none
-
hasCardinality
public boolean hasCardinality()Returns whether the field has a specified cardinality.- Returns:
truefor cardinality,falseelse
-
getValueType
Returns the value type.- Returns:
- the value type
-
isBasicType
Returns whether the giventypeis considered to be a known, basic type.- Parameters:
type- the type- Returns:
truefor known,falseelse
-
mapPropertyType
Maps a fieldvalueTypefor AAS properties.- Parameters:
valueType- the actual type, may be null or emptydflt- the default value if none matchex, may be null,valueTypeetc.- Returns:
- the resulting type, may be null
-
getIvmlValueType
Returns the value type as IVML type.- Parameters:
log- log the output- Returns:
- the IVML value type
-
getLogger
private static de.iip_ecosphere.platform.support.logging.Logger getLogger()Returns the logger instance for this class.- Returns:
- the logger instance
-