net.sourceforge.nrl.parser.model.uml2
Class UML2Attribute

java.lang.Object
  extended by net.sourceforge.nrl.parser.model.AbstractAttribute
      extended by net.sourceforge.nrl.parser.model.uml2.UML2Attribute
All Implemented Interfaces:
IAttribute

public class UML2Attribute
extends AbstractAttribute

Extension of a standard attribute that holds a UML2 typed element reference.


Field Summary
 
Fields inherited from interface net.sourceforge.nrl.parser.model.IAttribute
UNBOUNDED
 
Constructor Summary
UML2Attribute(NamedElement namedElement)
          Initialise the attribute using a UML2 named element object.
 
Method Summary
 List<String> getDocumentation()
          Extract the documentation from the UML attribute.
 int getMaxOccurs()
          Return the maximum number of occurrences of the attribute (0 or more).
 int getMinOccurs()
          Return the minimum number of occurrences of the attribute (0 or more).
 NamedElement getUML2()
          Return the UML2 Property this attribute was created from.
 boolean isStatic()
          Returns true if the attribute is static, or if it is an enum value.
 
Methods inherited from class net.sourceforge.nrl.parser.model.AbstractAttribute
getName, getOriginalName, getOwner, getType, getUserData, isRepeating, setName, setOriginalName, setOwner, setType, setUserData
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UML2Attribute

public UML2Attribute(NamedElement namedElement)
Initialise the attribute using a UML2 named element object. The type of the attribute will remain unresolved until resolve(Map) is called.

Parameters:
namedElement - the element
Method Detail

getDocumentation

public List<String> getDocumentation()
Extract the documentation from the UML attribute.

Returns:
the documentation or an empty list

getMinOccurs

public int getMinOccurs()
Description copied from interface: IAttribute
Return the minimum number of occurrences of the attribute (0 or more).

Returns:
the occurrences

getMaxOccurs

public int getMaxOccurs()
Description copied from interface: IAttribute
Return the maximum number of occurrences of the attribute (0 or more).

Returns:
the occurrences

isStatic

public boolean isStatic()
Description copied from interface: IAttribute
Returns true if the attribute is static, or if it is an enum value.

Returns:
true if static

getUML2

public NamedElement getUML2()
Return the UML2 Property this attribute was created from.

Returns:
the property


Copyright © 2006-2010 Christian Nentwich and others