com.espertech.esper.client.soda
Class FilterStream

java.lang.Object
  extended by com.espertech.esper.client.soda.Stream
      extended by com.espertech.esper.client.soda.ProjectedStream
          extended by com.espertech.esper.client.soda.FilterStream
All Implemented Interfaces:
Serializable

public class FilterStream
extends ProjectedStream

A stream upon which projections (views) can be added that selects events by name and filter expression.

See Also:
Serialized Form

Constructor Summary
FilterStream(Filter filter)
          Ctor.
FilterStream(Filter filter, String name)
          Ctor.
FilterStream(Filter filter, String name, List<View> views)
          Ctor.
 
Method Summary
static FilterStream create(Filter filter)
          Creates a stream using a filter that provides the event type name and filter expression to filter for.
static FilterStream create(Filter filter, String streamName)
          Creates a stream using a filter that provides the event type name and filter expression to filter for.
static FilterStream create(String eventTypeAlias)
          Creates a stream of events of the given name.
static FilterStream create(String eventTypeAlias, Expression filter)
          Creates a stream of events of the given event type name and names that stream.
static FilterStream create(String eventTypeAlias, String streamName)
          Creates a stream of events of the given event type name and names that stream.
static FilterStream create(String eventTypeAlias, String streamName, Expression filter)
          Creates a stream of events of the given event type name and names that stream.
 Filter getFilter()
          Returns the filter.
 void setFilter(Filter filter)
          Sets the filter to use.
 void toEPLProjectedStream(StringWriter writer)
          Represent as textual.
 
Methods inherited from class com.espertech.esper.client.soda.ProjectedStream
addView, addView, addView, addView, getViews, isUnidirectional, setUnidirectional, setViews, toEPLStream, toEPLViews
 
Methods inherited from class com.espertech.esper.client.soda.Stream
getStreamName, setStreamName, toEPL
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FilterStream

public FilterStream(Filter filter)
Ctor.

Parameters:
filter - specifies what events to look for

FilterStream

public FilterStream(Filter filter,
                    String name)
Ctor.

Parameters:
filter - specifies what events to look for
name - is the as-name for the stream

FilterStream

public FilterStream(Filter filter,
                    String name,
                    List<View> views)
Ctor.

Parameters:
filter - specifies what events to look for
name - is the as-name for the stream
views - is a list of projections onto the stream
Method Detail

create

public static FilterStream create(Filter filter)
Creates a stream using a filter that provides the event type name and filter expression to filter for.

Parameters:
filter - defines what to look for
Returns:
stream

create

public static FilterStream create(String eventTypeAlias)
Creates a stream of events of the given name.

Parameters:
eventTypeAlias - is the event type name or alias to filter for
Returns:
stream

create

public static FilterStream create(String eventTypeAlias,
                                  String streamName)
Creates a stream of events of the given event type name and names that stream. Example: "select * from MyEventTypeAlias as StreamName".

Parameters:
eventTypeAlias - is the event type name or alias to filter for
streamName - is an optional stream name
Returns:
stream

create

public static FilterStream create(Filter filter,
                                  String streamName)
Creates a stream using a filter that provides the event type name and filter expression to filter for.

Parameters:
filter - defines what to look for
streamName - is an optional stream name
Returns:
stream

create

public static FilterStream create(String eventTypeAlias,
                                  Expression filter)
Creates a stream of events of the given event type name and names that stream. Example: "select * from MyEventTypeAlias as StreamName".

Parameters:
eventTypeAlias - is the event type name or alias to filter for
filter - is the filter expression removing events from the stream
Returns:
stream

create

public static FilterStream create(String eventTypeAlias,
                                  String streamName,
                                  Expression filter)
Creates a stream of events of the given event type name and names that stream. Example: "select * from MyEventTypeAlias as StreamName".

Parameters:
eventTypeAlias - is the event type name or alias to filter for
filter - is the filter expression removing events from the stream
streamName - is an optional stream name
Returns:
stream

getFilter

public Filter getFilter()
Returns the filter.

Returns:
filter

setFilter

public void setFilter(Filter filter)
Sets the filter to use.

Parameters:
filter - to set

toEPLProjectedStream

public void toEPLProjectedStream(StringWriter writer)
Description copied from class: ProjectedStream
Represent as textual.

Specified by:
toEPLProjectedStream in class ProjectedStream
Parameters:
writer - to output to

© 2007 EsperTech Inc.
All rights reserved.
Visit us at espertech.com