Package org.omg.CosNotification

Examples of org.omg.CosNotification.StructuredEvent


    public void testStructuredToAny() throws Exception
    {
        Message _notifyEvent = messageFactory_.newMessage(testStructured_);
        assertNotNull(_notifyEvent);
        Any _any = _notifyEvent.toAny();
        StructuredEvent _event = StructuredEventHelper.extract(_any);
        assertNotNull(_event);
        assertEquals("domain", _event.header.fixed_header.event_type.domain_name);
        assertEquals("type", _event.header.fixed_header.event_type.type_name);
    }
View Full Code Here


    public void testStructuredToStructured() throws Exception
    {
        Message _notifyEvent = messageFactory_.newMessage(testStructured_);
        assertNotNull(_notifyEvent);
        StructuredEvent _event = _notifyEvent.toStructuredEvent();
        assertNotNull(_event);
        assertEquals("domain", _event.header.fixed_header.event_type.domain_name);
        assertEquals("type", _event.header.fixed_header.event_type.type_name);
    }
View Full Code Here

    }

    public void testAnyToStructured() throws Exception
    {
        Message _notifyEvent = messageFactory_.newMessage(testPerson_);
        StructuredEvent _structured = _notifyEvent.toStructuredEvent();
        assertNotNull(_structured);
        assertEquals("%ANY", _structured.header.fixed_header.event_type.type_name);
        assertEquals("", _structured.header.fixed_header.event_type.domain_name);
        assertEquals("", _structured.header.fixed_header.event_name);
View Full Code Here

    public void testPushStructured() throws Exception
    {
        // setup test data
        StructuredEventMessage _event = new StructuredEventMessage();

        StructuredEvent _data = getTestUtils().getEmptyStructuredEvent();

        _data.filterable_data = new Property[] {
                new Property("operation", toAny(DRINKING_COFFEE_ID)),
                new Property("name", toAny("alphonse")), new Property("minutes", toAny(10)) };
View Full Code Here

    public void setUpTest() throws Exception
    {
        messageFactory_ = new DefaultMessageFactory(getConfiguration());

        structuredEvent_ = new StructuredEvent();
        EventHeader _header = new EventHeader();
        FixedEventHeader _fixed = new FixedEventHeader();
        _fixed.event_name = "eventname";
        _fixed.event_type = new EventType("domain", "type");
        _header.fixed_header = _fixed;
View Full Code Here

    {
        Any any = toAny("value");
       
        objectUnderTest_.setAny(any);
       
        StructuredEvent event = objectUnderTest_.toStructuredEvent();
       
        assertEquals(any, event.remainder_of_body);
        assertEquals("%ANY", event.header.fixed_header.event_type.type_name);
    }
View Full Code Here

        controlTaskProcessor_.verify();
    }

    public void testDeliveryToConsumerDoesEnqueueAndDisposeMessage() throws Exception
    {
        StructuredEvent event = new StructuredEvent();

        MockControl controlMessage = MockControl.createStrictControl(Message.class);
        Message mockMessage = (Message) controlMessage.getMock();

        mockMessage.clone();
View Full Code Here

        controlTaskExecutor_.verify();
    }

    public void testFailedDeliveryToConsumerDoesNotDisposeMessage() throws Exception
    {
        StructuredEvent event = new StructuredEvent();

        MockControl controlMessage = MockControl.createControl(Message.class);
        Message mockMessage = (Message) controlMessage.getMock();

        mockMessage.clone();
View Full Code Here

    public void setUpTest() throws Exception
    {
        eventChannel_ = getDefaultChannel();

        structuredEvent_ = new StructuredEvent();
        EventHeader _header = new EventHeader();
        FixedEventHeader _fixed = new FixedEventHeader();
        _fixed.event_name = "eventname";
        _fixed.event_type = new EventType("domain", "type");
        _header.fixed_header = _fixed;
View Full Code Here

        verifyAll();
    }

    public void testMaximumBatchSize() throws Exception
    {
        StructuredEvent event = new StructuredEvent();

        MockControl controlMessage = MockControl.createNiceControl(Message.class);
        Message mockMessage = (Message) controlMessage.getMock();

        controlMessage.expectAndReturn(mockMessage.clone(), mockMessage, MockControl.ONE_OR_MORE);
View Full Code Here

TOP

Related Classes of org.omg.CosNotification.StructuredEvent

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.