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 theCheck
command.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CheckHelper
build()
Create an executable version of theCheckHelper
command.CheckHelper.Builder
withCheckBinaries(boolean checkBinaries)
Instruct the command to scan the full content of binary properties.CheckHelper.Builder
withCheckHead(boolean checkHead)
Instruct the command to check head state.CheckHelper.Builder
withCheckpoints(Set<String> checkpoints)
Instruct the command to check specified checkpoints.CheckHelper.Builder
withDebugInterval(long debugInterval)
Number of seconds between successive debug print statements.CheckHelper.Builder
withErrWriter(PrintWriter errWriter)
The text error stream writer used to print erroneous output.CheckHelper.Builder
withFailFast(boolean failFast)
CheckHelper.Builder
withFilterPaths(Set<String> filterPaths)
Content paths to be checked.CheckHelper.Builder
withOutWriter(PrintWriter outWriter)
The text output stream writer used to print normal output.CheckHelper.Builder
withRevisionsCount(Integer revisionsCount)
Instruct the command to check only the lastrevisionsCount
revisions.
-
-
-
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
-true
if binary properties should be scanned,false
otherwise.- 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 lastrevisionsCount
revisions. 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 theCheckHelper
command.- Returns:
- an instance of
CheckHelper
.
-
-