org.apache.jetspeed.services.messaging
Interface MessagingService

All Known Implementing Classes:
AbstractJMSMessagingService

public interface MessagingService

This class provides an API for accessing a JMS component.

Version:
$Id: MessagingService.java,v 1.4 2004/08/25 01:16:53 jford Exp $
Author:
Jeremy Ford

Field Summary
static int BYTE_MESSAGE
           
static java.lang.String GROUP_UPDATE_SUBJECT
           
static int MAP_MESSAGE
           
static int MESSAGE
           
static int OBJECT_MESSAGE
           
static java.lang.String PSML_UPDATE_SUBJECT
           
static java.lang.String REGISTRY_UPDATE_SUBJECT
           
static java.lang.String ROLE_UPDATE_SUBJECT
           
static java.lang.String SECURITY_CACHE_UPDATE_SUBJECT
           
static java.lang.String SECURITY_UPDATE_SUBJECT
           
static java.lang.String SERVICE_NAME
           
static int STREAM_MESSAGE
           
static int TEXT_MESSAGE
           
static java.lang.String USER_UPDATE_SUBJECT
           
 
Method Summary
 void addMessageListener(javax.jms.MessageListener listener, java.lang.String id, java.lang.String destination)
          This method creates a new consumer if one with the given id has not been created.
 javax.jms.MessageConsumer createConsumer(java.lang.String destination)
          This method creates a new MessageConsumer.
 javax.jms.Message createMessage(int messageType)
          Create a message based on the give type
 void removeMessageListener(java.lang.String id)
          Remove a message listener that was added to the service previously via the addMessageListener method.
 void sendMessage(javax.jms.Message message, java.lang.String destination)
          Send a message to the chose destination
 

Field Detail

SERVICE_NAME

public static final java.lang.String SERVICE_NAME
See Also:
Constant Field Values

USER_UPDATE_SUBJECT

public static final java.lang.String USER_UPDATE_SUBJECT
See Also:
Constant Field Values

GROUP_UPDATE_SUBJECT

public static final java.lang.String GROUP_UPDATE_SUBJECT
See Also:
Constant Field Values

ROLE_UPDATE_SUBJECT

public static final java.lang.String ROLE_UPDATE_SUBJECT
See Also:
Constant Field Values

SECURITY_UPDATE_SUBJECT

public static final java.lang.String SECURITY_UPDATE_SUBJECT
See Also:
Constant Field Values

MESSAGE

public static final int MESSAGE
See Also:
Constant Field Values

TEXT_MESSAGE

public static final int TEXT_MESSAGE
See Also:
Constant Field Values

BYTE_MESSAGE

public static final int BYTE_MESSAGE
See Also:
Constant Field Values

MAP_MESSAGE

public static final int MAP_MESSAGE
See Also:
Constant Field Values

OBJECT_MESSAGE

public static final int OBJECT_MESSAGE
See Also:
Constant Field Values

STREAM_MESSAGE

public static final int STREAM_MESSAGE
See Also:
Constant Field Values

REGISTRY_UPDATE_SUBJECT

public static final java.lang.String REGISTRY_UPDATE_SUBJECT
See Also:
Constant Field Values

SECURITY_CACHE_UPDATE_SUBJECT

public static final java.lang.String SECURITY_CACHE_UPDATE_SUBJECT
See Also:
Constant Field Values

PSML_UPDATE_SUBJECT

public static final java.lang.String PSML_UPDATE_SUBJECT
See Also:
Constant Field Values
Method Detail

addMessageListener

public void addMessageListener(javax.jms.MessageListener listener,
                               java.lang.String id,
                               java.lang.String destination)
This method creates a new consumer if one with the given id has not been created. The consumer will be closed during the services shutdown.

Parameters:
listener -
id -
destination -

createConsumer

public javax.jms.MessageConsumer createConsumer(java.lang.String destination)
This method creates a new MessageConsumer. It's lifecycle should be managed by the caller.

Parameters:
destination -

removeMessageListener

public void removeMessageListener(java.lang.String id)
Remove a message listener that was added to the service previously via the addMessageListener method.

Parameters:
id -

sendMessage

public void sendMessage(javax.jms.Message message,
                        java.lang.String destination)
Send a message to the chose destination

Parameters:
message -
destination -

createMessage

public javax.jms.Message createMessage(int messageType)
Create a message based on the give type

Parameters:
messageType -
Returns:


Copyright © 2000-2005 Apache Software Foundation. All Rights Reserved.