| | |
| | | } |
| | | else |
| | | { |
| | | DN parentDN = DirectoryServer.getParentDNInSuffix(entryDN); |
| | | DN parentDN = serverContext.getBackendConfigManager().getParentDNInSuffix(entryDN); |
| | | if (parentDN != null && entryMap.containsKey(parentDN)) |
| | | { |
| | | entryMap.put(entryDN, entry.duplicate(false)); |
| | |
| | | { |
| | | while (true) |
| | | { |
| | | parentDN = DirectoryServer.getParentDNInSuffix(parentDN); |
| | | parentDN = serverContext.getBackendConfigManager().getParentDNInSuffix(parentDN); |
| | | if (parentDN == null) |
| | | { |
| | | return null; |
| | |
| | | // Get the DN of the target entry's parent, if it exists. We'll need to |
| | | // also remove the reference to the target entry from the parent's set of |
| | | // children. |
| | | DN parentDN = DirectoryServer.getParentDNInSuffix(entryDN); |
| | | DN parentDN = serverContext.getBackendConfigManager().getParentDNInSuffix(entryDN); |
| | | |
| | | // Make sure that the target entry exists. If not, then fail. |
| | | if (! entryMap.containsKey(entryDN)) |
| | |
| | | break; |
| | | } |
| | | |
| | | parentDN = DirectoryServer.getParentDNInSuffix(parentDN); |
| | | parentDN = serverContext.getBackendConfigManager().getParentDNInSuffix(parentDN); |
| | | } |
| | | |
| | | LocalizableMessage m = ERR_LDIF_BACKEND_DELETE_NO_SUCH_ENTRY.get(entryDN); |
| | |
| | | if (! entryMap.containsKey(entryDN)) |
| | | { |
| | | DN matchedDN = null; |
| | | DN parentDN = DirectoryServer.getParentDNInSuffix(entryDN); |
| | | DN parentDN = serverContext.getBackendConfigManager().getParentDNInSuffix(entryDN); |
| | | while (parentDN != null) |
| | | { |
| | | if (entryMap.containsKey(parentDN)) |
| | |
| | | break; |
| | | } |
| | | |
| | | parentDN = DirectoryServer.getParentDNInSuffix(parentDN); |
| | | parentDN = serverContext.getBackendConfigManager().getParentDNInSuffix(parentDN); |
| | | } |
| | | |
| | | LocalizableMessage m = ERR_LDIF_BACKEND_MODIFY_NO_SUCH_ENTRY.get(entryDN); |
| | |
| | | if (! entryMap.containsKey(currentDN)) |
| | | { |
| | | DN matchedDN = null; |
| | | DN parentDN = DirectoryServer.getParentDNInSuffix(currentDN); |
| | | DN parentDN = serverContext.getBackendConfigManager().getParentDNInSuffix(currentDN); |
| | | while (parentDN != null) |
| | | { |
| | | if (entryMap.containsKey(parentDN)) |
| | |
| | | break; |
| | | } |
| | | |
| | | parentDN = DirectoryServer.getParentDNInSuffix(parentDN); |
| | | parentDN = serverContext.getBackendConfigManager().getParentDNInSuffix(parentDN); |
| | | } |
| | | |
| | | LocalizableMessage m = ERR_LDIF_BACKEND_MODDN_NO_SUCH_SOURCE_ENTRY.get(currentDN); |
| | |
| | | throw new DirectoryException(ResultCode.ENTRY_ALREADY_EXISTS, m); |
| | | } |
| | | |
| | | DN newParentDN = DirectoryServer.getParentDNInSuffix(newDN); |
| | | DN newParentDN = serverContext.getBackendConfigManager().getParentDNInSuffix(newDN); |
| | | if (! entryMap.containsKey(newParentDN)) |
| | | { |
| | | throw new DirectoryException(ResultCode.NO_SUCH_OBJECT, |
| | |
| | | |
| | | // Remove the entry from the list of children for the old parent and |
| | | // add the new entry DN to the set of children for the new parent. |
| | | DN oldParentDN = DirectoryServer.getParentDNInSuffix(currentDN); |
| | | DN oldParentDN = serverContext.getBackendConfigManager().getParentDNInSuffix(currentDN); |
| | | Set<DN> parentChildDNs = childDNs.get(oldParentDN); |
| | | if (parentChildDNs != null) |
| | | { |
| | |
| | | Entry baseEntry = entryMap.get(baseDN); |
| | | if (baseEntry == null && handlesEntry(baseDN)) |
| | | { |
| | | DN matchedDN = DirectoryServer.getParentDNInSuffix(baseDN); |
| | | DN matchedDN = serverContext.getBackendConfigManager().getParentDNInSuffix(baseDN); |
| | | while (matchedDN != null) |
| | | { |
| | | if (entryMap.containsKey(matchedDN)) |
| | |
| | | break; |
| | | } |
| | | |
| | | matchedDN = DirectoryServer.getParentDNInSuffix(matchedDN); |
| | | matchedDN = serverContext.getBackendConfigManager().getParentDNInSuffix(matchedDN); |
| | | } |
| | | |
| | | LocalizableMessage m = ERR_LDIF_BACKEND_SEARCH_NO_SUCH_BASE.get(baseDN); |
| | |
| | | continue; |
| | | } |
| | | |
| | | DN parentDN = DirectoryServer.getParentDNInSuffix(entryDN); |
| | | DN parentDN = serverContext.getBackendConfigManager().getParentDNInSuffix(entryDN); |
| | | if (parentDN == null || !entryMap.containsKey(parentDN)) |
| | | { |
| | | LocalizableMessage m = ERR_LDIF_BACKEND_MISSING_PARENT.get( |