Package com._1c.g5.v8.dt.lcore.util
Class FeatureSetting
java.lang.Object
com._1c.g5.v8.dt.lcore.util.FeatureSetting
Represents a value held by a feature of an object.
-
Constructor Summary
ConstructorsConstructorDescriptionFeatureSetting(org.eclipse.emf.ecore.EObject containedObject) Constructs a new containment feature setting for the given contained object.FeatureSetting(org.eclipse.emf.ecore.EObject owner, org.eclipse.emf.ecore.EStructuralFeature feature) Constructs a new single-valued feature setting.FeatureSetting(org.eclipse.emf.ecore.EObject owner, org.eclipse.emf.ecore.EStructuralFeature feature, int index) Constructs a new feature setting. -
Method Summary
Modifier and TypeMethodDescriptionbooleanorg.eclipse.emf.ecore.EStructuralFeatureReturns the specific feature holding a value for the object.Returns the feature and the index grouped together.intgetIndex()Returns the index of a value in the list of feature values.org.eclipse.emf.ecore.EObjectgetOwner()Returns the object holding a value.getValue()Returns the resolved value held by the feature of the object.inthashCode()booleanReturns whether this setting describes containment relationship.toString()
-
Constructor Details
-
FeatureSetting
public FeatureSetting(org.eclipse.emf.ecore.EObject owner, org.eclipse.emf.ecore.EStructuralFeature feature, int index) Constructs a new feature setting.- Parameters:
owner- the object holding a value (notnull)feature- the specific feature holding a value for the object (notnull)index- the index of a value in the list of feature values. Ignored if the feature is single-valued
-
FeatureSetting
public FeatureSetting(org.eclipse.emf.ecore.EObject owner, org.eclipse.emf.ecore.EStructuralFeature feature) Constructs a new single-valued feature setting.- Parameters:
owner- the object holding a value (notnull)feature- the specific single-valued feature holding a value for the object (notnull)
-
FeatureSetting
public FeatureSetting(org.eclipse.emf.ecore.EObject containedObject) Constructs a new containment feature setting for the given contained object.- Parameters:
containedObject- notnull. Must have a containing object
-
-
Method Details
-
getOwner
public org.eclipse.emf.ecore.EObject getOwner()Returns the object holding a value.- Returns:
- the object holding a value (never
null)
-
getFeature
public org.eclipse.emf.ecore.EStructuralFeature getFeature()Returns the specific feature holding a value for the object.- Returns:
- the specific feature holding a value for the object
(never
null)
-
getIndex
public int getIndex()Returns the index of a value in the list of feature values. Returns0if the feature is single-valued.- Returns:
- the value index
-
getFeatureIndex
Returns the feature and the index grouped together.- Returns:
- the feature and the index grouped together
(never
null)
-
getValue
Returns the resolved value held by the feature of the object.- Returns:
- the resolved value held by the feature of the object
-
isContainment
public boolean isContainment()Returns whether this setting describes containment relationship.- Returns:
trueif this setting describes containment relationship,falseotherwise
-
equals
-
hashCode
public int hashCode() -
toString
-