org.exolab.jms.jndiadministration
Class AdminConnection
java.lang.Object
|
+--org.exolab.jms.jndiadministration.AdminConnection
- Direct Known Subclasses:
- OfflineConnection, OnlineConnection
- public abstract class AdminConnection
- extends java.lang.Object
The abstract class all AdminConnection objects must inherit from.
Currently there are only two object types. OfflineConnection, for objects
that directly connect to and use the persistency mechanism, and
OnlineConnection objects that connect to an OpenJMSServer for all
their requests.
- Version:
- $Revision: 1.4 $ $Date: 2003/08/17 01:32:23 $
- Author:
- Jim Mourikis
- See Also:
OfflineConnection
,
OnlineConnection
Method Summary |
abstract void |
close()
Close the connection. |
abstract void |
createContext(java.lang.String name)
Create a new context with the given name. |
abstract void |
destroyContext(java.lang.String name)
Destroy context with the given name. |
abstract java.util.Enumeration |
getAllContexts(java.lang.String name)
Get an enumerated list of all the Contexts |
static AdminConnection |
instance()
Returns the one and only instance of the connection object. |
abstract java.lang.Object |
lookup(java.lang.String context)
Return the object associated with this context. |
abstract void |
rebind(java.lang.String name,
java.lang.Object ob)
Rebind the context with the given object. |
abstract void |
renameContext(java.lang.String oldName,
java.lang.String newName)
Rename context with the given name. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
instance_
protected static AdminConnection instance_
AdminConnection
public AdminConnection()
instance
public static AdminConnection instance()
- Returns the one and only instance of the connection object.
- Returns:
- AdminConnection The one and only instance.
close
public abstract void close()
- Close the connection.
getAllContexts
public abstract java.util.Enumeration getAllContexts(java.lang.String name)
- Get an enumerated list of all the Contexts
- Returns:
- Enumeration The list of contexts
lookup
public abstract java.lang.Object lookup(java.lang.String context)
- Return the object associated with this context.
if none exists return null.
- Parameters:
context
- The context name- Returns:
- Object The object for this context.
createContext
public abstract void createContext(java.lang.String name)
throws javax.naming.NamingException
- Create a new context with the given name.
- Parameters:
name
- The new context name.- Throws:
NamingException
- If the context cannot be created.
destroyContext
public abstract void destroyContext(java.lang.String name)
throws javax.naming.NamingException
- Destroy context with the given name.
- Parameters:
name
- The new context name.- Throws:
NamingException
- If the context cannot be created.
renameContext
public abstract void renameContext(java.lang.String oldName,
java.lang.String newName)
throws javax.naming.NamingException
- Rename context with the given name.
- Parameters:
oldName
- The old context namenewName
- The new context name- Throws:
NamingException
- If the context cannot be created.
rebind
public abstract void rebind(java.lang.String name,
java.lang.Object ob)
throws javax.naming.NamingException
- Rebind the context with the given object.
- Parameters:
name
- The context nameob
- The object to bind in this context- Throws:
NamingException
- If the context cannot be created.
Copyright © 1999-2004 The OpenJMS Group. All Rights Reserved.