de.cesr.more.util.io
Class MGraphMLReaderWithEdges<G extends Hypergraph<V,E>,V,E>

java.lang.Object
  extended by org.xml.sax.helpers.DefaultHandler
      extended by edu.uci.ics.jung.io.GraphMLReader<G,V,E>
          extended by de.cesr.more.util.io.MGraphMLReaderWithEdges<G,V,E>
Type Parameters:
G - Graph Type
V - Vertex Type
E - Edge Type
All Implemented Interfaces:
ContentHandler, DTDHandler, EntityResolver, ErrorHandler

public class MGraphMLReaderWithEdges<G extends Hypergraph<V,E>,V,E>
extends GraphMLReader<G,V,E>

MORe Creates a new MoreNetwork using the factories. For edges, source and target informations is derived from the GraphML file.

Date:
06.10.2010

Nested Class Summary
 
Nested classes/interfaces inherited from class edu.uci.ics.jung.io.GraphMLReader
GraphMLReader.KeyType, GraphMLReader.TagState
 
Field Summary
protected  MoreEdgeFactory<V,E> edgeFactory
          An MoreEdgeFactory that is used to create edge objects
 
Fields inherited from class edu.uci.ics.jung.io.GraphMLReader
current_edge, current_graph, current_key, current_states, current_text, current_vertex, default_edgetype, edge_desc, edge_factory, edge_ids, edge_metadata, graph_desc, graph_factory, graph_metadata, graphs, hyperedge_vertices, key_type, saxp, tag_state, vertex_desc, vertex_factory, vertex_ids, vertex_metadata
 
Constructor Summary
MGraphMLReaderWithEdges(org.apache.commons.collections15.Factory<V> vertex_factory, MoreEdgeFactory<V,E> edge_factory)
           
 
Method Summary
protected  void clearData()
          Passes contents of this#nodeMap to super#vertex_ids.
protected  void createEdge(Attributes atts, GraphMLReader.TagState state)
          Fetches information about source, target and direction from attributes to enable initialisation of and extended edge object.
protected  void createVertex(Attributes atts)
          Adapted to this application when vertex_ids is provided beforehand.
 
Methods inherited from class edu.uci.ics.jung.io.GraphMLReader
addDatum, addExtraData, assignEdgeSourceTarget, characters, createKey, endElement, getAttributeMap, getEdgeDescriptions, getEdgeIDs, getEdgeMetadata, getGraphDescriptions, getGraphMetadata, getVertexDescriptions, getVertexIDs, getVertexMetadata, handleData, initializeData, load, load, loadMultiple, loadMultiple, parse, startElement
 
Methods inherited from class org.xml.sax.helpers.DefaultHandler
endDocument, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setDocumentLocator, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

edgeFactory

protected MoreEdgeFactory<V,E> edgeFactory
An MoreEdgeFactory that is used to create edge objects

Constructor Detail

MGraphMLReaderWithEdges

public MGraphMLReaderWithEdges(org.apache.commons.collections15.Factory<V> vertex_factory,
                               MoreEdgeFactory<V,E> edge_factory)
                        throws ParserConfigurationException,
                               SAXException
Parameters:
vertex_factory -
edge_factory -
Throws:
ParserConfigurationException
SAXException
Method Detail

clearData

protected void clearData()
Passes contents of this#nodeMap to super#vertex_ids. superclearData() is called after superGraphMLReader.initializeData()...

Overrides:
clearData in class GraphMLReader<G extends Hypergraph<V,E>,V,E>
See Also:
GraphMLReader.clearData()

createEdge

protected void createEdge(Attributes atts,
                          GraphMLReader.TagState state)
                   throws SAXNotSupportedException
Fetches information about source, target and direction from attributes to enable initialisation of and extended edge object.

Overrides:
createEdge in class GraphMLReader<G extends Hypergraph<V,E>,V,E>
Throws:
SAXNotSupportedException
See Also:
GraphMLReader.createEdge(org.xml.sax.Attributes, edu.uci.ics.jung.io.GraphMLReader.TagState)

createVertex

protected void createVertex(Attributes atts)
                     throws SAXNotSupportedException
Adapted to this application when vertex_ids is provided beforehand.

Overrides:
createVertex in class GraphMLReader<G extends Hypergraph<V,E>,V,E>
Throws:
SAXNotSupportedException
See Also:
GraphMLReader.createVertex(org.xml.sax.Attributes)