org.jacorb.notification.filter
public abstract class AbstractFilter extends Object implements GCDisposable, IServantLifecyle, FilterOperations, JMXManageable, AbstractFilterMBean
Version: $Id: AbstractFilter.java,v 1.10 2006/01/21 00:45:41 alphonse.bendt Exp $
UNKNOWN: name = "Filter"
Field Summary | |
---|---|
protected ReadWriteLock | constraintsLock_ |
protected Map | constraints_
contains the associated constraints. as access to constraints_ is controlled by
constraintsLock_ its safe to use unsynchronized HashMap here |
static int | CONSTRAINTS_EMPTY |
protected MessageFactory | messageFactory_ |
static int | NO_CONSTRAINTS_MATCH |
protected WildcardMap | wildcardMap_ |
Constructor Summary | |
---|---|
protected | AbstractFilter(Configuration config, EvaluationContextFactory evaluationContextFactory, MessageFactory messageFactory, POA poa) |
Method Summary | |
---|---|
Object | activate() |
ConstraintInfo[] | add_constraints(ConstraintExp[] constraintExp)
The add_constraints operation is invoked by a client in order to associate one
or more new constraints with the target filter object. |
int | attach_callback(NotifySubscribe notifySubscribe) |
void | attemptDispose() |
void | deactivate() |
void | destroy() |
void | detach_callback(int id) |
void | dispose() |
Date | getCreationDate() |
Iterator | getIterator(Object key) |
String[] | getJMXNotificationTypes() |
String | getJMXObjectName() |
Date | getLastUsage() |
long | getMatchCount() |
long | getMatchStructuredCount() |
long | getMatchTypedCount() |
POA | getPOA() |
ConstraintInfo[] | get_all_constraints() |
int[] | get_callbacks() |
ConstraintInfo[] | get_constraints(int[] ids) |
String | listContraints() |
boolean | match(Any anyEvent) |
protected int | match_internal(Any anyEvent)
match Any to associated constraints. return the id of the first matching filter or
NO_CONSTRAINT. |
boolean | match_structured(StructuredEvent structuredevent) |
protected int | match_structured_internal(StructuredEvent structuredEvent)
match the StructuredEvent to the associated constraints. return the id of the first matching
filter or NO_CONSTRAINT. |
boolean | match_typed(Property[] properties) |
protected int | match_typed_internal(Property[] typedEvent)
match the TypedEvent to the associated constraints. return the id of the first matching
filter or NO_CONSTRAINT. |
void | modify_constraints(int[] deleteIds, ConstraintInfo[] constraintInfo) |
protected int | newConstraintId() |
protected abstract FilterConstraint | newFilterConstraint(ConstraintExp constraintExp)
create a new FilterConstraint based on the provided ConstraintExp |
Servant | newServant() |
void | registerDisposable(Disposable disposeHook) |
void | remove_all_constraints() |
void | setJMXCallback(JMXCallback callback) |
add_constraints
operation is invoked by a client in order to associate one
or more new constraints with the target filter object. The operation accepts as input a
sequence of constraint data structures, each element of which consists of a sequence of event
type structures (described in Section 3.2.1, "The Filter Interface," on page 3-14) and a
constraint expressed within the constraint grammar supported by the target object. Upon
processing each constraint, the target object associates a numeric identifier with the
constraint that is unique among all constraints it encapsulates. If any of the constraints in
the input sequence is not a valid expression within the supported constraint grammar, the
InvalidConstraint exception is raised. This exception contains as data the specific
constraint expression that was determined to be invalid. Upon successful processing of all
input constraint expressions, the add_constraints
operation returns a sequence
in which each element will be a structure including one of the input constraint expressions,
along with the unique identifier assigned to it by the target filter object. add_constraints
operation are such that its
sideeffects are performed atomically upon the target filter object. Once
add_constraints
is invoked by a client, the target filter object is
temporarily disabled from usage by any proxy object it may be associated with. The operation
is then carried out, either successfully adding all of the input constraints to the target
object or none of them (in the case one of the input expressions was invalid). Upon
completion of the operation, the target filter object is effectively re-enabled and can once
again be used by associated filter objects in order to make event forwarding decisions.UNKNOWN: description = "Destroy this Filter" impact = "ACTION"
UNKNOWN: description = "date this filter was created" access = "read-only"
UNKNOWN: description = "last usage = invoke match operation" access = "read-only"
UNKNOWN: description = "number of match invocations on this filter" access = "read-only"
UNKNOWN: description = "number of match_structured invocations on this filter" access = "read-only"
UNKNOWN: description = "number of match_typed invocations on this filter" access = "read-only"
UNKNOWN: description = "List all Constraints" impact = "INFO"