package org.openengsb.edb.jbi.endpoints;
import org.openengsb.contextcommon.ContextHelper;
import org.openengsb.core.EventHelper;
import org.openengsb.core.EventHelperImpl;
import org.openengsb.core.MessageProperties;
import org.openengsb.core.endpoints.SimpleEventEndpoint;
import org.openengsb.core.model.Event;


/**
 * @org.apache.xbean.XBean element="edbEvent" The Endpoint to the commit-feature
 *
 */
public class EdbEventEndpoint extends SimpleEventEndpoint {

    @Override
    protected void handleEvent(Event e, ContextHelper contextHelper, MessageProperties msgProperties) {
        EventHelper helper = new EventHelperImpl(this, msgProperties);
        // simply forward to drools
        helper.sendEvent(e, "urn:openengsb:drools", "droolsService");
    }

}

@@ -1,278 +1,677 @@
-package org.openengsb.edb.jbi.endpoints;%0Aimport org.openengsb.contextcommon.ContextHelper;%0Aimport org.openengsb.core.EventHelper;%0Aimport org.openengsb.core.EventHelperImpl;%0Aimport org.openengsb.core.MessageProperties;%0Aimport org.openengsb.core.endpoints.SimpleEventE
+/**%0A%0A   Copyright 2010 OpenEngSB Division, Vienna University of Technology%0A%0A   Licensed under the Apache License, Version 2.0 (the %22License%22);%0A   you may not use this file except in compliance with the License.%0A   You may obtain a copy of the License at%0A%0A       http://www.apache.org/licenses/LICENSE-2.0%0A%0A   Unless required by applicable law or agreed to in writing, software%0A   distributed under the License is distributed on an %22AS IS%22 BASIS,%0A   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.%0A   See the License for the specific language governing permissions and%0A   limitations under the License.%0A%0A */%0Apackage org.openengsb.edb.jbi.e
 ndpoint
-;
+s;%0A
 %0Aimp
@@ -697,21 +697,39 @@
 ore.
-model.Event;%0A
+endpoints.EventForwardEndpoint;
 %0A%0A/*
@@ -860,331 +860,29 @@
 nds 
-SimpleEventEndpoint %7B%0A%0A    @Override%0A    protected void handleEvent(Event e, ContextHelper contextHelper, MessageProperties msgProperties) %7B%0A        EventHelper helper = new EventHelperImpl(this, msgProperties);%0A        // simply forward to drools%0A        helper.sendEvent(e, %22urn:openengsb:drools%22, %22droolsService%22);%0A    %7D%0A
+EventForwardEndpoint %7B
 %0A%7D%0A

use EventForwardingEndpoint