org.openmdx.kernel.naming
Class Contexts

java.lang.Object
  extended by org.openmdx.kernel.naming.Contexts

public class Contexts
extends Object

Naming Utilities


Field Summary
static String NAMING_SERVICE
          This system property contains the id under which the lightweight container's naming service is bound to RMI registry.
static String REGISTRY_PORT
          This system property contains the port to be used by the lightweight container's RMI registry.
 
Constructor Summary
protected Contexts()
          Constructor
 
Method Summary
static void bind(Context context, Name name, Object object)
          Binds an object to a name creating intermediate contexts if necessary
static void bind(Context context, String name, Object object)
          Binds an object to a name creating intermediate contexts if necessary
static String getNamingService()
          The name under which the lightweight container is bound to the registry
static int getRegistryPort()
          The lightweight container's RMI registry's port.
static Context getSubcontext(Context context, Name name)
          Lookup or create a subcontext
static Context getSubcontext(Context context, String name)
          Lookup or create a subcontext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NAMING_SERVICE

public static final String NAMING_SERVICE
This system property contains the id under which the lightweight container's naming service is bound to RMI registry.

See Also:
Constant Field Values

REGISTRY_PORT

public static final String REGISTRY_PORT
This system property contains the port to be used by the lightweight container's RMI registry.

See Also:
Constant Field Values
Constructor Detail

Contexts

protected Contexts()
Constructor

Method Detail

bind

public static void bind(Context context,
                        Name name,
                        Object object)
                 throws NamingException
Binds an object to a name creating intermediate contexts if necessary

Parameters:
context -
name - the name relative to the context
object - the object to be bound to the name
Throws:
NamingException

bind

public static void bind(Context context,
                        String name,
                        Object object)
                 throws NamingException
Binds an object to a name creating intermediate contexts if necessary

Parameters:
context -
name - the name relative to the context
object - the object to be bound to the name
Throws:
NamingException

getSubcontext

public static Context getSubcontext(Context context,
                                    Name name)
                             throws NamingException
Lookup or create a subcontext

Parameters:
context -
name - the name relative to the context
Returns:
the existing or newly created context
Throws:
NamingException

getSubcontext

public static Context getSubcontext(Context context,
                                    String name)
                             throws NamingException
Lookup or create a subcontext

Parameters:
context -
name - the name relative to the context
Returns:
the existing or newly created context
Throws:
NamingException

getNamingService

public static String getNamingService()
The name under which the lightweight container is bound to the registry


getRegistryPort

public static int getRegistryPort()
The lightweight container's RMI registry's port.



This software is published under the BSD license. Copyright © 2003-2007, OMEX AG, Switzerland, All rights reserved. Use is subject to license terms.