Package javax.naming.ldap

Examples of javax.naming.ldap.LdapName


     */
    public Object lookup( String name ) throws NamingException
    {
        if ( Strings.isEmpty( name ) )
        {
            return lookup( new LdapName( "" ) );
        }
        else
        {
            return lookup( new LdapName( name ) );
        }
    }
View Full Code Here


     */
    @SuppressWarnings(value =
        { "unchecked" })
    public NamingEnumeration list( String name ) throws NamingException
    {
        return list( new LdapName( name ) );
    }
View Full Code Here

     */
    @SuppressWarnings(value =
        { "unchecked" })
    public NamingEnumeration listBindings( String name ) throws NamingException
    {
        return listBindings( new LdapName( name ) );
    }
View Full Code Here

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

    }


    public void addNamingListener( String name, int scope, NamingListener namingListener ) throws NamingException
    {
        addNamingListener( new LdapName( name ), scope, namingListener );
    }
View Full Code Here

     * The expected results is that the name returns the string exactly as given
     * in the constructor.
     * </p>
     */
    public void testToString005() throws Exception {
        LdapName ln = new LdapName("t=#08");
        assertEquals("t=#08", ln.toString());
    }
View Full Code Here

     * <p>
     * The expected result is zero because the name is empty.
     * </p>
     */
    public void testSize001() throws Exception {
        LdapName ln = new LdapName("");
        assertEquals(0, ln.size());
    }
View Full Code Here

     * The expected result is the correct number of Rdns.
     * </p>
     */
    public void testSize002() throws Exception {
        String test = ("CN=commonName,L=localityName,ST=stateOrProvinceName,O=organizationName,OU=organizationalUnitName,C=countryName,STREET=streetAddress,DC=domainComponent,UID=userid");
        LdapName ln = new LdapName(test);
        assertEquals(9, ln.size());
    }
View Full Code Here

     * using distincts special characters to create the name. Notice that the
     * special character "+", associates attributes Types And Values.
     * </p>
     */
    public void testSize003() throws Exception {
        LdapName ln = new LdapName("t1=test+t2=test,t3=test;t4=test");
        assertEquals(3, ln.size());
    }
View Full Code Here

     * <p>
     * The expected result is a true.
     * </p>
     */
    public void testIsEmpty002() throws Exception {
        LdapName ln = new LdapName("t=test");
        ln.remove(0);
        assertTrue(ln.isEmpty());
    }
View Full Code Here

TOP

Related Classes of javax.naming.ldap.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.