|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.xml.sax.helpers.DefaultHandler
be.ac.vub.cocompose.io.xmi.XMIModelReader
Reads a CoCompose model from an XMI file (requires second pass by XMIModelLinkReader).
Constructor Summary | |
XMIModelReader()
|
Method Summary | |
void |
characters(char[] ch,
int start,
int length)
Characters. |
void |
endCoComposeElement(String local)
Start CoCompose element. |
void |
endElement(String uri,
String local,
String raw)
End element. |
void |
endOwnedElement()
Finalises an ownedElement tag |
void |
endXMIElement(String local)
End XMI element. |
void |
ignorableWhitespace(char[] ch,
int start,
int length)
Ignorable whitespace. |
void |
notationDecl(String name,
String publicId,
String systemId)
DTD declaration. |
void |
processingInstruction(String target,
String data)
Processing instruction. |
Model |
read(String uri,
ModelFactory factory)
Reads the model from its uri. |
void |
startCoComposeElement(String local,
Attributes attrs)
Start CoCompose element. |
void |
startColor(Attributes attrs)
Parses a color tag |
void |
startDocument()
Start document. |
void |
startElement(String uri,
String local,
String raw,
Attributes attrs)
Start element. |
void |
startOwnedElement(Attributes attrs)
Parses an ownedElement tag |
void |
startPosition(Attributes attrs)
Parses a position tag |
void |
startXMIElement(String local,
Attributes attrs)
Start XMI element. |
Methods inherited from class org.xml.sax.helpers.DefaultHandler |
endDocument, endPrefixMapping, error, fatalError, resolveEntity, setDocumentLocator, skippedEntity, startPrefixMapping, unparsedEntityDecl, warning |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public XMIModelReader()
Method Detail |
public Model read(String uri, ModelFactory factory) throws IOException, ModelElementException
read
in interface ModelReader
uri
- - the uri to read from.factory
- - the model factory used to create the elements.
IOException
- - if the model could not be read.
ModelElementException
- - if a model element could not be read.public void processingInstruction(String target, String data) throws SAXException
processingInstruction
in interface ContentHandler
target
- Processing instruction element name.data
- Processing instruction element data.
SAXException
public void startDocument() throws SAXException
startDocument
in interface ContentHandler
SAXException
public void startElement(String uri, String local, String raw, Attributes attrs) throws SAXException
startElement
in interface ContentHandler
uri
- XML namespace URI.local
- local element name.raw
- raw (qualified) element name.attrs
- element attributes.
SAXException
public void startXMIElement(String local, Attributes attrs) throws SAXException
local
- local element name.attrs
- element attributes.
SAXException
public void startCoComposeElement(String local, Attributes attrs) throws SAXException
local
- local element name.attrs
- element attributes.
SAXException
public void startOwnedElement(Attributes attrs) throws ModelElementException
attrs
- element attributes
ModelElementException
public void endOwnedElement() throws ModelElementException
ModelElementException
public void startPosition(Attributes attrs) throws ModelElementException
attrs
- element attributes
ModelElementException
public void startColor(Attributes attrs) throws ModelElementException
attrs
- element attributes
ModelElementException
public void characters(char[] ch, int start, int length) throws SAXException
characters
in interface ContentHandler
ch
- Characters to print.start
- Starting index of characters.length
- Length of characters.
SAXException
public void ignorableWhitespace(char[] ch, int start, int length) throws SAXException
ignorableWhitespace
in interface ContentHandler
ch
- Characters to print.start
- Starting index of characters.length
- Length of characters.
SAXException
public void endElement(String uri, String local, String raw) throws SAXException
endElement
in interface ContentHandler
uri
- Ignored.local
- Ignored.raw
- Element name.
SAXException
public void endXMIElement(String local) throws SAXException
local
- local element name.
SAXException
public void endCoComposeElement(String local) throws SAXException
local
- local element name.
SAXException
public void notationDecl(String name, String publicId, String systemId) throws SAXException
notationDecl
in interface DTDHandler
name
- DTD name.publicId
- DTD public ID.systemId
- DTD system ID.
SAXException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |