/** * Set the Distinguished Name * * @param dn * The Distinguished Name */ public void setDn( DN dn ) { entry.setDn( (DN)dn.clone() ); }
clone.dn = (DN)dn.clone();
clone.setDn( (DN)dn.clone() );
/** * Checks to see if two names are siblings. * * @param name1 the first name * @param name2 the second name * @return true if the names are siblings, false otherwise. */ public static boolean isSibling( DN name1, DN name2 ) throws LdapInvalidDnException { if ( name1.size() == name2.size() ) { DN parentDn = ( DN ) name1.clone(); parentDn.remove( name1.size() - 1 ); return name2.isChildOf( parentDn ); } return false; }
rdn = ( DN ) descendant.clone();
dn = (DN)entry.getDn().clone();
DN newParentDNClone = ( DN ) newParentDn.clone(); newParentDNClone.remove( newParentDNClone.size() - 1 );
ancestorDn = ( DN ) aliasDn.clone(); ancestorDn.remove( aliasDn.size() - 1 ); ancestorId = getEntryId( ancestorDn.getNormName() ); DN normalizedAliasTargetParentDn = ( DN ) normalizedAliasTargetDn.clone(); normalizedAliasTargetParentDn.remove( normalizedAliasTargetDn.size() - 1 ); if ( !aliasDn.isChildOf( normalizedAliasTargetParentDn ) )
DN aliasDN = ( DN ) new DN( aliasDn ); DN ancestorDn = ( DN ) aliasDN.clone(); ancestorDn.remove( aliasDN.size() - 1 ); Long ancestorId = getEntryId( ancestorDn.getNormName() );
parentDn = ( DN ) normName.clone(); parentDn.remove( parentDn.size() - 1 ); parentId = getEntryId( parentDn.getNormName() );
DN childUpdn = ( DN ) updn.clone(); DN oldUpdn = new DN( getEntryUpdn( childId ) );
DN newUpdn = ( DN ) updn.clone(); // copy da old updn newUpdn.remove( newUpdn.size() - 1 ); // remove old upRdn