throws EventException {
final LinkedList<Subscription> list = new LinkedList<Subscription>();
for (Map.Entry<String, Subscription> stringSubscriptionEntry : store.entrySet()) {
//TODO : pick the filter based on the dialect
//XPathBasedEventFilter filter = new XPathBasedEventFilter();
TopicBasedEventFilter filter = new TopicBasedEventFilter();
if (filter != null) {
filter.setResultValue(stringSubscriptionEntry.getValue().getFilterValue());
filter.setSourceXpath(topicXPath);
//evaluatedValue = topicXPath.stringValueOf(mc);
}
if (filter == null || filter.match(event)) {
Subscription subscription = stringSubscriptionEntry.getValue();
Calendar current = Calendar.getInstance(); //Get current date and time
if (subscription.getExpires() != null) {
if (current.before(subscription.getExpires())) {
// add only valid subscriptions by checking the expiration