Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [incquery-dev] IPatternMatch refactoring

Hi,

-----incquery-dev-bounces@xxxxxxxxxxx ezt írta: -----

Can't we hide away all these behind a facade called EventSource{Specification|Instance|...} or something, so that we do not need multiple RuleSpecification and RuleInstance classes? 

We can, we should, we will. Can you elaborate on your idea?
How about this:

eventSourceSpecification may be a MatcherFactory/QuerySpecification (or a wrapper around it), or alternatively something that encompasses a complex event specification 

EventSourceInstance eventSourceInstance = eventSourceSpecification.get(IncQueryEngine) // this is specific to an engine, e.g. a Matcher (or a wrapper around it), or whatever its analogy is in CEP
eventSourceInstance.addUpdateListener(listener); // wraps matchUpdateListener... possibly also element updates?

listener will receive callbacks characterized by (a) an ITuple, (b) a transition/action token that can be interpreted by the ActivationLifeCycle to move to a new state. In case of a matcher, this is appear/disappear (and update?), while for CEP, it may be "happen" or something else characteristic to CEP.

Will this work? I have no idea what kind of internal impulses CEP aims to provide.

Cheers
Gaben

Back to the top