Interface ScriptBinding

All Known Implementing Classes:
CmsScriptBinding, RepositoryScriptBinding, RuntimeScriptBinding, StaticConfigurableScriptBinding, WebScriptBinding

public interface ScriptBinding
This interface describes a console data, variables and functions. Each implementation of this interface will enhance the console, by providing additional variables and functions that can be used in scripts.
  • Method Details

    • getWorkspacePattern

      Return the pattern of the workspace corresponding to this script binding.
      Returns:
      The pattern to match
    • getVariables

      Returns the list of variables this ScriptBinding provides, mapped by variable name.
      Parameters:
      execArgs - The The arguments for script execution
      Returns:
      The list of variables, or null if no variable is provided.
    • getVariablesScripts

      Returns the JavaScript variables script to inject at the start of the script, in the form of a single String prepended to the script.
      Returns:
      The functions text, or null if no function is provided.
    • getVariablesDescriptions

      Returns the list of variables descriptions, mapped by variable name. This list does not have to match the getVariables return value, but the description is used to inform the user of the existence and usability of each variable.
      Returns:
      The list of variables descriptions, or null if no description is provided.
    • cleanVariables

      void cleanVariables(Map<String,Object> variables)
      Allows clean up of variables created during the getVariables call.
      Parameters:
      variables - The map of variables.
    • getFunctions

      Returns the JavaScript functions to inject at the start of the script, in the form of a single String prepended to the script.
      Returns:
      The functions text, or null if no function is provided.
    • getFunctionsDescriptions

      Returns the list of functions descriptions, mapped by function name. This list does not have to match the functions returned by getFunctions, but the description is used to inform the user of the existence and usability of each function.
      Returns:
      The list of functions descriptions, or null if no description is provided.
    • getTutorials

      Returns the list of tutorials
      Returns:
      The list of tutorials, or null if no tutorial is provided.