com.intel.hadoop.graphbuilder.graph
Interface GraphOutput

All Known Implementing Classes:
GLGraphOutput, SimpleGraphOutput

public interface GraphOutput

Controls the high level output logic of a graph, including initializing, finalizing the Hadoop IO objects, and configuring the output directory. The output only writes out the local part of the graph (the edges) and does not write the vertex record information. This is because the ingress of edges and vertices are separate processes.


Method Summary
 void close()
          Close the output.
 void configure(org.apache.hadoop.mapred.JobConf conf)
          Configure this GraphOutput using JobConf.
 void init(org.apache.hadoop.mapred.JobConf conf)
          Set the OutputFormat in the JobConf.
 void write(Graph g, EdgeFormatter formatter, org.apache.hadoop.mapred.OutputCollector out, org.apache.hadoop.mapred.Reporter reporter)
          Write out the graph to the OutputCollector.
 void writeAndClear(Graph g, EdgeFormatter formatter, org.apache.hadoop.mapred.OutputCollector out, org.apache.hadoop.mapred.Reporter reporter)
          Write out the graph and clearing the fields written to free up memory.
 

Method Detail

init

void init(org.apache.hadoop.mapred.JobConf conf)
Set the OutputFormat in the JobConf.

Parameters:
conf -

configure

void configure(org.apache.hadoop.mapred.JobConf conf)
Configure this GraphOutput using JobConf.

Parameters:
conf -

write

void write(Graph g,
           EdgeFormatter formatter,
           org.apache.hadoop.mapred.OutputCollector out,
           org.apache.hadoop.mapred.Reporter reporter)
           throws java.lang.Exception
Write out the graph to the OutputCollector.

Parameters:
g - the graph to output.
formatter - formatter for the graph string representation.
out -
reporter -
Throws:
java.lang.Exception

writeAndClear

void writeAndClear(Graph g,
                   EdgeFormatter formatter,
                   org.apache.hadoop.mapred.OutputCollector out,
                   org.apache.hadoop.mapred.Reporter reporter)
                   throws java.lang.Exception
Write out the graph and clearing the fields written to free up memory.

Parameters:
g - the graph to output.
formatter - formatter of the graph string representation.
out -
reporter -
Throws:
java.io.IOException
java.lang.Exception

close

void close()
           throws java.io.IOException
Close the output.

Throws:
java.io.IOException