public class ModelTypeAttribute extends AbstractModelElement implements IModelTypeAttribute
ModelTypeAttribute represent an attribute from the PolicyCmptType or the
ProductCmptType.IModelTypeAttribute.AttributeType, IModelTypeAttribute.ValueSetTypePROPERTY_ATTRIBUTE_TYPE, PROPERTY_DATATYPE, PROPERTY_PRODUCT_RELEVANT, PROPERTY_VALUE_SET_TYPE, XML_TAG, XML_WRAPPER_TAGDESCRIPTIONS_PROPERTY_LOCALE, DESCRIPTIONS_XML_TAG, DESCRIPTIONS_XML_WRAPPER_TAG, EXTENSION_PROPERTIES_PROPERTY_ID, EXTENSION_PROPERTIES_PROPERTY_NULL, EXTENSION_PROPERTIES_XML_TAG, EXTENSION_PROPERTIES_XML_WRAPPER_TAG, LABELS_PROPERTY_LOCALE, LABELS_PROPERTY_PLURAL_VALUE, LABELS_PROPERTY_VALUE, LABELS_XML_TAG, LABELS_XML_WRAPPER_TAG, PROPERTY_NAME| Constructor and Description |
|---|
ModelTypeAttribute(ModelType modelType) |
| Modifier and Type | Method and Description |
|---|---|
protected Class<?> |
findDatatype() |
IModelTypeAttribute.AttributeType |
getAttributeType() |
Class<?> |
getDatatype() |
IModelType |
getModelType()
Returns the model type this attribute belongs to.
|
Object |
getValue(IModelObject source)
Returns the value of the given model object's attribute identified by this model type
attribute.
|
IModelTypeAttribute.ValueSetType |
getValueSetType()
Returns the type of value set restricting this attribute
|
void |
initFromXml(XMLStreamReader parser)
Initializes the model element's state with the data stored in the xml element at the parser's
current position.
|
boolean |
isProductRelevant()
Returns if this attribute is product relevant.
|
void |
setValue(IModelObject source,
Object value)
Sets the given model object's attribute identified by this model type attribute to the given
value.
|
String |
toString() |
getDescription, getExtensionPropertyIds, getExtensionPropertyValue, getLabel, getName, getRepository, initDescriptionsFromXml, initExtPropertiesFromXml, initLabelFromXml, initLabelsFromXml, setExtensionPropertyValueclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetDescription, getExtensionPropertyIds, getExtensionPropertyValue, getLabel, getName, getRepository, initExtPropertiesFromXmlpublic ModelTypeAttribute(ModelType modelType)
public IModelType getModelType()
IModelTypeAttributegetModelType in interface IModelTypeAttributepublic Class<?> getDatatype() throws ClassNotFoundException
getDatatype in interface IModelTypeAttributeClass.ClassNotFoundException - if the datatype's class can not be loaded.public IModelTypeAttribute.AttributeType getAttributeType()
getAttributeType in interface IModelTypeAttributepublic IModelTypeAttribute.ValueSetType getValueSetType()
IModelTypeAttributegetValueSetType in interface IModelTypeAttributepublic boolean isProductRelevant()
IModelTypeAttributeisProductRelevant in interface IModelTypeAttributepublic void initFromXml(XMLStreamReader parser) throws XMLStreamException
IModelElementinitFromXml in interface IModelElementinitFromXml in class AbstractModelElementXMLStreamExceptionprotected Class<?> findDatatype()
public Object getValue(IModelObject source)
IModelTypeAttributegetValue in interface IModelTypeAttributesource - a model object corresponding to the IModelType this attribute
belongs topublic void setValue(IModelObject source, Object value)
IModelTypeAttributeIModelTypeAttribute.AttributeType.CHANGEABLE.setValue in interface IModelTypeAttributesource - a model object corresponding to the IModelType this attribute
belongs tovalue - an object of this model type attribute's datatypeCopyright © 2014. All rights reserved.