public class XMLTopologySerializer extends Object implements TopologySerializer
Constructor and Description |
---|
XMLTopologySerializer(boolean validateDocument) |
Modifier and Type | Method and Description |
---|---|
String |
exportToString(Topology topology)
Returns a string representation of this topology.
|
void |
importFromString(Topology topology,
String data)
Imports nodes and wired links from the specified string representation of a
topology.
|
public String exportToString(Topology topology)
TopologySerializer
TopologySerializer.importFromString(Topology, String)
method. Only the nodes and wired links are exported
here (not the topology's properties).exportToString
in interface TopologySerializer
topology
- The Topology
object which must be exportedString
representation of the Topology
public void importFromString(Topology topology, String data)
TopologySerializer
importFromString
in interface TopologySerializer
topology
- The Topology
object which must be populateddata
- The String
representation.