Package org.omg.CosNotification

Examples of org.omg.CosNotification.StructuredEvent


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

        // set test event type and name
        testEvent_ = new StructuredEvent();
        EventType _type = new EventType("testDomain", "testType");
        FixedEventHeader _fixed = new FixedEventHeader(_type, "testing");

        // complete header date
        Property[] _variable = new Property[0];
View Full Code Here


        assertTrue(receiver.isEventHandled());

        while (!received.isEmpty())
        {
            StructuredEvent event = (StructuredEvent) received.remove(0);

            Iterator i = received.iterator();
            while (i.hasNext())
            {
                short p1 = event.header.variable_header[0].value.extract_short();
View Full Code Here

     *                if an error occurs
     */
    public StructuredEvent pull_structured_event() throws Disconnected
    {
        BooleanHolder _success = new BooleanHolder();
        StructuredEvent _event;
        while (true)
        {
            _event = try_pull_structured_event(_success);
            if (_success.value)
            {
View Full Code Here

     */
    public StructuredEvent try_pull_structured_event(BooleanHolder booleanHolder)
            throws Disconnected
    {
        booleanHolder.value = false;
        StructuredEvent _result = NotificationTestUtils.getInvalidStructuredEvent(orb_);
        if (event_ != null)
        {
            synchronized (this)
            {
                if (event_ != null && available_)
View Full Code Here

        assertEquals("TESTING", _result.getString());
    }

    public void testToStructuredEvent() throws Exception {
        Message _event = factory_.newMessage(testPerson_);
        StructuredEvent _structuredEvent = _event.toStructuredEvent();

        assertEquals("", _structuredEvent.header.fixed_header.event_type.domain_name);
        assertEquals("%ANY", _structuredEvent.header.fixed_header.event_type.type_name);

        Person _p = PersonHelper.extract(_structuredEvent.remainder_of_body);
View Full Code Here

                    {
                        return null;
                    }
                });

        StructuredEvent _recvd = _mesg.toStructuredEvent();

        assertEquals(testStructured_.header.fixed_header.event_name,
                _recvd.header.fixed_header.event_name);

        assertEquals(testStructured_.remainder_of_body, _recvd.remainder_of_body);
View Full Code Here

        assertEquals(testStructured_.remainder_of_body, _recvd.remainder_of_body);
    }

    public void testWrappedAnyToAny() throws Exception
    {
        StructuredEvent _wrappedAny = new StructuredEvent();

        EventHeader _header = new EventHeader();
        FixedEventHeader _fixed = new FixedEventHeader();
        _fixed.event_name = "";
        _fixed.event_type = new EventType("", "%ANY");
View Full Code Here

        messageFactory_ = new DefaultMessageFactory(getConfiguration());

        testPerson_ = testUtils_.getTestPersonAny();

        testStructured_ = 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

    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

        FixedEventHeader _fixedHeader = new FixedEventHeader();
        _fixedHeader.event_name = "ALARM";
        _fixedHeader.event_type = new EventType("TESTING", "TESTING");
        EventHeader _header = new EventHeader(_fixedHeader, new Property[0]);

        StructuredEvent _structuredEvent = new StructuredEvent(_header, new Property[0],
                getTestPersonAny());

        return _structuredEvent;
    }
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.