| org.jboss.mq.sm.StateManager
All known Subclasses: org.jboss.mq.sm.file.OldStateManager, org.jboss.mq.sm.AbstractStateManager,
StateManager | public interface StateManager (Code) | | Interface for StateManager.
A StateManager is a manager that manages states that has to do with clients/
users and durable subscription.
A state manager most know how to persist information regarding durable
subscriptions.
It should also hold all current clientID's that are connected to the server.
It may also support basic autentication, which is what the old
default StateManager did.
author: Peter Antman author: Norbert Lataille author: Hiram Chirino version: $Revision: 57198 $ |
addLoggedOnClientId | public void addLoggedOnClientId(String ID) throws JMSException(Code) | | Ad a logged in clientID to the statemanager.
The clientID must not be active.
The StateManager should somehow assure that a clientID that is
preconfigured for a user is not allowed to be added this way.
Parameters: ID - a clientID exception: JMSException - Description of Exception exception: InvalidClientIDException - if the clientID wass already logged in. |
checkUser | public String checkUser(String login, String passwd) throws JMSException(Code) | | Check if a user has a preconfigured clientID and return it.
If the user has a preconfigured clienID it will be added to the current
logged in clientID's and returned.
The state manager may also use this method to authenticate a user.
If a SecurityManager is installed this is not necesarry.
Parameters: login - user name Parameters: passwd - password a preconfigured clientID. exception: JMSException - if the user exception: JMSSecurityException - if the clientID is already loged in. |
getDurableSubscriptionIdsForTopic | public Collection getDurableSubscriptionIdsForTopic(SpyTopic topic) throws JMSException(Code) | | Get all configured durable subscriptions for a particular topic.
Parameters: topic - the topic. a collection of DurableSubscriptionID exception: JMSException - Description of Exception |
removeLoggedOnClientId | public void removeLoggedOnClientId(String ID)(Code) | | Remove the logged in clientID.
Parameters: ID - clientID. |
setDurableSubscription | public void setDurableSubscription(JMSDestinationManager server, DurableSubscriptionID sub, SpyTopic topic) throws JMSException(Code) | | Ad, change or delete a durable subsciption.
The contract is that the StateManager, must physically create the durable
subscription. And when the method returns the information must be persisted.
Parameters: server - The JMSServer Parameters: sub - The id of the durable subscription Parameters: topic - The topic to subscribe durable on, if nullthe subscription will be removed. exception: JMSException - Description of Exception |
|
|