Interface ScriptingExtensionPluginInfo<T>

All Known Implementing Classes:
ComputeFunctionPluginInfo, CqlUtilsPluginInfo, ExamplePluginData, GlobalVarsScriptingExtensionPluginData

public interface ScriptingExtensionPluginInfo<T>
Any implementation of a SandboxExtension that is found in the runtime can be automatically loaded into the scenario scripting sandbox. The descriptor type is used to flag the object type of the actual instance to be used as the extension point.

Each scenario gets its own instance of an object from this SandboxPlugin

  • Method Details

    • getDescription

      String getDescription()
      Returns:
      a brief description of this extension.
    • getExtensionObject

      T getExtensionObject(org.apache.logging.log4j.Logger logger, NBComponent component)
      Parameters:
      logger - A logger named for the extension, in case the extension wants to log internally
      component - The main metrics component, in case the extension wants to track metrics internally
      Returns:
      a new instance of an extension. The extension is given a logger if it desires.
    • getBaseVariableName

      default String getBaseVariableName()
      Returns:
      a simple name at the root of the variable namespace to anchor this extension.
    • isAutoLoading

      default boolean isAutoLoading()
      If auto loading is true, then the extension will be injected into every scenario sandbox. If it is false, then the runtime may offer the user the extension via some mechanism.
      Returns:
      whether or not to auto inject this extension into each new scenario
    • autoImportStaticMethodClasses

      default List<Class<?>> autoImportStaticMethodClasses()