Applications can create an object model by instantiating this class and then setting the various clauses. When done, use {@link com.espertech.esper.client.EPAdministrator} to create a statement from the model.
Alternativly, a given textual EPL can be compiled into an object model representation via the compile method on {@link com.espertech.esper.client.EPAdministrator}.
Use the toEPL method to generate a textual EPL from an object model.
Minimally, and EPL statement consists of the select-clause and the where-clause. These are represented by {@link SelectClause}and {@link FromClause} respectively.
Here is a short example that create a simple EPL statement such as "select page, responseTime from PageLoad" :
EPStatementObjectModel model = new EPStatementObjectModel(); model.setSelectClause(SelectClause.create("page", "responseTime")); model.setFromClause(FromClause.create(FilterStream.create("PageLoad")));
The select-clause and from-clause must be set for the statement object model to be useable by the administrative API. All other clauses a optional.
Please see the documentation set for further examples.
|
|
|
|
|
|
|
|
|
|