Package io.nosqlbench.engine.cli
Class BasicScriptBuffer
java.lang.Object
io.nosqlbench.engine.cli.BasicScriptBuffer
- All Implemented Interfaces:
ScriptBuffer
public class BasicScriptBuffer extends java.lang.Object implements ScriptBuffer
-
Constructor Summary
Constructors Constructor Description BasicScriptBuffer() -
Method Summary
Modifier and Type Method Description ScriptBufferadd(Cmd cmd)ScriptBufferadd(Cmd... cmds)Add parsed commands to the script bufferstatic java.lang.Stringassemble(NBCLIOptions options)java.util.Map<java.lang.String,java.lang.String>getCombinedParams()Get a map which contains all of the params which came from commands of global scope, likescriptandfragmentcommands.java.util.List<Cmd>getCommands()java.lang.StringgetParsedScript()Get the text image of the combined script with all previously added commands includedstatic java.lang.StringloadScript(Cmd cmd)Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
BasicScriptBuffer
public BasicScriptBuffer()
-
-
Method Details
-
getCommands
- Specified by:
getCommandsin interfaceScriptBuffer
-
add
-
add
Description copied from interface:ScriptBufferAdd parsed commands to the script buffer- Specified by:
addin interfaceScriptBuffer- Parameters:
cmds- A parsed command- Returns:
- This ScriptBuffer
-
getParsedScript
public java.lang.String getParsedScript()Description copied from interface:ScriptBufferGet the text image of the combined script with all previously added commands included- Specified by:
getParsedScriptin interfaceScriptBuffer- Returns:
- The script text
-
getCombinedParams
public java.util.Map<java.lang.String,java.lang.String> getCombinedParams()Description copied from interface:ScriptBufferGet a map which contains all of the params which came from commands of global scope, likescriptandfragmentcommands. If one of these commands overwrites a named parameter from another, an error should be logged at warning or higher level.- Specified by:
getCombinedParamsin interfaceScriptBuffer- Returns:
- A globa params map.
-
assemble
-
loadScript
-