Examples of Edge


Examples of org.apache.flink.examples.java.graph.util.EnumTrianglesDataTypes.Edge

     
      // clear vertex list
      vertices.clear();
     
      // read first edge
      Edge firstEdge = edges.next();
      outTriad.setFirstVertex(firstEdge.getFirstVertex());
      vertices.add(firstEdge.getSecondVertex());
     
      // build and emit triads
      while (edges.hasNext()) {
        Integer higherVertexId = edges.next().getSecondVertex();
       
View Full Code Here

Examples of org.apache.giraph.edge.Edge

    throws IOException, InterruptedException {

    TaskAttemptContext tac = mock(TaskAttemptContext.class);
    when(tac.getConfiguration()).thenReturn(conf);

    Edge edge = mock(Edge.class);

    when(edge.getTargetVertexId()).thenReturn(new LongWritable(1));
    when(edge.getValue()).thenReturn(new LongWritable(5));

    final RecordWriter<Text, Text> tw = mock(RecordWriter.class);
    SrcIdDstIdEdgeValueEdgeWriter writer = new SrcIdDstIdEdgeValueEdgeWriter() {
      @Override
      protected RecordWriter<Text, Text> createLineRecordWriter(
View Full Code Here

Examples of org.apache.openjpa.lib.graph.Edge

        graph.addNode(row2);

        // add an edge from row1 to row2, and set the fk causing the
        // dependency as the user object so we can retrieve it when resolving
        // circular constraints
        Edge edge = new Edge(row1, row2, true);
        edge.setUserObject(fk);
        graph.addEdge(edge);

        return graph;
    }
View Full Code Here

Examples of org.apache.tez.dag.api.Edge

        workToConf.put(w, wxConf);
       
        // add all dependencies (i.e.: edges) to the graph
        for (BaseWork v: work.getChildren(w)) {
          assert workToVertex.containsKey(v);
          Edge e = null;

          TezEdgeProperty edgeProp = work.getEdgeProperty(w, v);

          e = utils.createEdge(wxConf, wx, workToConf.get(v), workToVertex.get(v), edgeProp);
          dag.addEdge(e);
View Full Code Here

Examples of org.apache.tuscany.core.databinding.impl.DirectedGraph.Edge

        Assert.assertNotNull(vertex);
        Assert.assertEquals(vertex.getValue(), "a");

        Assert.assertNull(graph.getVertex("1"));

        Edge edge = graph.getEdge("a", "b");
        Assert.assertNotNull(edge);
        Assert.assertEquals(edge.getWeight(), 3);

        edge = graph.getEdge("b", "a");
        Assert.assertNull(edge);

        DirectedGraph<String, Object>.Path path = graph.getShortestPath("a", "c");
View Full Code Here

Examples of org.apache.tuscany.sca.databinding.impl.DirectedGraph.Edge

        Assert.assertNotNull(vertex);
        Assert.assertEquals(vertex.getValue(), "a");

        Assert.assertNull(graph.getVertex("1"));

        Edge edge = graph.getEdge("a", "b");
        Assert.assertNotNull(edge);
        Assert.assertEquals(edge.getWeight(), 3);

        edge = graph.getEdge("b", "a");
        Assert.assertNull(edge);

        DirectedGraph<String, Object>.Path path = graph.getShortestPath("a", "c");
View Full Code Here

Examples of org.boris.expr.graph.Edge

    private void addDependencies(Range source, Range target)
            throws GraphCycleException {
        if (source.isArray()) {
            Range[] r = source.split();
            for (Range rs : r) {
                graph.add(new Edge(rs, target));
            }
        } else {
            graph.add(new Edge(source, target));
        }
    }
View Full Code Here

Examples of org.codehaus.plexus.graph.Edge

        visitor.discoverVertex( v );

        Iterator edges = graph.getOutbound( v ).iterator();
        while ( edges.hasNext() )
        {
            Edge e = (Edge) edges.next();
            visitEdge( graph, e, visitor );
        }

        visitor.finishVertex( v );
View Full Code Here

Examples of org.drools.examples.benchmarks.waltz.model.Edge

        {
            ++lineCount;
        }
        else if ( object instanceof Edge )
        {
            Edge edge = ( Edge ) object;
            if ( edge.isJoined( ) )
            {
                ++joinedEdgeCount;
            }
            if ( edge.isPlotted( ) )
            {
                ++plottedEdgeCount;
            }
            edgeSet.add( edge.getP1( ) + ":" + edge.getP2( ) );
        }
        else if ( object instanceof Junction )
        {
            Junction junction = ( Junction ) object;
            int basePoint = junction.getBasePoint( );
View Full Code Here

Examples of org.eclipse.dd.di.Edge

            if (result == null)
                result = defaultCase(theEObject);
            return result;
        }
        case DiPackage.EDGE: {
            Edge edge = (Edge) theEObject;
            T result = caseEdge(edge);
            if (result == null)
                result = caseDiagramElement(edge);
            if (result == null)
                result = defaultCase(theEObject);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.