if ( tuple.getLastHandle() == null ) {
// can be null for eval, not and exists that have no right input
continue;
}
if ( tuple.getLastHandle().isEvent() ) {
EventFactHandle handle = (EventFactHandle) tuple.getLastHandle();
// decrease the activation count for the event
handle.decreaseActivationsCount();
// handles "expire" only in stream mode.
if ( handle.isExpired() ) {
if ( handle.getActivationsCount() <= 0 ) {
// and if no more activations, retract the handle
handle.getEntryPoint().retract( handle );
}
}
}
}
}