Class CompilerOptions

java.lang.Object
com.espertech.esper.compiler.client.CompilerOptions

public class CompilerOptions extends Object
Callbacks and optional values for the compiler to determine modifiers, statement name, statement user object, module name and module-uses. All values are optional and can be null.
  • Constructor Details

    • CompilerOptions

      public CompilerOptions()
  • Method Details

    • getAccessModifierEventType

      public AccessModifierEventTypeOption getAccessModifierEventType()
      Returns the callback that determines the access modifier of a given event type
      Returns:
      callback returning an access modifier for an event type
    • setAccessModifierEventType

      public CompilerOptions setAccessModifierEventType(AccessModifierEventTypeOption accessModifierEventType)
      Sets the callback that determines the access modifier of a given event type.
      Parameters:
      accessModifierEventType - callback returning an access modifier for an event type
      Returns:
      itself
    • getStatementUserObject

      public StatementUserObjectOption getStatementUserObject()
      Returns the callback that determines a compiler-time statement user object for a statement. The user object is available from EPStatement by method getUserObjectCompileTime.
      Returns:
      callback to set a compile-time statement user object
    • setStatementUserObject

      public CompilerOptions setStatementUserObject(StatementUserObjectOption statementUserObject)
      Sets the callback that determines a compiler-time statement user object for a statement. The user object is available from EPStatement by method getUserObjectCompileTime.
      Parameters:
      statementUserObject - callback to set a compile-time statement user object
      Returns:
      itself
    • setBusModifierEventType

      public CompilerOptions setBusModifierEventType(BusModifierEventTypeOption busModifierEventType)
      Sets the callback that determines whether the event type is visible in the event bus i.e. available for use with send-event.
      Parameters:
      busModifierEventType - callback to set the event type bus modifier value
      Returns:
      itself
    • getBusModifierEventType

      public BusModifierEventTypeOption getBusModifierEventType()
      Returns the callback that determines whether the event type is visible in the event bus i.e. available for use with send-event.
      Returns:
      callback to set the event type bus modifier value
    • getAccessModifierContext

      public AccessModifierContextOption getAccessModifierContext()
      Returns the callback that determines the access modifier of a given context.
      Returns:
      callback returning an access modifier for a context
    • setAccessModifierContext

      public CompilerOptions setAccessModifierContext(AccessModifierContextOption accessModifierContext)
      Sets the callback that determines the access modifier of a given context.
      Parameters:
      accessModifierContext - callback returning an access modifier for a context
      Returns:
      itself
    • getAccessModifierVariable

      public AccessModifierVariableOption getAccessModifierVariable()
      Returns the callback that determines the access modifier of a given variable.
      Returns:
      callback returning an access modifier for a variable
    • setAccessModifierVariable

      public CompilerOptions setAccessModifierVariable(AccessModifierVariableOption accessModifierVariable)
      Sets the callback that determines the access modifier of a given variable.
      Parameters:
      accessModifierVariable - callback returning an access modifier for a variable
      Returns:
      itself
    • getAccessModifierInlinedClass

      public AccessModifierInlinedClassOption getAccessModifierInlinedClass()
      Returns the callback that determines the access modifier of a given inlined-class.
      Returns:
      callback returning an access modifier for an inlined-class
    • setAccessModifierInlinedClass

      public CompilerOptions setAccessModifierInlinedClass(AccessModifierInlinedClassOption accessModifierInlinedClass)
      Sets the callback that determines the access modifier of a given inlined-class.
      Parameters:
      accessModifierInlinedClass - callback returning an access modifier for an inlined-class
      Returns:
      itself
    • getAccessModifierExpression

      public AccessModifierExpressionOption getAccessModifierExpression()
      Returns the callback that determines the access modifier of a given declared expression.
      Returns:
      callback returning an access modifier for a declared expression
    • setAccessModifierExpression

      public CompilerOptions setAccessModifierExpression(AccessModifierExpressionOption accessModifierExpression)
      Sets the callback that determines the access modifier of a given declared expression.
      Parameters:
      accessModifierExpression - callback returning an access modifier for a declared expression
      Returns:
      itself
    • getAccessModifierTable

      public AccessModifierTableOption getAccessModifierTable()
      Returns the callback that determines the access modifier of a given declared expression.
      Returns:
      callback returning an access modifier for a declared expression
    • setAccessModifierTable

      public CompilerOptions setAccessModifierTable(AccessModifierTableOption accessModifierTable)
      Returns the callback that determines the access modifier of a given table.
      Parameters:
      accessModifierTable - callback returning an access modifier for a table
      Returns:
      itself
    • getStatementName

      public StatementNameOption getStatementName()
      Returns the callback that determines the statement name
      Returns:
      callback returning the statement name
    • setStatementName

      public CompilerOptions setStatementName(StatementNameOption statementName)
      Sets the callback that determines the statement name
      Parameters:
      statementName - callback returning the statement name
      Returns:
      itself
    • getAccessModifierNamedWindow

      public AccessModifierNamedWindowOption getAccessModifierNamedWindow()
      Returns the callback that determines the access modifier of a given named window.
      Returns:
      callback returning an access modifier for an named window
    • setAccessModifierNamedWindow

      public CompilerOptions setAccessModifierNamedWindow(AccessModifierNamedWindowOption accessModifierNamedWindow)
      Sets the callback that determines the access modifier of a given named window.
      Parameters:
      accessModifierNamedWindow - callback returning an access modifier for an named window
      Returns:
      itself
    • getAccessModifierScript

      public AccessModifierScriptOption getAccessModifierScript()
      Returns the callback that determines the access modifier of a given script.
      Returns:
      callback returning an access modifier for a script
    • setAccessModifierScript

      public CompilerOptions setAccessModifierScript(AccessModifierScriptOption accessModifierScript)
      Sets the callback that determines the access modifier of a given script.
      Parameters:
      accessModifierScript - callback returning an access modifier for a script
      Returns:
      itself
    • getModuleName

      public ModuleNameOption getModuleName()
      Returns the callback that determines the module name.
      Returns:
      callback returning the module name to use
    • setModuleName

      public CompilerOptions setModuleName(ModuleNameOption moduleName)
      Sets the callback that determines the module name.
      Parameters:
      moduleName - callback returning the module name to use
      Returns:
      itself
    • getModuleUses

      public ModuleUsesOption getModuleUses()
      Returns the callback that determines the module uses.
      Returns:
      callback returning the module uses
    • setModuleUses

      public CompilerOptions setModuleUses(ModuleUsesOption moduleUses)
      Sets the callback that determines the module uses.
      Parameters:
      moduleUses - callback returning the module uses
      Returns:
      itself
    • getInlinedClassInspection

      public InlinedClassInspectionOption getInlinedClassInspection()
      Returns the classback for inlined-class compilation wherein the callback receives class output
      Returns:
      callback
    • setInlinedClassInspection

      public void setInlinedClassInspection(InlinedClassInspectionOption inlinedClassInspection)
      Sets the classback for inlined-class compilation wherein the callback receives class output
      Parameters:
      inlinedClassInspection - callback
    • getStateMgmtSetting

      public StateMgmtSettingOption getStateMgmtSetting()
      For internal-use-only and subject-to-change-between-versions, state-management settings
      Returns:
      settings option
    • setStateMgmtSetting

      public void setStateMgmtSetting(StateMgmtSettingOption stateMgmtSetting)
      For internal-use-only and subject-to-change-between-versions, state-management settings
      Parameters:
      stateMgmtSetting - settings option
    • getPathCache

      public CompilerPathCache getPathCache()
      Returns a cache, or null if not using a cache, that retains for each EPCompiled the EPL objects that the EPCompiled provides.
      Returns:
      cache or null if not using a cache
    • setPathCache

      public void setPathCache(CompilerPathCache pathCache)
      Sets the cache, or null if not using a cache, that retains for each EPCompiled the EPL objects that the EPCompiled provides.
      Parameters:
      pathCache - or null if not using a cache
    • getCompilerHook

      public CompilerHookOption getCompilerHook()
      Experimental API: Returns the provider of the compiler to use

      NOTE: Experimental API and not supported

      Returns:
      compiler option or null to use the default Janino-based compiler
    • setCompilerHook

      public void setCompilerHook(CompilerHookOption compilerHook)
      Experimental API: Sets the provider of the compiler to use

      NOTE: Experimental API and not supported

      Experimental - Not Supported - Set the JDK compiler like this:

               compilerHook = new CompilerHookOption() {
                   public CompilerAbstraction getValue(CompilerHookContext env) {
                       return new CompilerAbstractionToolProvider(ToolProvider.getSystemJavaCompiler());
                   }
               };
       
      Parameters:
      compilerHook - provider of the compiler to that replaces the default Janino-based compiler