Package com.intel.hadoop.graphbuilder.graph

Examples of com.intel.hadoop.graphbuilder.graph.Vertex


        mapVal.init(VertexEdgeUnionType.EDGEVAL, e);
        out.collect(new IntWritable(e.hashCode()), mapVal);
      }

      while (viter.hasNext()) {
        Vertex v = viter.next();
        mapVal.init(VertexEdgeUnionType.VERTEXVAL, v);
        out.collect(new IntWritable(v.hashCode()), mapVal);
      }
    } catch (Exception e) {
      e.printStackTrace();
    }
  }
View Full Code Here


  public void reduce(IntWritable key, Iterator<Text> iter,
      OutputCollector<Text, Text> out, Reporter reporter) throws IOException {
    long baseid = key.get();
    int split = 0;
    while (iter.hasNext()) {
      Vertex v = graphparser.parseVertex(iter.next().toString(), vidparser,
          vdataparser);
      long newId = baseid + splitsize * split;
      out.collect(new Text("vidmap"), new Text(newId + "\t" + v.vid()));
      out.collect(new Text("vdata"), new Text("!" + newId + "\t"
          + v.vdata().toString()));
      split++;
    }
  }
View Full Code Here

TOP

Related Classes of com.intel.hadoop.graphbuilder.graph.Vertex

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.