Class CheckHelper.Builder
- java.lang.Object
-
- org.apache.jackrabbit.oak.segment.tool.check.CheckHelper.Builder
-
- Enclosing class:
- CheckHelper
public static class CheckHelper.Builder extends Object
Collect options for theCheckcommand.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CheckHelperbuild()Create an executable version of theCheckHelpercommand.CheckHelper.BuilderwithCheckBinaries(boolean checkBinaries)Instruct the command to scan the full content of binary properties.CheckHelper.BuilderwithCheckHead(boolean checkHead)Instruct the command to check head state.CheckHelper.BuilderwithCheckpoints(Set<String> checkpoints)Instruct the command to check specified checkpoints.CheckHelper.BuilderwithDebugInterval(long debugInterval)Number of seconds between successive debug print statements.CheckHelper.BuilderwithErrWriter(PrintWriter errWriter)The text error stream writer used to print erroneous output.CheckHelper.BuilderwithFailFast(boolean failFast)CheckHelper.BuilderwithFilterPaths(Set<String> filterPaths)Content paths to be checked.CheckHelper.BuilderwithOutWriter(PrintWriter outWriter)The text output stream writer used to print normal output.CheckHelper.BuilderwithRevisionsCount(Integer revisionsCount)Instruct the command to check only the lastrevisionsCountrevisions.
-
-
-
Method Detail
-
withDebugInterval
public CheckHelper.Builder withDebugInterval(long debugInterval)
Number of seconds between successive debug print statements. This parameter is not required and defaults to an arbitrary large number.- Parameters:
debugInterval- number of seconds between successive debug print statements. It must be positive.- Returns:
- this builder.
-
withCheckBinaries
public CheckHelper.Builder withCheckBinaries(boolean checkBinaries)
Instruct the command to scan the full content of binary properties. This parameter is not required and defaults tofalse.- Parameters:
checkBinaries-trueif binary properties should be scanned,falseotherwise.- Returns:
- this builder.
-
withCheckHead
public CheckHelper.Builder withCheckHead(boolean checkHead)
Instruct the command to check head state. This parameter is not required and defaults totrue.- Parameters:
checkHead- iftrue, will check the head state.- Returns:
- this builder.
-
withRevisionsCount
public CheckHelper.Builder withRevisionsCount(Integer revisionsCount)
Instruct the command to check only the lastrevisionsCountrevisions. This parameter is not required and defaults to1.- Parameters:
revisionsCount- number of revisions to check.- Returns:
- this builder.
-
withCheckpoints
public CheckHelper.Builder withCheckpoints(Set<String> checkpoints)
Instruct the command to check specified checkpoints. This parameter is not required and defaults to "/checkpoints", i.e. will check all checkpoints when not explicitly overridden.- Parameters:
checkpoints- checkpoints to be checked- Returns:
- this builder.
-
withFilterPaths
public CheckHelper.Builder withFilterPaths(Set<String> filterPaths)
Content paths to be checked. This parameter is not required and defaults to "/".- Parameters:
filterPaths- paths to be checked- Returns:
- this builder.
-
withOutWriter
public CheckHelper.Builder withOutWriter(PrintWriter outWriter)
The text output stream writer used to print normal output.- Parameters:
outWriter- the output writer.- Returns:
- this builder.
-
withErrWriter
public CheckHelper.Builder withErrWriter(PrintWriter errWriter)
The text error stream writer used to print erroneous output.- Parameters:
errWriter- the error writer.- Returns:
- this builder.
-
withFailFast
public CheckHelper.Builder withFailFast(boolean failFast)
-
build
public CheckHelper build()
Create an executable version of theCheckHelpercommand.- Returns:
- an instance of
CheckHelper.
-
-