Class ScriptTemplatesConfig
-
- All Implemented Interfaces:
public final class ScriptTemplatesConfigSettings-group for the start- and java-script-templates used during server pack generation: the per-type template-maps stored under prefixed property-keys, their defaults inside the server_files-directory, and the deprecated list-based template-handling. Extracted from ApiProperties (refactor Phase 1b); ApiProperties remains the facade through which consumers access these values.
-
-
Field Summary
Fields Modifier and Type Field Description public final static StringSTART_SCRIPT_TEMPLATES_PREFIXpublic final static StringJAVA_SCRIPT_TEMPLATES_PREFIXpublic final static StringLEGACY_SCRIPT_TEMPLATES_KEYprivate TreeSet<File>scriptTemplatesprivate HashMap<String, String>startScriptTemplatesprivate HashMap<String, String>javaScriptTemplates
-
Constructor Summary
Constructors Constructor Description ScriptTemplatesConfig(PropertyStore store, PathsConfig paths)
-
Method Summary
Modifier and Type Method Description final TreeSet<File>getScriptTemplates()The start-script templates generation will use. final UnitsetScriptTemplates(TreeSet<File> value)The start-script templates generation will use. final HashMap<String, String>getStartScriptTemplates()Start-script templates to use during server pack generation. final UnitsetStartScriptTemplates(HashMap<String, String> map)Start-script templates to use during server pack generation. final HashMap<String, String>getJavaScriptTemplates()Start-script templates to use during server pack generation. final UnitsetJavaScriptTemplates(HashMap<String, String> map)Start-script templates to use during server pack generation. final List<File>defaultScriptTemplates()Default list of script templates used by ServerPackCreator. final HashMap<String, String>defaultStartScriptTemplates()Default map of start-script templates: sh, ps1, bat. final HashMap<String, String>defaultJavaScriptTemplates()Default map of start-script templates: sh, ps1, bat. -
-
Constructor Detail
-
ScriptTemplatesConfig
ScriptTemplatesConfig(PropertyStore store, PathsConfig paths)
-
-
Method Detail
-
getScriptTemplates
final TreeSet<File> getScriptTemplates()
The start-script templates generation will use. Sorted, so generated packs are reproducible.
Reads the equally-deprecated defaultScriptTemplates on purpose: both belong to the pre-6.0.0 flat-list representation, and this accessor exists to keep answering in that representation for callers who have not moved to startScriptTemplates yet. Delegating to the replacement instead would change what it returns, which is the one thing a deprecated facade must not do.
-
setScriptTemplates
final Unit setScriptTemplates(TreeSet<File> value)
The start-script templates generation will use. Sorted, so generated packs are reproducible.
Reads the equally-deprecated defaultScriptTemplates on purpose: both belong to the pre-6.0.0 flat-list representation, and this accessor exists to keep answering in that representation for callers who have not moved to startScriptTemplates yet. Delegating to the replacement instead would change what it returns, which is the one thing a deprecated facade must not do.
-
getStartScriptTemplates
final HashMap<String, String> getStartScriptTemplates()
Start-script templates to use during server pack generation. Each key represents a different template and script-type.
-
setStartScriptTemplates
final Unit setStartScriptTemplates(HashMap<String, String> map)
Start-script templates to use during server pack generation. Each key represents a different template and script-type.
-
getJavaScriptTemplates
final HashMap<String, String> getJavaScriptTemplates()
Start-script templates to use during server pack generation. Each key represents a different template and script-type.
-
setJavaScriptTemplates
final Unit setJavaScriptTemplates(HashMap<String, String> map)
Start-script templates to use during server pack generation. Each key represents a different template and script-type.
-
defaultScriptTemplates
@Deprecated(message = "Deprecated as of 6.0.0", replaceWith = @ReplaceWith(expression = "defaultScriptTemplateMap")) final List<File> defaultScriptTemplates()
Default list of script templates used by ServerPackCreator.
-
defaultStartScriptTemplates
final HashMap<String, String> defaultStartScriptTemplates()
Default map of start-script templates: sh, ps1, bat.
-
defaultJavaScriptTemplates
final HashMap<String, String> defaultJavaScriptTemplates()
Default map of start-script templates: sh, ps1, bat.
-
-
-
-