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 2006-2008 Sun Microsystems, Inc.
025 *      Portions Copyright 2013-2015 ForgeRock AS.
026 */
027package org.opends.server.types.operation;
028
029
030
031import java.util.Set;
032
033import org.forgerock.opendj.ldap.ByteString;
034import org.forgerock.opendj.ldap.DereferenceAliasesPolicy;
035import org.opends.server.types.DN;
036import org.opends.server.types.RawFilter;
037import org.forgerock.opendj.ldap.SearchScope;
038import org.opends.server.types.SearchFilter;
039
040
041
042/**
043 * This class defines a set of methods that are available for use by
044 * post-operation plugins for search operations.  Note that this
045 * interface is intended only to define an API for use by plugins and
046 * is not intended to be implemented by any custom classes.
047 */
048@org.opends.server.types.PublicAPI(
049     stability=org.opends.server.types.StabilityLevel.UNCOMMITTED,
050     mayInstantiate=false,
051     mayExtend=false,
052     mayInvoke=true)
053public interface PostOperationSearchOperation
054       extends PostOperationOperation
055{
056  /**
057   * Retrieves the raw, unprocessed base DN as included in the request
058   * from the client.  This may or may not contain a valid DN, as no
059   * validation will have been performed.
060   *
061   * @return  The raw, unprocessed base DN as included in the request
062   *          from the client.
063   */
064  ByteString getRawBaseDN();
065
066
067
068  /**
069   * Retrieves the base DN for this search operation.
070   *
071   * @return  The base DN for this search operation.
072   */
073  DN getBaseDN();
074
075
076
077  /**
078   * Retrieves the scope for this search operation.
079   *
080   * @return  The scope for this search operation.
081   */
082  SearchScope getScope();
083
084
085
086  /**
087   * Retrieves the alias dereferencing policy for this search
088   * operation.
089   *
090   * @return  The alias dereferencing policy for this search
091   *          operation.
092   */
093  DereferenceAliasesPolicy getDerefPolicy();
094
095
096
097  /**
098   * Retrieves the size limit for this search operation.
099   *
100   * @return  The size limit for this search operation.
101   */
102  int getSizeLimit();
103
104
105
106  /**
107   * Retrieves the time limit for this search operation.
108   *
109   * @return  The time limit for this search operation.
110   */
111  int getTimeLimit();
112
113
114
115  /**
116   * Retrieves the typesOnly flag for this search operation.
117   *
118   * @return  The typesOnly flag for this search operation.
119   */
120  boolean getTypesOnly();
121
122
123
124  /**
125   * Retrieves the raw, unprocessed search filter as included in the
126   * request from the client.  It may or may not contain a valid
127   * filter (e.g., unsupported attribute types or values with an
128   * invalid syntax) because no validation will have been performed on
129   * it.
130   *
131   * @return  The raw, unprocessed search filter as included in the
132   *          request from the client.
133   */
134  RawFilter getRawFilter();
135
136
137
138  /**
139   * Retrieves the filter for this search operation.
140   *
141   * @return  The filter for this search operation.
142   */
143  SearchFilter getFilter();
144
145
146
147  /**
148   * Retrieves the set of requested attributes for this search
149   * operation.  Its contents should not be altered.
150   *
151   * @return  The set of requested attributes for this search
152   *          operation.
153   */
154  Set<String> getAttributes();
155
156
157
158  /**
159   * Retrieves the number of entries sent to the client for this
160   * search operation.
161   *
162   * @return  The number of entries sent to the client for this search
163   *          operation.
164   */
165  int getEntriesSent();
166
167
168
169  /**
170   * Retrieves the number of search references sent to the client for
171   * this search operation.
172   *
173   * @return  The number of search references sent to the client for
174   *          this search operation.
175   */
176  int getReferencesSent();
177}
178