public class GraphVisitorDFS<T> extends Object implements GraphVisitor<T>
Constructor and Description |
---|
GraphVisitorDFS(Collection<? extends T> first,
BinaryProcedure<T,GraphVisitor<T>> callee) |
GraphVisitorDFS(T first,
BinaryProcedure<T,GraphVisitor<T>> callee) |
Modifier and Type | Method and Description |
---|---|
void |
abort() |
void |
enqueue(Collection<? extends T> next) |
void |
enqueue(T next) |
Collection<T> |
getVisitedNodes() |
void |
process() |
boolean |
wasAborted() |
public GraphVisitorDFS(T first, BinaryProcedure<T,GraphVisitor<T>> callee)
public GraphVisitorDFS(Collection<? extends T> first, BinaryProcedure<T,GraphVisitor<T>> callee)
public void enqueue(T next)
enqueue
in interface GraphVisitor<T>
public void enqueue(Collection<? extends T> next)
enqueue
in interface GraphVisitor<T>
public void abort()
abort
in interface GraphVisitor<T>
public boolean wasAborted()
wasAborted
in interface GraphVisitor<T>
public Collection<T> getVisitedNodes()
getVisitedNodes
in interface GraphVisitor<T>
public void process()
process
in interface GraphVisitor<T>
Copyright © 2011-2021. All Rights Reserved.