Package org.apache.cxf.event

Examples of org.apache.cxf.event.Event


        WorkQueueManagerImpl wqm = new WorkQueueManagerImpl();
        wqm.setBus(bus);
        EventProcessor ep = bus.getExtension(EventProcessor.class);
        QName eventID = new QName(ComponentEventFilter.COMPONENT_CREATED_EVENT);
        if (null != ep) {        
            ep.sendEvent(new Event(wqm, eventID));
        }       
       
        //NOTE: now the bus WorkQueueManager is lazy load , if WorkQueueManager
        //create with bus , this test could be failed.
        List<Instrumentation> list = im.getAllInstrumentation();
        //NOTE: change for the BindingManager and TransportFactoryManager instrumentation
        // create with the bus.
        assertEquals("Too many instrumented items", 1, list.size());
        Instrumentation it1 = list.get(0);
        //Instrumentation it2 = list.get(3);
        assertTrue("Item 1 not a WorkQueueInstrumentation",
                   WorkQueueInstrumentation.class.isAssignableFrom(it1.getClass()));
       
        // not check for the instrumentation unique name
        // sleep for the MBServer connector thread startup
        try {
            Thread.sleep(100);
        } catch (InterruptedException e) {
            // do nothing
        }
        eventID = new QName(ComponentEventFilter.COMPONENT_REMOVED_EVENT);
        if (null != ep) {
            ep.sendEvent(new Event(wqm, eventID));
        }   
        assertEquals("Instrumented stuff not removed from list", 0, list.size());
        bus.shutdown(true);
        assertEquals("Instrumented stuff not removed from list", 0, list.size());
    }
View Full Code Here


            autoQueue = createAutomaticWorkQueue();
            EventProcessor ep = bus.getExtension(EventProcessor.class);
            //setup the QName
            QName eventID = new QName(ComponentEventFilter.COMPONENT_CREATED_EVENT);
            if (null != ep) {               
                ep.sendEvent(new Event(this, eventID));
            }
        }
        return autoQueue;
    }
View Full Code Here

        //sent out remove event.
        EventProcessor ep = bus.getExtension(EventProcessor.class);
        QName eventID = new QName(ComponentEventFilter.COMPONENT_REMOVED_EVENT);
        if (null != ep) {
            ep.sendEvent(new Event(this, eventID));       
        }
        synchronized (this) {
            notifyAll();
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.cxf.event.Event

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.