mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

neil_a_wilson
03.52.2007 e1ea3e0d8999105f144d2be98e0286928b8319ed
opends/src/server/org/opends/server/core/SearchOperation.java
@@ -102,9 +102,6 @@
                  PostOperationSearchOperation, PostResponseSearchOperation,
                  SearchEntrySearchOperation, SearchReferenceSearchOperation
{
  // Indicates whether a search result done response has been sent to the
  // client.
  private AtomicBoolean responseSent;
@@ -116,12 +113,18 @@
  // entries.
  private boolean includeUsableControl;
  // Indicates whether to only real attributes should be returned.
  private boolean realAttributesOnly;
  // Indicates whether LDAP subentries should be returned.
  private boolean returnLDAPSubentries;
  // Indicates whether to include attribute types only or both types and values.
  private boolean typesOnly;
  // Indicates whether to only virtual attributes should be returned.
  private boolean virtualAttributesOnly;
  // The raw, unprocessed base DN as included in the request from the client.
  private ByteString rawBaseDN;
@@ -274,6 +277,8 @@
    persistentSearch       = null;
    returnLDAPSubentries   = false;
    matchedValuesControl   = null;
    realAttributesOnly     = false;
    virtualAttributesOnly  = false;
  }
@@ -865,7 +870,8 @@
    Entry entryToReturn;
    if ((attributes == null) || attributes.isEmpty())
    {
      entryToReturn = entry.duplicateWithoutOperationalAttributes(typesOnly);
      entryToReturn = entry.duplicateWithoutOperationalAttributes(typesOnly,
                                                                  true);
    }
    else
    {
@@ -1028,6 +1034,16 @@
    }
    if (realAttributesOnly)
    {
      entryToReturn.stripVirtualAttributes();
    }
    else if (virtualAttributesOnly)
    {
      entryToReturn.stripRealAttributes();
    }
    // If there is a matched values control, then further pare down the entry
    // based on the filters that it contains.
    if ((matchedValuesControl != null) && (! typesOnly))
@@ -1877,6 +1893,14 @@
          {
            includeUsableControl = true;
          }
          else if (oid.equals(OID_REAL_ATTRS_ONLY))
          {
            realAttributesOnly = true;
          }
          else if (oid.equals(OID_VIRTUAL_ATTRS_ONLY))
          {
            virtualAttributesOnly = true;
          }
          // NYI -- Add support for additional controls.
          else if (c.isCritical())