public class PreparedEventExpressionTemplate
extends java.lang.Object
implements java.io.Serializable
Instances of this class are declared to represent templates for "Prepared Event Expressions". These are similar in concept to SQL prepared statements, in that they allow a monitor to declare a parameterised event expression that can then be "instantiated" as many times as necessary with different parameter values. The advantage of this approach over standard event expressions is that the expression is only parsed once, when the template is created. Instantiating the template with some set of parameters is then a relatively cheap operation. Standard event expressions will be parsed every time a listener is attached to them, which can be inefficient in monitors that create large numbers of listeners.
See the documentation for PreparedEventExpression
for examples of how this class is used.
Constructor and Description |
---|
PreparedEventExpressionTemplate(java.lang.String templateString)
Constructor to create a new instance with the given immutable
expression template string.
|
Modifier and Type | Method and Description |
---|---|
PreparedEventExpression |
getInstance()
Create a new instance of the event expression template.
|
java.lang.String |
getTemplateString()
Get the String value of the PreparedEventExpressionTemplate.
|
java.lang.String |
toString() |
public PreparedEventExpressionTemplate(java.lang.String templateString)
templateString
- The event expression template to be used.public java.lang.String getTemplateString()
public java.lang.String toString()
toString
in class java.lang.Object
getTemplateString()
public PreparedEventExpression getInstance()
Submit a bug or feature
Copyright (c) 2013-2022 Software AG, Darmstadt, Germany and/or Software AG USA Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors. Use, reproduction, transfer, publication or disclosure is prohibited except as specifically provided for in your License Agreement with Software AG.