Package org.apache.ldap.common.name

Examples of org.apache.ldap.common.name.LdapName


         * inding the base then we set the eective base to the alias target
         * gotten rom the alias index.
         */
        else if ( null != aliasedBase ) // mode = FINDING || ALWAYS
        {
            effectiveBase = new LdapName( aliasedBase );
        }
        /*
         * I the base not an alias the we just set the base to the given base
         */
        else
View Full Code Here


            msg += " but it was set to null in env!";

            throw new ConfigurationException( msg );
        }

        dn = new LdapName( url );

        if ( ! nexusProxy.hasEntry( dn ) )
        {
            throw new NameNotFoundException( dn + " does not exist" );
        }
View Full Code Here

    /**
     * @see javax.naming.Context#createSubcontext(java.lang.String)
     */
    public Context createSubcontext( String name ) throws NamingException
    {
        return createSubcontext( new LdapName( name ) );
    }
View Full Code Here

     */
    public Context createSubcontext( Name name ) throws NamingException
    {
        Attributes attributes = new LockableAttributesImpl();

        LdapName target = buildTarget( name );

        String rdn = name.get( name.size() - 1 );

        String rdnAttribute = NamespaceTools.getRdnAttribute( rdn );

        String rdnValue = NamespaceTools.getRdnValue( rdn );

        attributes.put( rdnAttribute, rdnValue );

        attributes.put( JavaLdapSupport.OBJECTCLASS_ATTR, JavaLdapSupport.JCONTAINER_ATTR );

        attributes.put( JavaLdapSupport.OBJECTCLASS_ATTR, JavaLdapSupport.TOP_ATTR );
       
        /*
         * Add the new context to the server which as a side effect adds
         * operational attributes to the attributes refering instance which
         * can them be used to initialize a new ServerLdapContext.  Remember
         * we need to copy over the controls as well to propagate the complete
         * environment besides whats in the hashtable for env.
         */
        nexusProxy.add( target.toString(), target, attributes );
       
        ServerLdapContext ctx = new ServerLdapContext( principal, nexusProxy, env, target );

        Control [] controls = ( Control [] ) ( ( ServerLdapContext ) this ).getRequestControls().clone();

View Full Code Here

    /**
     * @see javax.naming.Context#destroySubcontext(java.lang.String)
     */
    public void destroySubcontext( String name ) throws NamingException
    {
        destroySubcontext( new LdapName( name ) );
    }
View Full Code Here

    /**
     * @see javax.naming.Context#bind(java.lang.String, java.lang.Object)
     */
    public void bind( String name, Object obj ) throws NamingException
    {
        bind( new LdapName( name ), obj );
    }
View Full Code Here

    /**
     * @see javax.naming.Context#rename(java.lang.String, java.lang.String)
     */
    public void rename( String oldName, String newName ) throws NamingException
    {
        rename( new LdapName( oldName ), new LdapName( newName ) );
    }
View Full Code Here

    /**
     * @see javax.naming.Context#rebind(java.lang.String, java.lang.Object)
     */
    public void rebind( String name, Object obj ) throws NamingException
    {
        rebind( new LdapName( name ), obj );
    }
View Full Code Here

    /**
     * @see javax.naming.Context#unbind(java.lang.String)
     */
    public void unbind( String name ) throws NamingException
    {
        unbind( new LdapName( name ) );
    }
View Full Code Here

    /**
     * @see javax.naming.Context#lookup(java.lang.String)
     */
    public Object lookup( String name ) throws NamingException
    {
        return lookup( new LdapName( name ) );
    }
View Full Code Here

TOP

Related Classes of org.apache.ldap.common.name.LdapName

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.