Class PropertyDescriptorImpl
java.lang.Object
de.mid.innovator.m2msdk.model.transformation.property.PropertyDescriptorImpl
- All Implemented Interfaces:
PropertyDescriptorIF,Serializable
- Direct Known Subclasses:
PropertyAnchor,PropertyComposite,PropertyContext,PropertyFile,PropertyFilterName,PropertyFilterType,PropertyFix,PropertyGeneric,PropertyHash,PropertyInformationPurpose,PropertyInnovatorElementProxyState,PropertyInnovatorEnumLiteralProperty,PropertyInnovatorFlowText,PropertyInnovatorIsStereotypePropertyDefault,PropertyInnovatorLabel,PropertyInnovatorPath,PropertyInnovatorPathDepth,PropertyInnovatorStereotype,PropertyInnovatorText,PropertyIsElementMapped,PropertyIsElementPropertyChanged,PropertyIsTargetElementMapped,PropertyJavaBeansPropertyMeta,PropertyJavaFunction,PropertyLeft,PropertyListBase,PropertyLogicBase,PropertyMappedElement,PropertyNull,PropertyNumberBase,PropertyObject,PropertyObjects,PropertyOption,PropertyOptionStringMap,PropertyOriginalElement,PropertyPair,PropertyProperty,PropertyRight,PropertyStereotypeProperty,PropertyStore,PropertyStringBase,PropertySwitchBoolean,PropertyTerms
Generic implementation of a property descriptor.
- Version:
- 10.1.1
- Author:
- jmback
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionPropertyDescriptorImpl(SessionInterface iSession, MetaModel iMM) Default constructor, -
Method Summary
Modifier and TypeMethodDescriptionvoidAdd a subordinated property descriptor to this property descriptor.voidAdd a subordinated property descriptor to this property descriptor.filter(MappingElementList filterElements, PropertyValue iValue, ExpressionContext ec) Mass Filters Elements by PropertyValue.Get a long NLS description of the effect and the behavior of the property descriptor.getKnownNames(MappingElementIF element) Get list of known property names.Get meta model where the property descriptor is used in.Get property type.Get the result type of this property descriptor.Get all sub descriptors.getValue(MappingElementIF element) getValue(MappingElementIF element, ExpressionContext ec) Read value from item.getValueAsString(MappingElementIF element, ExpressionContext el) Read value as String from itemgetValues(MappingElementList elements) Read values from items.booleanisLogged()Is it necessary that modifications done with the descriptor are logged?setValue(MappingElementIF el, PropertyValue iValue) Set value for item.toString()
-
Constructor Details
-
PropertyDescriptorImpl
Default constructor,- Parameters:
iSession- current sessioniMM- meta model for the property descriptor
-
PropertyDescriptorImpl
public PropertyDescriptorImpl()
-
-
Method Details
-
getValue
public PropertyValue getValue(MappingElementIF element, ExpressionContext ec) throws M2MException, RemoteException Description copied from interface:PropertyDescriptorIFRead value from item.- Specified by:
getValuein interfacePropertyDescriptorIF- Parameters:
element- TODOec- context containing the model element and the source and the target and the anchors- Returns:
- items value
- Throws:
M2MExceptionRemoteExceptionRemoteException
-
getValue
- Specified by:
getValuein interfacePropertyDescriptorIF- Throws:
M2MExceptionRemoteException
-
getValues
Description copied from interface:PropertyDescriptorIFRead values from items.- Specified by:
getValuesin interfacePropertyDescriptorIF- Parameters:
elements- the elements from which the value should be read.- Returns:
- a list of all values
- Throws:
M2MExceptionRemoteExceptionRemoteException
-
getValueAsString
public String getValueAsString(MappingElementIF element, ExpressionContext el) throws M2MException, RemoteException Description copied from interface:PropertyDescriptorIFRead value as String from item- Specified by:
getValueAsStringin interfacePropertyDescriptorIF- Parameters:
element- TODOel- context containing the model element and the source and the target and the anchors- Returns:
- items as string value
- Throws:
M2MExceptionRemoteException
-
getPropertyType
Description copied from interface:PropertyDescriptorIFGet property type.- Specified by:
getPropertyTypein interfacePropertyDescriptorIF- Returns:
- the type of the property
-
filter
public MappingElementList filter(MappingElementList filterElements, PropertyValue iValue, ExpressionContext ec) throws M2MException, RemoteException Description copied from interface:PropertyDescriptorIFMass Filters Elements by PropertyValue. Filter the elements from the input list which have the given value as descriptor value.- Specified by:
filterin interfacePropertyDescriptorIF- Parameters:
filterElements- TODOiValue- given valueec- list of model elements to check- Returns:
- Elements having the given value.
- Throws:
M2MExceptionRemoteException
-
toString
-
addSubDescriptor
Description copied from interface:PropertyDescriptorIFAdd a subordinated property descriptor to this property descriptor.- Specified by:
addSubDescriptorin interfacePropertyDescriptorIF- Parameters:
sub- Property descriptor which has to be evaluated for evaluating this descriptor- Throws:
AbortException- critical errorRemoteExceptionRemoteException
-
addSubDescriptor
Description copied from interface:PropertyDescriptorIFAdd a subordinated property descriptor to this property descriptor.- Specified by:
addSubDescriptorin interfacePropertyDescriptorIF- Parameters:
subs- Property descriptor which has to be evaluated for evaluating this descriptor- Throws:
M2MExceptionRemoteExceptionRemoteException
-
getResult
Description copied from interface:PropertyDescriptorIFGet the result type of this property descriptor. The result type is determined by the property type.- Specified by:
getResultin interfacePropertyDescriptorIF- Returns:
- result type
-
getKnownNames
public ParameterProposalList getKnownNames(MappingElementIF element) throws M2MException, RemoteException Description copied from interface:PropertyDescriptorIFGet list of known property names. Even with a known name, a property descriptor may fail for getting or setting a value!- Specified by:
getKnownNamesin interfacePropertyDescriptorIF- Parameters:
element- Mapping element to be treated, maybe null.- Returns:
- List of known property names.
- Throws:
M2MExceptionRemoteExceptionRemoteException
-
setValue
public OperationResult setValue(MappingElementIF el, PropertyValue iValue) throws M2MException, RemoteException Description copied from interface:PropertyDescriptorIFSet value for item.- Specified by:
setValuein interfacePropertyDescriptorIF- Parameters:
el- item where to set the property (maybe null, meaning to set the value of the descriptor itself)iValue- to be set- Returns:
- false result, if error; true result, if identically changed; else setted value
- Throws:
M2MException- exception while settingRemoteException
-
getSubDescriptors
Description copied from interface:PropertyDescriptorIFGet all sub descriptors.- Specified by:
getSubDescriptorsin interfacePropertyDescriptorIF- Returns:
- sub descriptors
-
getMetaModel
Description copied from interface:PropertyDescriptorIFGet meta model where the property descriptor is used in.- Specified by:
getMetaModelin interfacePropertyDescriptorIF- Returns:
- Meta model of property descriptor
- Throws:
M2MException
-
getDescription
Description copied from interface:PropertyDescriptorIFGet a long NLS description of the effect and the behavior of the property descriptor.- Specified by:
getDescriptionin interfacePropertyDescriptorIF- Returns:
- long NLS string with description for user
-
isLogged
public boolean isLogged()Description copied from interface:PropertyDescriptorIFIs it necessary that modifications done with the descriptor are logged?- Specified by:
isLoggedin interfacePropertyDescriptorIF- Returns:
- true, if it is necessary.
-