Package com.nuix.nx.sourceitem
Class SourceItemVisitor
- java.lang.Object
-
- com.nuix.nx.sourceitem.SourceItemVisitor
-
public class SourceItemVisitor extends java.lang.ObjectA helper class for visiting all items recursively in a tree of source items.
-
-
Constructor Summary
Constructors Constructor Description SourceItemVisitor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidonVisit(SourceItemVisitCallback callback)Provides a callback which will be called once for each source item located.protected voidrecursivelyVisit(nuix.SourceItem sourceItem)Recursively visits source items and their children unless callback specifies skipping children for a given source item.voidvisit(java.io.File file, java.util.Map<?,?> sourceItemFactorySettings, java.util.Map<?,?> fileSettings)Creates a SourceItemFactory and begins recursing the source item tree for the provided file.voidvisit(java.lang.String file, java.util.Map<?,?> sourceItemFactorySettings, java.util.Map<?,?> fileSettings)Creates a SourceItemFactory and begins recursing the source item tree for the provided file.
-
-
-
Method Detail
-
onVisit
public void onVisit(SourceItemVisitCallback callback)
Provides a callback which will be called once for each source item located.- Parameters:
callback- A callback which will be invoked each time a source item is visited.
-
visit
public void visit(java.io.File file, java.util.Map<?,?> sourceItemFactorySettings, java.util.Map<?,?> fileSettings) throws java.io.FileNotFoundExceptionCreates a SourceItemFactory and begins recursing the source item tree for the provided file.- Parameters:
file- The file to recurse.sourceItemFactorySettings- Settings you might provide to a call to Utilities.getSourceItemFactory, can be null to use defaultsfileSettings- Settings you might provide to a call to SourceItemFactory.openFile, can be null to use defaults- Throws:
java.io.FileNotFoundException- Thrown by SourceItemFactory if the provided file does not exist.
-
visit
public void visit(java.lang.String file, java.util.Map<?,?> sourceItemFactorySettings, java.util.Map<?,?> fileSettings) throws java.io.FileNotFoundExceptionCreates a SourceItemFactory and begins recursing the source item tree for the provided file.- Parameters:
file- The file to recurse.sourceItemFactorySettings- Settings you might provide to a call to Utilities.getSourceItemFactory, can be null to use defaultsfileSettings- Settings you might provide to a call to SourceItemFactory.openFile, can be null to use defaults- Throws:
java.io.FileNotFoundException- Thrown by SourceItemFactory if the provided file does not exist.
-
recursivelyVisit
protected void recursivelyVisit(nuix.SourceItem sourceItem)
Recursively visits source items and their children unless callback specifies skipping children for a given source item.- Parameters:
sourceItem- The source item to visit and potentially recursively visit children of.
-
-