super(topologyFactory, assemblyFactory, extensionProcessor);
}
public Runtime read(XMLStreamReader reader) throws ContributionReadException, XMLStreamException {
QName name = null;
Runtime runtime = null;
Node node = null;
String domainName = DEFAULT_DOMAIN;
// Read the composite document
while (reader.hasNext()) {
int event = reader.getEventType();
switch (event) {
case START_ELEMENT:
name = reader.getName();
if (RUNTIME_QNAME.equals(name)) {
// Read a <runtime>
runtime = topologyFactory.createRuntime();
} else if (NODE_QNAME.equals(name)) {
// Read a <node>
node = topologyFactory.createNode();
node.setName(getString(reader, NAME));
// add node to runtime
runtime.getNodes().add(node);
// reset domain name to the default
domainName = DEFAULT_DOMAIN;
} else if (DOMAIN_QNAME.equals(name)) {
// Read a <domain>