[New] Added Parameter.isUomDefined() and .isInterpretationDefined()
This commit is contained in:
parent
579902fbc7
commit
e4fcf459ba
|
@ -87,6 +87,11 @@ public abstract class AbstractParameter<T> extends AbstractStrolchElement implem
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isInterpretationDefined() {
|
||||
return !INTERPRETATION_NONE.equals(this.interpretation);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getUom() {
|
||||
return this.uom;
|
||||
|
@ -102,6 +107,11 @@ public abstract class AbstractParameter<T> extends AbstractStrolchElement implem
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isUomDefined() {
|
||||
return !UOM_NONE.equals(this.uom);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setIndex(int index) {
|
||||
assertNotReadonly();
|
||||
|
|
|
@ -124,6 +124,13 @@ public interface Parameter<T> extends StrolchElement, Comparable<Parameter<?>> {
|
|||
*/
|
||||
void setUom(String uom);
|
||||
|
||||
/**
|
||||
* Returns true if the interpretation is not {@link StrolchModelConstants#UOM_NONE}
|
||||
*
|
||||
* @return true if the interpretation is not {@link StrolchModelConstants#UOM_NONE}
|
||||
*/
|
||||
boolean isUomDefined();
|
||||
|
||||
/**
|
||||
* Returns the index of this {@link Parameter}. This can be used to sort the parameters in a UI
|
||||
*
|
||||
|
@ -166,6 +173,13 @@ public interface Parameter<T> extends StrolchElement, Comparable<Parameter<?>> {
|
|||
*/
|
||||
void setInterpretation(String interpretation);
|
||||
|
||||
/**
|
||||
* Returns true if the interpretation is not {@link StrolchModelConstants#INTERPRETATION_NONE}
|
||||
*
|
||||
* @return true if the interpretation is not {@link StrolchModelConstants#INTERPRETATION_NONE}
|
||||
*/
|
||||
boolean isInterpretationDefined();
|
||||
|
||||
/**
|
||||
* The {@link ParameterizedElement} parent to which this {@link Parameter} belongs
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue