Package org.jgrapht.io
Class DIMACSExporter<V,E>
- java.lang.Object
-
- org.jgrapht.io.DIMACSExporter<V,E>
-
- Type Parameters:
V
- the graph vertex typeE
- the graph edge type
- All Implemented Interfaces:
GraphExporter<V,E>
@Deprecated public class DIMACSExporter<V,E> extends Object implements GraphExporter<V,E>
Deprecated.In favor ofDIMACSImporter
.Exports a graph into DIMACS format.For a description of the format see http://dimacs.rutgers.edu/Challenges. Note that there are a lot of different formats based on each different challenge, see
DIMACSFormat
for the supported formats. The exporter uses theDIMACSFormat.MAX_CLIQUE
by default.- Author:
- Dimitrios Michail
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
DIMACSExporter.Parameter
Deprecated.Parameters that affect the behavior of theDIMACSExporter
exporter.
-
Field Summary
Fields Modifier and Type Field Description static DIMACSFormat
DEFAULT_DIMACS_FORMAT
Deprecated.The default format used by the exporter.protected ComponentNameProvider<E>
edgeIDProvider
Deprecated.Provides an identifier for an edge.protected ComponentNameProvider<V>
vertexIDProvider
Deprecated.Provides an identifier for a vertex.
-
Constructor Summary
Constructors Constructor Description DIMACSExporter()
Deprecated.Constructs a new exporter.DIMACSExporter(ComponentNameProvider<V> vertexIDProvider)
Deprecated.Constructs a new exporter with a given vertex ID provider.DIMACSExporter(ComponentNameProvider<V> vertexIDProvider, DIMACSFormat format)
Deprecated.Constructs a new exporter with a given vertex ID provider.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
exportGraph(Graph<V,E> g, Writer writer)
Deprecated.Export a graphComponentNameProvider<E>
getEdgeIDProvider()
Deprecated.Get the edge id providerDIMACSFormat
getFormat()
Deprecated.Get the format of the exporterComponentNameProvider<V>
getVertexIDProvider()
Deprecated.Get the vertex id providerboolean
isParameter(DIMACSExporter.Parameter p)
Deprecated.Return if a particular parameter of the exporter is enabledvoid
setEdgeIDProvider(ComponentNameProvider<E> edgeIDProvider)
Deprecated.Set the edge id provider.void
setFormat(DIMACSFormat format)
Deprecated.Set the format of the exportervoid
setParameter(DIMACSExporter.Parameter p, boolean value)
Deprecated.Set the value of a parameter of the exportervoid
setVertexIDProvider(ComponentNameProvider<V> vertexIDProvider)
Deprecated.Set the vertex id provider-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.jgrapht.io.GraphExporter
exportGraph, exportGraph
-
-
-
-
Field Detail
-
DEFAULT_DIMACS_FORMAT
public static final DIMACSFormat DEFAULT_DIMACS_FORMAT
Deprecated.The default format used by the exporter.
-
vertexIDProvider
protected ComponentNameProvider<V> vertexIDProvider
Deprecated.Provides an identifier for a vertex.
-
edgeIDProvider
protected ComponentNameProvider<E> edgeIDProvider
Deprecated.Provides an identifier for an edge.
-
-
Constructor Detail
-
DIMACSExporter
public DIMACSExporter()
Deprecated.Constructs a new exporter.
-
DIMACSExporter
public DIMACSExporter(ComponentNameProvider<V> vertexIDProvider)
Deprecated.Constructs a new exporter with a given vertex ID provider.- Parameters:
vertexIDProvider
- for generating vertex IDs. Must not be null.
-
DIMACSExporter
public DIMACSExporter(ComponentNameProvider<V> vertexIDProvider, DIMACSFormat format)
Deprecated.Constructs a new exporter with a given vertex ID provider.- Parameters:
vertexIDProvider
- for generating vertex IDs. Must not be null.format
- the format to use
-
-
Method Detail
-
exportGraph
public void exportGraph(Graph<V,E> g, Writer writer)
Deprecated.Export a graph- Specified by:
exportGraph
in interfaceGraphExporter<V,E>
- Parameters:
g
- the graph to exportwriter
- the output writer
-
isParameter
public boolean isParameter(DIMACSExporter.Parameter p)
Deprecated.Return if a particular parameter of the exporter is enabled- Parameters:
p
- the parameter- Returns:
true
if the parameter is set,false
otherwise
-
setParameter
public void setParameter(DIMACSExporter.Parameter p, boolean value)
Deprecated.Set the value of a parameter of the exporter- Parameters:
p
- the parametervalue
- the value to set
-
getFormat
public DIMACSFormat getFormat()
Deprecated.Get the format of the exporter- Returns:
- the format of the exporter
-
setFormat
public void setFormat(DIMACSFormat format)
Deprecated.Set the format of the exporter- Parameters:
format
- the format to use
-
getVertexIDProvider
public ComponentNameProvider<V> getVertexIDProvider()
Deprecated.Get the vertex id provider- Returns:
- the vertex id provider
-
setVertexIDProvider
public void setVertexIDProvider(ComponentNameProvider<V> vertexIDProvider)
Deprecated.Set the vertex id provider- Parameters:
vertexIDProvider
- the new vertex id provider. Must not be null.
-
getEdgeIDProvider
public ComponentNameProvider<E> getEdgeIDProvider()
Deprecated.Get the edge id provider- Returns:
- The edge provider
-
setEdgeIDProvider
public void setEdgeIDProvider(ComponentNameProvider<E> edgeIDProvider)
Deprecated.Set the edge id provider.- Parameters:
edgeIDProvider
- the new edge id provider. Must not be null.
-
-