@Override public void rename(String oldName, String newName) throws NamingException { delegating.rename(oldName, newName); }
@Override public void rename(Name oldName, Name newName) throws NamingException { delegating.rename(oldName, newName); }
LdapName newLdapName = new LdapName(identityLdapName.getRdns().subList(0, identityLdapName.size()-1)); newLdapName.add(new Rdn(identityMapping.rdnIdentifier, renameTo)); identity.getDirContext().rename(identityLdapName, newLdapName);
public Object executeWithContext(DirContext ctx) throws javax.naming.NamingException { ctx.rename(oldDn, newDn); return null; } });
public Object executeWithContext(DirContext ctx) throws NamingException { ctx.rename(oldDn, newDn); return null; } });
@Override public synchronized void rename(String oldName, String newName) throws NamingException { this.delegate.rename(oldName, newName); }
public Object executeWithContext(DirContext ctx) throws javax.naming.NamingException { ctx.rename(oldDn, newDn); return null; } });
public Object executeWithContext(DirContext ctx) throws javax.naming.NamingException { ctx.rename(oldDn, newDn); return null; } });
public Object executeWithContext(DirContext ctx) throws javax.naming.NamingException { ctx.rename(oldDn, newDn); return null; } });
public Object executeWithContext(DirContext ctx) throws javax.naming.NamingException { ctx.rename(oldDn, newDn); return null; } });
public Object executeWithContext(DirContext ctx) throws NamingException { ctx.rename(oldDn, newDn); return null; } });
public Object executeWithContext(DirContext ctx) throws NamingException { ctx.rename(oldDn, newDn); return null; } });
@Override public synchronized void rename(Name oldName, Name newName) throws NamingException { this.delegate.rename(oldName, newName); }
public Object executeWithContext(DirContext ctx) throws NamingException { ctx.rename(oldDn, newDn); return null; } });
public Object executeWithContext(DirContext ctx) throws javax.naming.NamingException { ctx.rename(oldDn, newDn); return null; } });
public Object executeWithContext(DirContext ctx) throws javax.naming.NamingException { ctx.rename(oldDn, newDn); return null; } });
@Override public void rename(Name oldName, Name newName) throws NamingException { delegating.rename(oldName, newName); }
public void renameEntry(Name oldDN, Name newDN) throws NamingException { Name rdn = newDN.getSuffix(newDN.size() - 1); Name oldRdn = oldDN.getSuffix(oldDN.size() - 1); if (!oldRdn.toString().equals(rdn.toString())) ctx.rename(oldDN, rdn); }
@Test public void testRename() throws Exception { expectGetReadWriteContext(); tested.rename(oldNameMock, newNameMock); verify(dirContextMock).rename(oldNameMock, newNameMock); verify(dirContextMock).close(); }
@Test public void testRename_String() throws Exception { expectGetReadWriteContext(); tested.rename("o=example.com", "o=somethingelse.com"); verify(dirContextMock).rename("o=example.com", "o=somethingelse.com"); verify(dirContextMock).close(); } }