base/common/src/main/com/thesett/common/jndi/SimpleContext.java
public void rebind(String name, Object obj) throws NamingException
    {
        if ("".equals(name))
        {
            throw new InvalidNameException("Cannot bind empty name");
        }

        bindings.put(name, obj);
    }
public void rebind(String name, Object obj) throws NamingException
    {
        if ("".equals(name))
        {
            throw new InvalidNameException("Cannot bind empty name");
        }

        bindings.put(name, obj);
    }
Binds a name to an object, overwriting any existing binding. All intermediate contexts and the target context
(that named by all but terminal atomic component of the name) must already exist.

<p/>If the object is a DirContext, any existing attributes associated with the name are replaced with those of
the object. Otherwise, any existing attributes associated with the name remain unchanged.

@param  name The name to bind; may not be empty.
@param  obj  The object to bind; possibly null.

@throws NamingException If the name is illegal.