|
|||||||||
PREV CLASS SOURCE NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A representation of the model object 'EStructural Feature'.
The following features are supported:
Changeable
Volatile
Transient
Unique
Default Value Literal
Default Value
Lower Bound
Upper Bound
Many
Required
Unsettable
EContaining Class
EcorePackage.getEStructuralFeature()
Inner Class Summary | |
static interface |
EStructuralFeature.Internal
Internal API implemented by all features. |
static interface |
EStructuralFeature.Setting
A representation of a value held by a feature of an object. |
Field Summary | |
static int |
UNBOUNDED_MULTIPLICITY
|
Method Summary | |
java.lang.Class |
getContainerClass()
Returns the instance class of the containing class. |
java.lang.Object |
getDefaultValue()
Returns the value of the 'Default Value' attribute. |
java.lang.String |
getDefaultValueLiteral()
Returns the value of the 'Default Value Literal' attribute. |
EClass |
getEContainingClass()
Returns the value of the 'EContaining Class' reference. |
int |
getFeatureID()
Returns the ID relative to the containing class. |
int |
getLowerBound()
Returns the value of the 'Lower Bound' attribute. |
int |
getUpperBound()
Returns the value of the 'Upper Bound' attribute. |
boolean |
isChangeable()
Returns the value of the 'Changeable' attribute. |
boolean |
isMany()
Returns the value of the 'Many' attribute. |
boolean |
isRequired()
Returns the value of the 'Required' attribute. |
boolean |
isTransient()
Returns the value of the 'Transient' attribute. |
boolean |
isUnique()
Returns the value of the 'Unique' attribute. |
boolean |
isUnsettable()
Returns the value of the 'Unsettable' attribute. |
boolean |
isVolatile()
Returns the value of the 'Volatile' attribute. |
void |
setChangeable(boolean value)
Sets the value of the ' Changeable ' attribute. |
void |
setDefaultValue(java.lang.Object value)
A convenience method for setting the 'Default Value Literal' attribute. |
void |
setDefaultValueLiteral(java.lang.String value)
Sets the value of the ' Default Value Literal ' attribute. |
void |
setLowerBound(int value)
Sets the value of the ' Lower Bound ' attribute. |
void |
setTransient(boolean value)
Sets the value of the ' Transient ' attribute. |
void |
setUnique(boolean value)
Sets the value of the ' Unique ' attribute. |
void |
setUnsettable(boolean value)
Sets the value of the ' Unsettable ' attribute. |
void |
setUpperBound(int value)
Sets the value of the ' Upper Bound ' attribute. |
void |
setVolatile(boolean value)
Sets the value of the ' Volatile ' attribute. |
Methods inherited from interface org.eclipse.emf.ecore.ETypedElement |
getEType, setEType |
Methods inherited from interface org.eclipse.emf.ecore.ENamedElement |
getName, setName |
Methods inherited from interface org.eclipse.emf.ecore.EModelElement |
getEAnnotation, getEAnnotations |
Methods inherited from interface org.eclipse.emf.ecore.EObject |
eAllContents, eClass, eContainer, eContainmentFeature, eContents, eCrossReferences, eGet, eGet, eIsProxy, eIsSet, eResource, eSet, eUnset |
Methods inherited from interface org.eclipse.emf.common.notify.Notifier |
eAdapters, eDeliver, eNotify, eSetDeliver |
Field Detail |
public static final int UNBOUNDED_MULTIPLICITY
Method Detail |
public boolean isTransient()
setTransient(boolean)
,
EcorePackage.getEStructuralFeature_Transient()
public void setTransient(boolean value)
Transient
' attribute.
value
- the new value of the 'Transient' attribute.isTransient()
public boolean isVolatile()
setVolatile(boolean)
,
EcorePackage.getEStructuralFeature_Volatile()
public void setVolatile(boolean value)
Volatile
' attribute.
value
- the new value of the 'Volatile' attribute.isVolatile()
public boolean isChangeable()
"true"
.
setChangeable(boolean)
,
EcorePackage.getEStructuralFeature_Changeable()
public void setChangeable(boolean value)
Changeable
' attribute.
value
- the new value of the 'Changeable' attribute.isChangeable()
public java.lang.String getDefaultValueLiteral()
It represents the serialized form of the default value.
setDefaultValueLiteral(String)
,
EcorePackage.getEStructuralFeature_DefaultValueLiteral()
public void setDefaultValueLiteral(java.lang.String value)
Default Value Literal
' attribute.
value
- the new value of the 'Default Value Literal' attribute.getDefaultValueLiteral()
public java.lang.Object getDefaultValue()
It represents the default value that feature must take on when an
explicit value has not been set. Specifically, it may be non-null if
the feature has an eType
. If the
defaultValueLiteral
is null, it is
simply the eType
's intrinsic default value
. Otherwise, if the
eType
is an EDataType
and the
defaultValueLiteral
is non-null, it is the object created
by the factory's EFactory.createFromString(org.eclipse.emf.ecore.EDataType, java.lang.String)
method when invoked
with those two objects as parameters.
EcorePackage.getEStructuralFeature_DefaultValue()
public void setDefaultValue(java.lang.Object value)
If the feature has an eType
that is an
EDataType
, the specified value
is converted to
a string using the factory's EFactory.convertToString(org.eclipse.emf.ecore.EDataType, java.lang.Object)
method, and the defaultValueLiteral
is
set to the result.
setDefaultValueLiteral(java.lang.String)
public boolean isUnique()
"true"
.
setUnique(boolean)
,
EcorePackage.getEStructuralFeature_Unique()
public void setUnique(boolean value)
Unique
' attribute.
value
- the new value of the 'Unique' attribute.isUnique()
public int getLowerBound()
It represents the minimum number of values that must appear in a valid instance.
setLowerBound(int)
,
EcorePackage.getEStructuralFeature_LowerBound()
public void setLowerBound(int value)
Lower Bound
' attribute.
value
- the new value of the 'Lower Bound' attribute.getLowerBound()
public int getUpperBound()
"1"
.
It represents the maximum number of values that must appear in a valid instance;
the value -1
represents unbounded.
setUpperBound(int)
,
EcorePackage.getEStructuralFeature_UpperBound()
public void setUpperBound(int value)
Upper Bound
' attribute.
value
- the new value of the 'Upper Bound' attribute.getUpperBound()
public boolean isMany()
EcorePackage.getEStructuralFeature_Many()
public boolean isRequired()
EcorePackage.getEStructuralFeature_Required()
public boolean isUnsettable()
An unsettable attribute explicitly models the state of being set verses being unset
and so provides a direct implementation for the reflective eIsSet
.
It is only applicable single-valued
features.
One effect of this setting is that,
in addition to generating the methods getXyz
and setXyz
(if the attribute is changeable
),
a reflective generator will generate the methods isSetXyz
and unsetXyz
.
setUnsettable(boolean)
,
EcorePackage.getEStructuralFeature_Unsettable()
public void setUnsettable(boolean value)
Unsettable
' attribute.
value
- the new value of the 'Unsettable' attribute.isUnsettable()
public EClass getEContainingClass()
It represents the containing class of this feature.
EcorePackage.getEStructuralFeature_EContainingClass()
public int getFeatureID()
containing
class.public java.lang.Class getContainerClass()
instance class
of the containing
class.
|
Copyright 2001-2003 IBM Corporation and others. All Rights Reserved. |
||||||||
PREV CLASS SOURCE NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |