|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.ashridgetech.jamda.uml.ModelElement | +--com.ashridgetech.jamda.uml.Feature | +--com.ashridgetech.jamda.uml.Attribute
A UML Attribute. Contained by ClassType
.
Nested Class Summary | |
protected class |
Attribute.PropertyImpl
Inner class implementation of the Property interface for Attribute . |
Nested classes inherited from class com.ashridgetech.jamda.uml.ModelElement |
ModelElement.DuplicateElementException, ModelElement.ElementListStore, ModelElement.ElementNameListStore, ModelElement.ElementNameStore, ModelElement.ElementStore, ModelElement.TaggedValue, ModelElement.UnknownElementException |
Field Summary | |
static java.lang.String |
DEFAULT_OID_NAME
|
Fields inherited from class com.ashridgetech.jamda.uml.ModelElement |
DUMMY_STORE |
Constructor Summary | |
|
Attribute(ClassType owner,
java.lang.String name,
Type type)
Creates new Attribute belonging to a ClassType . |
protected |
Attribute(ru.novosoft.uml.foundation.core.MAttribute ma,
ClassType owner)
Creates new Attribute from a NSUML MAttribute object during loading |
Method Summary | |
StructuredType.Aggregation |
getAggregation()
Get the aggregation of this Attribute . |
java.lang.String |
getInitialValue()
Get the initial value of this Attribute , or null if no initial value
is specified. |
java.lang.String |
getMultName()
Get the name of this Attribute , converted to plural using Util.pluralize(java.lang.String)
if isMultiple() returns true. |
ClassType |
getOwner()
Get the owner of this Attribute . |
Property |
getProperty()
Get the representation of this Attribute as a Property . |
Type |
getType()
Get the type of this Attribute . |
boolean |
isChangeable()
Show whether this Attribute is changeable or frozen. |
boolean |
isMultiple()
Indicate whether this property can have multiple values. |
boolean |
isOid()
Indicate whether this Attribute is an object identifier (OID)
for its StructuredType . |
boolean |
isReadable()
Indicate whether the value(s) of this property can be read. |
boolean |
isWritable()
Indicate whether the value(s) of this property can be written. |
boolean |
isWritableBy(Actor actor)
Indicate whether the value(s) of this property can be written by a given Actor . |
protected Attribute |
setChangeable(boolean changeable)
Set whether this Attribute is changeable or frozen. |
Attribute |
setInitialValue(java.lang.String initValue)
Set the visibility of this Attribute . |
Attribute |
setStatic(boolean isStatic)
Set whether this Attribute is of static scope. |
Attribute |
setVisibility(StructuredType.Visibility visibility)
Set the visibility of this Attribute . |
Methods inherited from class com.ashridgetech.jamda.uml.Feature |
getReaders, getVisibility, getWriters, isReadableBy, isStatic, setFeatureStatic, setFeatureVisibility |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final java.lang.String DEFAULT_OID_NAME
Constructor Detail |
public Attribute(ClassType owner, java.lang.String name, Type type)
Attribute
belonging to a ClassType
.
owner
- the owner of this Attribute
name
- the name of this Attribute
type
- the type of this Attribute
protected Attribute(ru.novosoft.uml.foundation.core.MAttribute ma, ClassType owner)
Method Detail |
public ClassType getOwner()
Attribute
.
ClassType
to which this belongsModelElement.getParentElement()
public Type getType()
Attribute
.
public Attribute setStatic(boolean isStatic)
Attribute
is of static scope.
isStatic
- true if this is to be static
public boolean isChangeable()
Attribute
is changeable or frozen.
protected Attribute setChangeable(boolean changeable)
Attribute
is changeable or frozen.
changeable
- true if this is to be changeable
public boolean isMultiple()
NSUtil.isMultiple(ru.novosoft.uml.foundation.data_types.MMultiplicity)
public java.lang.String getMultName()
Attribute
, converted to plural using Util.pluralize(java.lang.String)
if isMultiple()
returns true.
public boolean isReadable()
public boolean isWritable()
public Attribute setVisibility(StructuredType.Visibility visibility)
Attribute
.
visibility
- the Visibility
instance representing
this Attribute
's visibility - must not be null
public StructuredType.Aggregation getAggregation()
Attribute
.
StructuredType.Aggregation.COMPOSITE
public java.lang.String getInitialValue()
Attribute
, or null if no initial value
is specified.
public Attribute setInitialValue(java.lang.String initValue)
Attribute
.
initValue
- the new initial value expression - must not be null
public boolean isWritableBy(Actor actor)
Actor
.
For this to be true, Feature.isWritableBy(com.ashridgetech.jamda.uml.Actor)
must be true AND thisAttribute
must be changeable
isWritableBy
in class Feature
public boolean isOid()
Attribute
is an object identifier (OID)
for its StructuredType
.
DEFAULT_OID_NAME
public Property getProperty()
Attribute
as a Property
.
getProperty
in interface PropertyElement
Property
for this Attribute
- always the same instance
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |