Package qupath.lib.scripting
Class ScriptParameters.Builder
java.lang.Object
qupath.lib.scripting.ScriptParameters.Builder
- Enclosing class:
- ScriptParameters
Builder class for 
ScriptParameters.- 
Method SummaryModifier and TypeMethodDescriptionbuild()Build theScriptParameterswith the current options.doUpdateHierarchy(boolean requestUpdate) Optionally request a hierarchy update event after running a script (default is true for scripts that operate on image data).Set optional string args to pass to the script.setBatchIndex(int ind) Set the current image index for batch processing (default is 0).setBatchSaveResult(boolean doSave) Specify whether the script that is running should save results or not.setBatchSize(int batch) Set the batch size for batch processing (default is 1).setDefaultImports(Collection<Class<?>> imports) setDefaultStaticImports(Collection<Class<?>> imports) setErrorWriter(Writer writer) Set the main error writer.setImageData(ImageData<?> imageData) Set the current image data for the script.setProject(Project<?> project) Set the current project for the script.Set the output and error writers to useSystem.outandSystem.err.Set the main output writer.useCompiled(boolean useCompiled) Request that the script is compiled before being evaluated, or a previously compiled version is used where available.Set the output and error writers to append to the default logger.useLogWriters(org.slf4j.Logger logger) Set the output and error writers to append to the specified logger.
- 
Method Details- 
setDefaultImports
- 
setDefaultStaticImports
- 
setFile
- 
setScript
- 
setSystemWritersSet the output and error writers to useSystem.outandSystem.err.- Returns:
 
- 
useLogWritersSet the output and error writers to append to the specified logger.- Parameters:
- logger-
- Returns:
 
- 
useLogWritersSet the output and error writers to append to the default logger.- Returns:
 
- 
setWriterSet the main output writer.- Parameters:
- writer-
- Returns:
 
- 
setErrorWriterSet the main error writer.- Parameters:
- writer-
- Returns:
 
- 
setBatchSizeSet the batch size for batch processing (default is 1).- Parameters:
- batch-
- Returns:
 
- 
setBatchIndexSet the current image index for batch processing (default is 0).- Parameters:
- ind-
- Returns:
 
- 
setBatchSaveResultSpecify whether the script that is running should save results or not.- Parameters:
- doSave-
- Returns:
 
- 
setArgsSet optional string args to pass to the script.- Parameters:
- args-
- Returns:
 
- 
setProjectSet the current project for the script.- Parameters:
- project-
- Returns:
 
- 
setImageDataSet the current image data for the script.- Parameters:
- imageData-
- Returns:
 
- 
doUpdateHierarchyOptionally request a hierarchy update event after running a script (default is true for scripts that operate on image data).- Parameters:
- requestUpdate-
- Returns:
 
- 
useCompiledRequest that the script is compiled before being evaluated, or a previously compiled version is used where available.- Parameters:
- useCompiled-
- Returns:
 
- 
buildBuild theScriptParameterswith the current options.- Returns:
- Throws:
- IllegalArgumentException- if neither file nor script are set
 
 
-