Commons Sandbox
  1. Commons Sandbox
  2. SANDBOX-372

Make the org.apache.commons.graph.visit.GraphVisitHandler able to return objects

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Graph
    • Labels:
      None

      Description

      Graph visit could produce output objects, taking inspiration form DbUtil's ResultSetHandler and AsyncHttpClient's AsyncHandler it would be possible invoke:

      final List<V> visited = visit( inputGraph ).from( startVertex ).applyingDepthFirstSearch( new MyHandler() );
      

      just adding a callback method in GraphVisitHandler, something like:

      public interface GraphVisitHandler<V extends Vertex, E extends Edge, G extends Graph<V, E>, O>
      {
      
          [...]
      
          O onCompleted();
      
      }
      

        Activity

        Simone Tripodi created issue -
        Hide
        Simone Tripodi added a comment -

        fixed on trunk, see r1237632

        Show
        Simone Tripodi added a comment - fixed on trunk, see r1237632
        Simone Tripodi made changes -
        Field Original Value New Value
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]

          People

          • Assignee:
            Simone Tripodi
            Reporter:
            Simone Tripodi
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development