001/* 002 * CDDL HEADER START 003 * 004 * The contents of this file are subject to the terms of the 005 * Common Development and Distribution License, Version 1.0 only 006 * (the "License"). You may not use this file except in compliance 007 * with the License. 008 * 009 * You can obtain a copy of the license at legal-notices/CDDLv1_0.txt 010 * or http://forgerock.org/license/CDDLv1.0.html. 011 * See the License for the specific language governing permissions 012 * and limitations under the License. 013 * 014 * When distributing Covered Code, include this CDDL HEADER in each 015 * file and include the License file at legal-notices/CDDLv1_0.txt. 016 * If applicable, add the following below this CDDL HEADER, with the 017 * fields enclosed by brackets "[]" replaced with your own identifying 018 * information: 019 * Portions Copyright [yyyy] [name of copyright owner] 020 * 021 * CDDL HEADER END 022 * 023 * 024 * Copyright 2008 Sun Microsystems, Inc. 025 * Portions Copyright 2014-2015 ForgeRock AS 026 */ 027package org.opends.server.types.operation; 028 029 030 031import org.opends.server.types.*; 032import org.forgerock.opendj.ldap.ByteString; 033 034 035/** 036 * This class defines a set of methods that are available for use by 037 * subordinate modify DN operation plugins. Note that this interface 038 * is intended only to define an API for use by plugins and is not 039 * intended to be implemented by any custom classes. 040 */ 041@org.opends.server.types.PublicAPI( 042 stability=org.opends.server.types.StabilityLevel.UNCOMMITTED, 043 mayInstantiate=false, 044 mayExtend=false, 045 mayInvoke=true) 046public interface SubordinateModifyDNOperation 047 extends InProgressOperation 048{ 049 /** 050 * Retrieves the raw, unprocessed entry DN as included in the client 051 * request. The DN that is returned may or may not be a valid DN, 052 * since no validation will have been performed upon it. 053 * 054 * @return The raw, unprocessed entry DN as included in the client 055 * request. 056 */ 057 ByteString getRawEntryDN(); 058 059 060 061 /** 062 * Retrieves the DN of the entry to rename. This should not be 063 * called by pre-parse plugins because the processed DN will not be 064 * available yet. Instead, they should call the 065 * {@code getRawEntryDN} method. 066 * 067 * @return The DN of the entry to rename, or {@code null} if the 068 * raw entry DN has not yet been processed. 069 */ 070 DN getEntryDN(); 071 072 073 074 /** 075 * Retrieves the raw, unprocessed newRDN as included in the request 076 * from the client. This may or may not contain a valid RDN, as no 077 * validation will have been performed on it. 078 * 079 * @return The raw, unprocessed newRDN as included in the request 080 * from the client. 081 */ 082 ByteString getRawNewRDN(); 083 084 085 086 /** 087 * Retrieves the new RDN to use for the entry. This should not be 088 * called by pre-parse plugins, because the processed newRDN will 089 * not yet be available. Pre-parse plugins should instead use the 090 * {@code getRawNewRDN} method. 091 * 092 * @return The new RDN to use for the entry, or {@code null} if the 093 * raw newRDN has not yet been processed. 094 */ 095 RDN getNewRDN(); 096 097 098 099 /** 100 * Indicates whether the current RDN value should be removed from 101 * the entry. 102 * 103 * @return {@code true} if the current RDN value should be removed 104 * from the entry, or {@code false} if not. 105 */ 106 boolean deleteOldRDN(); 107 108 109 110 /** 111 * Retrieves the raw, unprocessed newSuperior from the client 112 * request. This may or may not contain a valid DN, as no 113 * validation will have been performed on it. 114 * 115 * @return The raw, unprocessed newSuperior from the client 116 * request, or {@code null} if there is none. 117 */ 118 ByteString getRawNewSuperior(); 119 120 121 122 /** 123 * Retrieves the newSuperior DN for the entry. This should not be 124 * called by pre-parse plugins, because the processed DN will not 125 * yet be available at that time. Instead, they should use the 126 * {@code getRawNewSuperior} method. 127 * 128 * @return The newSuperior DN for the entry, or {@code null} if 129 * there is no newSuperior DN for this request or if the 130 * raw newSuperior has not yet been processed. 131 */ 132 DN getNewSuperior(); 133 134 135 136 /** 137 * Retrieves the current entry, before it is renamed. This will not 138 * be available to pre-parse plugins or during the conflict 139 * resolution portion of the synchronization processing. 140 * 141 * @return The current entry, or {@code null} if it is not yet 142 * available. 143 */ 144 Entry getOriginalEntry(); 145 146 147 148 /** 149 * Retrieves the new entry, as it will appear after it is renamed. 150 * This will not be available to pre-parse plugins or during the 151 * conflict resolution portion of the synchronization processing. 152 * 153 * @return The updated entry, or {@code null} if it is not yet 154 * available. 155 */ 156 Entry getUpdatedEntry(); 157} 158