public abstract class SingleConfigurableTask extends Object implements ConfigurableTask
| Modifier and Type | Class and Description |
|---|---|
static class |
SingleConfigurableTask.Entry
Instance of this class represents nested elements of a task configuration file.
|
static class |
SingleConfigurableTask.Unit |
| Modifier and Type | Field and Description |
|---|---|
protected Configurable |
configurable |
protected boolean |
createConfigurable |
protected Configurable |
fromConfigurable |
| Constructor and Description |
|---|
SingleConfigurableTask() |
| Modifier and Type | Method and Description |
|---|---|
void |
addEntry(SingleConfigurableTask.Entry entry) |
protected abstract void |
checkAttributes() |
void |
execute() |
protected abstract void |
readConfigurable() |
protected abstract void |
readSourceConfigurable() |
void |
setAutoNumbering(boolean autoNumbering)
Whether to use property auto numbering (for property names
with a trailing '.')
|
void |
setCreate(boolean create)
Whether the configuration file or registry root entry should be created if it doesn't already
exist (default: true).
|
void |
setEmptyLines(boolean emptyLines)
Whether to preserve empty lines
|
void |
setEncoding(Charset encoding)
The encoding to be used for loading and saving configuration files
|
void |
setEscape(boolean escape)
Whether to accept escape sequences
|
void |
setEscapeNewLine(boolean escapeNewLine)
Whether to interpret escape at the end of line for joining lines
|
void |
setHeaderComment(boolean headerComment)
Whether to use header comments
|
void |
setOperator(String operator)
The operator to use for separating name and value
|
void |
setPatchPreserveEntries(boolean preserveEntries)
Whether to preserve equal entries but not necessarily their values from an old configuration,
if they can be found (default: true).
|
void |
setPatchPreserveValues(boolean preserveValues)
Whether to preserve the values of equal entries from an old configuration, if they can be
found (default: true).
|
void |
setPatchResolveVariables(boolean resolve)
Whether variables should be resolved during patching.
|
protected abstract void |
writeConfigurable() |
protected boolean createConfigurable
protected Configurable configurable
protected Configurable fromConfigurable
public void setPatchPreserveEntries(boolean preserveEntries)
preserveEntries - - true to preserve equal entries from an old configurationpublic void setPatchPreserveValues(boolean preserveValues)
preserveValues - - true to preserve the values of equal entries from an old
configurationpublic void setPatchResolveVariables(boolean resolve)
resolve - - true to resolve in-value variablespublic void setEscape(boolean escape)
escape - - true to resolve escape sequencespublic void setEscapeNewLine(boolean escapeNewLine)
escapeNewLine - - true to interpret escape at the end of line for joining linespublic void setHeaderComment(boolean headerComment)
headerComment - - true to use header commentspublic void setEmptyLines(boolean emptyLines)
emptyLines - - true to preserve empty linespublic void setAutoNumbering(boolean autoNumbering)
autoNumbering - - true to use property auto numberingpublic void setOperator(String operator)
operator - - an operator stringpublic void setEncoding(Charset encoding)
encoding - - an encoding stringpublic void setCreate(boolean create)
create - - whether to create a new configuration file or registry root entrypublic void execute()
throws Exception
execute in interface ConfigurableTaskExceptionprotected abstract void readSourceConfigurable()
throws Exception
Exceptionpublic void addEntry(SingleConfigurableTask.Entry entry)
Copyright © 2001–2025. All rights reserved.