< prev index next >

src/java.naming/share/classes/javax/naming/ldap/InitialLdapContext.java

Print this page


   1 /*
   2  * Copyright (c) 1999, 2019, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.  Oracle designates this
   8  * particular file as subject to the "Classpath" exception as provided
   9  * by Oracle in the LICENSE file that accompanied this code.
  10  *
  11  * This code is distributed in the hope that it will be useful, but WITHOUT
  12  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  14  * version 2 for more details (a copy is included in the LICENSE file that
  15  * accompanied this code).
  16  *
  17  * You should have received a copy of the GNU General Public License version
  18  * 2 along with this work; if not, write to the Free Software Foundation,
  19  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  20  *
  21  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22  * or visit www.oracle.com if you need additional information or have any
  23  * questions.
  24  */
  25 
  26 package javax.naming.ldap;
  27 
  28 import javax.naming.*;
  29 import javax.naming.directory.*;
  30 
  31 import java.util.Hashtable;
  32 
  33 /**
  34   * This class is the starting context for performing
  35   * LDAPv3-style extended operations and controls.
  36   *<p>
  37   * See {@code javax.naming.InitialContext} and
  38   * {@code javax.naming.InitialDirContext} for details on synchronization,
  39   * and the policy for how an initial context is created.
  40   *
  41   * <h2>Request Controls</h2>
  42   * When you create an initial context ({@code InitialLdapContext}),
  43   * you can specify a list of request controls.
  44   * These controls will be used as the request controls for any
  45   * implicit LDAP "bind" operation performed by the context or contexts
  46   * derived from the context. These are called <em>connection request controls</em>.
  47   * Use {@code getConnectControls()} to get a context's connection request
  48   * controls.
  49   *<p>
  50   * The request controls supplied to the initial context constructor
  51   * are <em>not</em> used as the context request controls
  52   * for subsequent context operations such as searches and lookups.
  53   * Context request controls are set and updated by using
  54   * {@code setRequestControls()}.
  55   *<p>
  56   * As shown, there can be two different sets of request controls
  57   * associated with a context: connection request controls and context
  58   * request controls.
  59   * This is required for those applications needing to send critical
  60   * controls that might not be applicable to both the context operation and
  61   * any implicit LDAP "bind" operation.


   1 /*
   2  * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.  Oracle designates this
   8  * particular file as subject to the "Classpath" exception as provided
   9  * by Oracle in the LICENSE file that accompanied this code.
  10  *
  11  * This code is distributed in the hope that it will be useful, but WITHOUT
  12  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  14  * version 2 for more details (a copy is included in the LICENSE file that
  15  * accompanied this code).
  16  *
  17  * You should have received a copy of the GNU General Public License version
  18  * 2 along with this work; if not, write to the Free Software Foundation,
  19  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  20  *
  21  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22  * or visit www.oracle.com if you need additional information or have any
  23  * questions.
  24  */
  25 
  26 package javax.naming.ldap;
  27 
  28 import javax.naming.*;
  29 import javax.naming.directory.*;
  30 
  31 import java.util.Hashtable;
  32 
  33 /**
  34   * This class is the starting context for performing
  35   * LDAPv3-style extended operations and controls.
  36   *<p>
  37   * See {@code javax.naming.InitialContext} and
  38   * {@code javax.naming.InitialDirContext} for details on synchronization,
  39   * and the policy for how an initial context is created.
  40   *
  41   * <h1>Request Controls</h1>
  42   * When you create an initial context ({@code InitialLdapContext}),
  43   * you can specify a list of request controls.
  44   * These controls will be used as the request controls for any
  45   * implicit LDAP "bind" operation performed by the context or contexts
  46   * derived from the context. These are called <em>connection request controls</em>.
  47   * Use {@code getConnectControls()} to get a context's connection request
  48   * controls.
  49   *<p>
  50   * The request controls supplied to the initial context constructor
  51   * are <em>not</em> used as the context request controls
  52   * for subsequent context operations such as searches and lookups.
  53   * Context request controls are set and updated by using
  54   * {@code setRequestControls()}.
  55   *<p>
  56   * As shown, there can be two different sets of request controls
  57   * associated with a context: connection request controls and context
  58   * request controls.
  59   * This is required for those applications needing to send critical
  60   * controls that might not be applicable to both the context operation and
  61   * any implicit LDAP "bind" operation.


< prev index next >