|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.biomage.tools.generate_classes.XMIParseHelpers
public final class XMIParseHelpers
Nested Class Summary | |
---|---|
static class |
XMIParseHelpers.IDREFException
Description: Thrown when a lookup fails and the top element has an IDREF attribute. |
Field Summary | |
---|---|
static int |
AGGREGATE
Is Co-owned by one or more objects |
static int |
COMPOSITE
Is solely owned by a containing object |
static int |
NOT_AGGR
Is Independent |
static java.lang.String |
tobeIdentifiable
|
Constructor Summary | |
---|---|
XMIParseHelpers()
|
Method Summary | |
---|---|
static org.w3c.dom.Element |
getAssociationEndClassifier(org.w3c.dom.Element associationEndElement)
Description: Returns the classifier of the association end element. |
static int |
getAssociationEndMultiplicityRangeLower(org.w3c.dom.Element associationEndElement)
Description: Returns the multiplicity range lower of the association end element. |
static int |
getAssociationEndMultiplicityRangeUpper(org.w3c.dom.Element associationEndElement)
Description: Returns the multiplicity range upper of the association end element. |
static org.w3c.dom.Element |
getAttributeClassifier(org.w3c.dom.Element attributeElement)
Description: Returns the classifier of the association end element. |
static int |
getAttributeMultiplicityRangeLower(org.w3c.dom.Element attributeElement)
Description: Returns the multiplicity range lower of the association end element. |
static org.w3c.dom.NodeList |
getConstrainedElements(org.w3c.dom.Element constraintElement)
Description: Returns a NodeList of constrained elements. |
static java.lang.String |
getConstraintString(org.w3c.dom.Element constraintElement)
Description: Returns the string representing the constraint. |
static java.lang.String |
getElementID(org.w3c.dom.Element element)
Description: Returns the ID of the element. |
static java.lang.String |
getElementIDRef(org.w3c.dom.Element element)
Description: Returns the IDRef of the element. |
static java.lang.String |
getElementName(org.w3c.dom.Element element)
Description: Returns the name of the element. |
static java.lang.String |
getElementText(org.w3c.dom.Element element)
Description: Returns the text of the element. |
static java.lang.String |
getElementValue(org.w3c.dom.Element element)
Description: Returns the value of the element. |
static org.w3c.dom.Element |
getFirstElementByTagName(org.w3c.dom.Element element,
java.lang.String sName)
Description: Returns the first descendant Element with a given tag name, in the order in which they are encountered in a preorder traversal of this Element tree. |
static org.w3c.dom.Element |
getFirstElementByTagNameArray(org.w3c.dom.Element element,
java.lang.String[] asName)
Description: Returns the first descendant Element with a given tag name, in the order in which they are encountered in a preorder traversal of this Element tree. |
static java.lang.String |
getInitialValue(org.w3c.dom.Element attributeElement)
Description: Returns the classifier of the association end element. |
static org.w3c.dom.NodeList |
getOperationElements(org.w3c.dom.Element classElement)
Description: Returns a NodeList of operation elements. |
static java.lang.String |
getOperationSpecification(org.w3c.dom.Element operationElement)
Description: Returns the specification(semantics) of an operation. |
static org.w3c.dom.NodeList |
getParameterElements(org.w3c.dom.Element operationElement)
Description: Returns a NodeList of parameter elements. |
static java.lang.String |
getParameterKind(org.w3c.dom.Element parameterElement)
Description: Returns the kind of the parameter ("return", "inout", etc.). |
static java.lang.String |
getParameterTypeID(org.w3c.dom.Element parameterElement)
Description: Returns the id of the parameter element's data type. |
static java.lang.String |
getTokenValue(org.w3c.dom.Document doc,
java.lang.String token)
Description: Returns the text of the element with name of token. |
static boolean |
isAssociationEndNavigable(org.w3c.dom.Element associationEndElement)
Description: Returns whether the association end is navigable. |
static boolean |
isAssociationEndOrdered(org.w3c.dom.Element associationEndElement)
Description: Returns whether the association end is ordered. |
static boolean |
isIdentifiable(org.w3c.dom.Element myclass)
Description: Returns whether or not a given class is Identifiable -- useful in the C++ generation code. |
static void |
setIdentifiable(org.w3c.dom.Element myclass,
boolean value)
Description: Sets up a class as identifiable or not. |
static void |
setIdentifiable(org.w3c.dom.Element myclass,
java.lang.String value)
Description: Sets up a class as identifiable or not. |
static int |
typeAssociationEndAggregate(org.w3c.dom.Element associationEndElement)
Description: Returns whether the association end is aggregate. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int NOT_AGGR
public static final int AGGREGATE
public static final int COMPOSITE
public static final java.lang.String tobeIdentifiable
Constructor Detail |
---|
public XMIParseHelpers()
Method Detail |
---|
public static org.w3c.dom.Element getAssociationEndClassifier(org.w3c.dom.Element associationEndElement) throws java.lang.Exception
associationEndElement:
- the association end element tree.
java.lang.Exception
public static org.w3c.dom.Element getAttributeClassifier(org.w3c.dom.Element attributeElement) throws java.lang.Exception
associationEndElement:
- the association end element tree.
java.lang.Exception
public static java.lang.String getInitialValue(org.w3c.dom.Element attributeElement) throws java.lang.Exception
attributeElement:
- the attribute element tree.
java.lang.Exception
public static java.lang.String getConstraintString(org.w3c.dom.Element constraintElement) throws java.lang.Exception
constraintElement:
- the constraint element tree.
java.lang.Exception
public static org.w3c.dom.NodeList getConstrainedElements(org.w3c.dom.Element constraintElement) throws java.lang.Exception
constraintElement:
- the constraint element tree.
java.lang.Exception
public static org.w3c.dom.NodeList getOperationElements(org.w3c.dom.Element classElement) throws java.lang.Exception
classElement:
- the class element tree.
java.lang.Exception
public static org.w3c.dom.NodeList getParameterElements(org.w3c.dom.Element operationElement) throws java.lang.Exception
oeprationElement:
- the operation element tree.
java.lang.Exception
public static java.lang.String getParameterTypeID(org.w3c.dom.Element parameterElement) throws java.lang.Exception
paramElement:
- the parameter element tree.
java.lang.Exception
public static java.lang.String getParameterKind(org.w3c.dom.Element parameterElement) throws java.lang.Exception
paramElement:
- the parameter element tree.
java.lang.Exception
public static java.lang.String getOperationSpecification(org.w3c.dom.Element operationElement) throws java.lang.Exception
operationElement:
- the operation element tree.
java.lang.Exception
public static int getAssociationEndMultiplicityRangeLower(org.w3c.dom.Element associationEndElement) throws java.lang.Exception
associationEndElement:
- the association end element tree.
java.lang.Exception
public static int getAssociationEndMultiplicityRangeUpper(org.w3c.dom.Element associationEndElement) throws java.lang.Exception
associationEndElement:
- the association end element tree.
java.lang.Exception
public static int getAttributeMultiplicityRangeLower(org.w3c.dom.Element attributeElement) throws java.lang.Exception
associationEndElement:
- the association end element tree.
java.lang.Exception
public static java.lang.String getElementID(org.w3c.dom.Element element) throws java.lang.Exception
element:
- the element tree.
java.lang.Exception
public static java.lang.String getElementIDRef(org.w3c.dom.Element element) throws java.lang.Exception
element:
- the element tree.
java.lang.Exception
public static java.lang.String getElementValue(org.w3c.dom.Element element) throws java.lang.Exception
element:
- the element tree.
java.lang.Exception
public static java.lang.String getElementName(org.w3c.dom.Element element) throws java.lang.Exception
element:
- the element tree.
java.lang.Exception
public static java.lang.String getElementText(org.w3c.dom.Element element) throws java.lang.Exception
element:
- the element tree.
java.lang.Exception
public static java.lang.String getTokenValue(org.w3c.dom.Document doc, java.lang.String token) throws java.lang.Exception
doc:
- the document which may have an elemnt with a name
corresponding to tokentoken:
- name of element to get the text of.
java.lang.Exception
public static org.w3c.dom.Element getFirstElementByTagName(org.w3c.dom.Element element, java.lang.String sName)
element:
- the element tree.sName:
- name of the tag to match on. The special value "*"
matches all tags.
public static org.w3c.dom.Element getFirstElementByTagNameArray(org.w3c.dom.Element element, java.lang.String[] asName) throws XMIParseHelpers.IDREFException, java.lang.Exception
element:
- the element tree.asName:
- array of names of the tags to match on. The special
value "*" matches all tags.
XMIParseHelpers.IDREFException
- is thrown if the lookup fails to find the tag
and the element parameter has an idref attribute.
java.lang.Exception
public static int typeAssociationEndAggregate(org.w3c.dom.Element associationEndElement) throws java.lang.Exception
associationEndElement:
- the association end element tree.
java.lang.Exception
public static boolean isAssociationEndNavigable(org.w3c.dom.Element associationEndElement) throws java.lang.Exception
associationEndElement:
- the association end element tree.
java.lang.Exception
public static boolean isAssociationEndOrdered(org.w3c.dom.Element associationEndElement) throws java.lang.Exception
associationEndElement:
- the association end element tree.
java.lang.Exception
public static boolean isIdentifiable(org.w3c.dom.Element myclass) throws java.lang.Exception
myclass:
- the element which we wish to check.
java.lang.Exception
public static void setIdentifiable(org.w3c.dom.Element myclass, boolean value) throws java.lang.Exception
myclass:
- the element which we wish to identify
value:
- whether or not it is true or false.
java.lang.Exception
public static void setIdentifiable(org.w3c.dom.Element myclass, java.lang.String value) throws java.lang.Exception
myclass:
- the element which we wish to identify
value:
- whether or not it is true or false.
java.lang.Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |