Class FeaturePathDomainModelReferenceConverter
- java.lang.Object
-
- org.eclipse.emfforms.core.services.databinding.featurepath.FeaturePathDomainModelReferenceConverter
-
- All Implemented Interfaces:
DomainModelReferenceConverter
,DomainModelReferenceConverterEMF
public class FeaturePathDomainModelReferenceConverter extends java.lang.Object implements DomainModelReferenceConverterEMF
An implementation ofDomainModelReferenceConverterEMF
that convertsVFeaturePathDomainModelReference
s.- Author:
- Lucas Koehler
-
-
Field Summary
-
Fields inherited from interface org.eclipse.emfforms.spi.core.services.databinding.DomainModelReferenceConverter
NOT_APPLICABLE
-
-
Constructor Summary
Constructors Constructor Description FeaturePathDomainModelReferenceConverter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.eclipse.emf.databinding.IEMFListProperty
convertToListProperty(VDomainModelReference domainModelReference, org.eclipse.emf.ecore.EObject object)
Converts aVDomainModelReference
to anIListProperty
.org.eclipse.emf.databinding.IEMFValueProperty
convertToValueProperty(VDomainModelReference domainModelReference, org.eclipse.emf.ecore.EClass rootEClass, org.eclipse.emf.edit.domain.EditingDomain editingDomain)
org.eclipse.emf.databinding.IEMFValueProperty
convertToValueProperty(VDomainModelReference domainModelReference, org.eclipse.emf.ecore.EObject object)
Converts aVDomainModelReference
to aIValueProperty
.org.eclipse.emf.ecore.EStructuralFeature.Setting
getSetting(VDomainModelReference domainModelReference, org.eclipse.emf.ecore.EObject object)
Retrieve the Setting which is described by the providedVDomainModelReference
and the providedEObject
.double
isApplicable(VDomainModelReference domainModelReference)
Checks whether the givenVDomainModelReference
can be converted by thisDomainModelReferenceConverter
to aIValueProperty
.
-
-
-
Method Detail
-
isApplicable
public double isApplicable(VDomainModelReference domainModelReference)
Description copied from interface:DomainModelReferenceConverter
Checks whether the givenVDomainModelReference
can be converted by thisDomainModelReferenceConverter
to aIValueProperty
. The return value is the priority of this converter. The higher the priority, the better suits the converter the givenVDomainModelReference
.- Specified by:
isApplicable
in interfaceDomainModelReferenceConverter
- Parameters:
domainModelReference
- TheVDomainModelReference
whose priority is wanted.- Returns:
- The priority of the given
VDomainModelReference
; negative infinity if this converter is not applicable.
-
convertToValueProperty
public org.eclipse.emf.databinding.IEMFValueProperty convertToValueProperty(VDomainModelReference domainModelReference, org.eclipse.emf.ecore.EObject object) throws DatabindingFailedException
Description copied from interface:DomainModelReferenceConverter
Converts aVDomainModelReference
to aIValueProperty
.- Specified by:
convertToValueProperty
in interfaceDomainModelReferenceConverter
- Specified by:
convertToValueProperty
in interfaceDomainModelReferenceConverterEMF
- Parameters:
domainModelReference
- TheVDomainModelReference
that will be converted to aIValueProperty
object
- The root object of the rendered form- Returns:
- The created
IValueProperty
, does not returnnull
. - Throws:
DatabindingFailedException
- if no value property could be created due to an invalidVDomainModelReference
.
-
convertToValueProperty
public org.eclipse.emf.databinding.IEMFValueProperty convertToValueProperty(VDomainModelReference domainModelReference, org.eclipse.emf.ecore.EClass rootEClass, org.eclipse.emf.edit.domain.EditingDomain editingDomain) throws DatabindingFailedException
Description copied from interface:DomainModelReferenceConverterEMF
- Specified by:
convertToValueProperty
in interfaceDomainModelReferenceConverterEMF
- Parameters:
domainModelReference
- TheVDomainModelReference
that will be converted to aIValueProperty
rootEClass
- The rootEClass
of the givenVDomainModelReference
editingDomain
- TheEditingDomain
used by the createdvalue property
. The EditingDomain might benull
but in this case the value property will not support set functionality- Returns:
- The created
IValueProperty
, does not returnnull
. - Throws:
DatabindingFailedException
- if no value property could be created due to an invalidVDomainModelReference
.
-
convertToListProperty
public org.eclipse.emf.databinding.IEMFListProperty convertToListProperty(VDomainModelReference domainModelReference, org.eclipse.emf.ecore.EObject object) throws DatabindingFailedException
Description copied from interface:DomainModelReferenceConverter
Converts aVDomainModelReference
to anIListProperty
.- Specified by:
convertToListProperty
in interfaceDomainModelReferenceConverter
- Specified by:
convertToListProperty
in interfaceDomainModelReferenceConverterEMF
- Parameters:
domainModelReference
- TheVDomainModelReference
that will be converted to anIListProperty
object
- The root object of the rendered form- Returns:
- The created
IListProperty
, does not returnnull
. - Throws:
DatabindingFailedException
- if no value property could be created due to an invalidVDomainModelReference
.
-
getSetting
public org.eclipse.emf.ecore.EStructuralFeature.Setting getSetting(VDomainModelReference domainModelReference, org.eclipse.emf.ecore.EObject object) throws DatabindingFailedException
Description copied from interface:DomainModelReferenceConverterEMF
Retrieve the Setting which is described by the providedVDomainModelReference
and the providedEObject
.- Specified by:
getSetting
in interfaceDomainModelReferenceConverterEMF
- Parameters:
domainModelReference
- TheVDomainModelReference
to use to retrieve the settingobject
- TheEObject
to use to retrieve the setting- Returns:
- The Setting being described by the
VDomainModelReference
- Throws:
DatabindingFailedException
- if the databinding could not be executed successfully.
-
-