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