org.jboss.jms.server.endpoint
Class ServerConsumerEndpoint

java.lang.Object
  extended by org.jboss.jms.server.endpoint.ServerConsumerEndpoint
All Implemented Interfaces:
Closeable, ConsumerEndpoint, Receiver

public class ServerConsumerEndpoint
extends java.lang.Object
implements Receiver, ConsumerEndpoint

Concrete implementation of ConsumerEndpoint. Lives on the boundary between Messaging Core and the JMS Facade. Handles delivery of messages from the server to the client side consumer.

Version:
$Revision: 3268 $ $Id: ServerConsumerEndpoint.java 3268 2007-10-31 14:35:03Z timfox $
Author:
Ovidiu Feodorov, Tim Fox

Method Summary
 boolean accept(Message msg)
           
 void changeRate(float newRate)
          Sent to the server to specify a new maximum rate at which to send messages at
 void close()
          Close the instance
 long closing(long sequence)
          Tell the instance to prepare to close
 JBossDestination getDestination()
           
 ServerSessionEndpoint getSessionEndpoint()
           
 Delivery handle(DeliveryObserver observer, MessageReference ref, Transaction tx)
          A receiver can return an active, "done" or null delivery.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

handle

public Delivery handle(DeliveryObserver observer,
                       MessageReference ref,
                       Transaction tx)
Description copied from interface: Receiver
A receiver can return an active, "done" or null delivery. The method returns null in case the receiver doesn't accept the message. The return value is unspecified when the message is submitted in the context of a transaction (tx not null).

Specified by:
handle in interface Receiver
Parameters:
observer - - the component the delivery should be acknowledged to.
See Also:
Delivery, DeliveryObserver

accept

public boolean accept(Message msg)

closing

public long closing(long sequence)
             throws JMSException
Description copied from interface: Closeable
Tell the instance to prepare to close

Specified by:
closing in interface Closeable
Throws:
JMSException

close

public void close()
           throws JMSException
Description copied from interface: Closeable
Close the instance

Specified by:
close in interface Closeable
Throws:
JMSException

changeRate

public void changeRate(float newRate)
                throws JMSException
Description copied from interface: ConsumerEndpoint
Sent to the server to specify a new maximum rate at which to send messages at

Specified by:
changeRate in interface ConsumerEndpoint
Throws:
JMSException

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

getDestination

public JBossDestination getDestination()

getSessionEndpoint

public ServerSessionEndpoint getSessionEndpoint()


Copyright © 2006 JBoss Inc. All Rights Reserved.