Package org.jacorb.notification.interfaces

Examples of org.jacorb.notification.interfaces.Message


    }

    public void push_structured_event(StructuredEvent structuredEvent) throws Disconnected
    {
        checkStillConnected();
        Message _mesg = getMessageFactory().newMessage(structuredEvent, this);

        checkMessageProperties(_mesg);
        processMessage(_mesg);
    }
View Full Code Here


        return new MessageSupplierDelegate.PullResult(_event, _hasEvent.value);
    }

    public void queueMessages(PullResult data)
    {
        Message _mesg = getMessageFactory().newMessage((StructuredEvent) data.data_, this);

        checkMessageProperties(_mesg);

        processMessage(_mesg);
    }
View Full Code Here

        return new MessageSupplierDelegate.PullResult(_event, _hasEvent.value);
    }

    public void queueMessages(PullResult data)
    {
        Message _message = getMessageFactory().newMessage((Any) data.data_, this);

        checkMessageProperties(_message);

        processMessage(_message);
    }
View Full Code Here

    private Message updatePriority(int indexOfCurrentEvent, Message message)
    {
        AnyHolder _priorityFilterResult = new AnyHolder();

        Message _currentMessage = message;

        try
        {
            boolean priorityMatch = message.match(arrayCurrentFilterStage_[indexOfCurrentEvent]
                    .getPriorityFilter(), _priorityFilterResult);

            if (priorityMatch)
            {
                _currentMessage = (Message) getMessage().clone();

                _currentMessage.setPriority(_priorityFilterResult.value.extract_long());
            }
        } catch (UnsupportedFilterableData e)
        {
            if (logger_.isDebugEnabled())
            {
View Full Code Here

    }

    private Message updateTimeout(int indexOfCurrentFilterStage, Message message)
    {
        AnyHolder _lifetimeFilterResult = new AnyHolder();
        Message _currentMessage = message;

        try
        {
            boolean lifetimeMatch = _currentMessage.match(
                    arrayCurrentFilterStage_[indexOfCurrentFilterStage].getLifetimeFilter(),
                    _lifetimeFilterResult);

            if (lifetimeMatch && (_currentMessage == getMessage()))
            {
                // LifeTime Mapping Filter matched and current Message
                // was not copied yet. This depends on the fact that
                // updatePriority was run before.

                _currentMessage = (Message) getMessage().clone();

                _currentMessage.setTimeout(_lifetimeFilterResult.value.extract_long());
            }

        } catch (UnsupportedFilterableData e)
        {
            if (logger_.isDebugEnabled())
View Full Code Here

        {
            boolean _forward = false;

            if (!arrayCurrentFilterStage_[x].isDestroyed())
            {
                Message _currentMessage = getMessage();

                if (arrayCurrentFilterStage_[x].hasPriorityFilter())
                {
                    _currentMessage = updatePriority(x, _currentMessage);
                }

                if (arrayCurrentFilterStage_[x].hasLifetimeFilter())
                {
                    _currentMessage = updateTimeout(x, _currentMessage);
                }

                if (_currentMessage != getMessage())
                {
                    // MappingFilter attached to a particular
                    // FilterStage did change (Timeout or Priority)
                    // the current Message.
                    // store changed Message in Map for later use.
                    changedMessages_.putAlternateMessage(arrayCurrentFilterStage_[x],
                            _currentMessage);
                }

                _forward = _currentMessage.match(arrayCurrentFilterStage_[x]);
            }

            if (_forward)
            {
                // the subsequent destination filters need to be eval'd
View Full Code Here

        message_ = message;
    }

    public Message removeMessage()
    {
        Message _mesg = message_;

        message_ = null;

        return _mesg;
    }
View Full Code Here

    {
        for (int x = 0; x < filterStagesWithMessageConsumer.length; ++x)
        {
            MessageConsumer consumer = filterStagesWithMessageConsumer[x].getMessageConsumer();

            Message alternateMessage = map.getAlternateMessage(filterStagesWithMessageConsumer[x]);

            if (alternateMessage != null)
            {
                consumer.queueMessage(alternateMessage);
            }
View Full Code Here

     * factory method to create PushToConsumer Tasks. The Tasks are initialized with the data taken
     * from a FilterProxySupplierTask.
     */
    public void enqueueMessage(FilterProxySupplierTask task)
    {
        Message _message = task.removeMessage();

        FilterStage[] _seqFilterStageToBeProcessed = task.getFilterStageToBeProcessed();

        enqueueMessage(_seqFilterStageToBeProcessed, _message, task.changedMessages_);
    }
View Full Code Here

        {
            Message[] allMessages = queue_.getAllMessages(false);

            for (int i = 0; i < allMessages.length; i++)
            {
                Message message = allMessages[i];
                message.dispose();
            }
        } catch (InterruptedException e)
        {
            // should not happen as above call does not wait.
        }
View Full Code Here

TOP

Related Classes of org.jacorb.notification.interfaces.Message

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.