Uploaded image for project: 'Directory ApacheDS'
  1. Directory ApacheDS
  2. DIRSERVER-314

Reversed operations: LdapName.getPrefix() and LdapName.getSuffix()

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Duplicate
    • None
    • None
    • None
    • None

    Description

      This code shows what we did wrong:

      org.apache.ldap.common.name.LdapName name = new org.apache.ldap.common.name.LdapName( "ou=a, ou=b, ou=c" );
      System.out.println( name.getPrefix( 1 ) );
      System.out.println( name.getPrefix( 2 ) );
      System.out.println( name.getSuffix( 1 ) );
      System.out.println( name.getSuffix( 2 ) );
      System.out.println( name.get( 0 ) );
      System.out.println( name.get( 1 ) );
      System.out.println( name.get( 2 ) );

      javax.naming.ldap.LdapName newName = new javax.naming.ldap.LdapName( "ou=a, ou=b, ou=c" );
      System.out.println( newName.getPrefix( 1 ) );
      System.out.println( newName.getPrefix( 2 ) );
      System.out.println( newName.getSuffix( 1 ) );
      System.out.println( newName.getSuffix( 2 ) );
      System.out.println( newName.get( 0 ) );
      System.out.println( newName.get( 1 ) );
      System.out.println( newName.get( 2 ) );

      Attachments

        Activity

          People

            akarasulu Alex Karasulu
            trustin Trustin Lee
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: