Class InitialDirContext
- java.lang.Object
-
- javax.naming.InitialContext
-
- javax.naming.directory.InitialDirContext
- All Implemented Interfaces:
-
Context
,DirContext
- Direct Known Subclasses:
InitialLdapContext
public class InitialDirContext extends InitialContext implements DirContext
This class is the starting context for performing directory operations. The documentation in the class description of InitialContext (including those for synchronization) apply here.
- Since:
- 1.3
- See Also:
InitialContext
Fields
Fields declared in class javax.naming.InitialContext
defaultInitCtx, gotDefault, myProps
Fields declared in interface javax.naming.Context
APPLET, AUTHORITATIVE, BATCHSIZE, DNS_URL, INITIAL_CONTEXT_FACTORY, LANGUAGE, OBJECT_FACTORIES, PROVIDER_URL, REFERRAL, SECURITY_AUTHENTICATION, SECURITY_CREDENTIALS, SECURITY_PRINCIPAL, SECURITY_PROTOCOL, STATE_FACTORIES, URL_PKG_PREFIXES
Fields declared in interface javax.naming.directory.DirContext
ADD_ATTRIBUTE, REMOVE_ATTRIBUTE, REPLACE_ATTRIBUTE
Constructors
Modifier | Constructor | Description |
---|---|---|
InitialDirContext() | Constructs an initial DirContext. | |
protected | InitialDirContext(boolean lazy) | Constructs an initial DirContext with the option of not initializing it. |
InitialDirContext(Hashtable<?,?> environment) | Constructs an initial DirContext using the supplied environment. |
Methods
Methods declared in class javax.naming.InitialContext
composeName, composeName, doLookup, doLookup, getDefaultInitCtx, getURLOrDefaultInitCtx, getURLOrDefaultInitCtx, init
Methods declared in class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods declared in interface javax.naming.Context
addToEnvironment, bind, bind, close, composeName, composeName, createSubcontext, createSubcontext, destroySubcontext, destroySubcontext, getEnvironment, getNameInNamespace, getNameParser, getNameParser, list, list, listBindings, listBindings, lookup, lookup, lookupLink, lookupLink, rebind, rebind, removeFromEnvironment, rename, rename, unbind, unbind
Methods declared in interface javax.naming.directory.DirContext
bind, bind, createSubcontext, createSubcontext, getAttributes, getAttributes, getAttributes, getAttributes, getSchema, getSchema, getSchemaClassDefinition, getSchemaClassDefinition, modifyAttributes, modifyAttributes, modifyAttributes, modifyAttributes, rebind, rebind, search, search, search, search, search, search, search, search
Constructors
InitialDirContext
protected InitialDirContext(boolean lazy) throws NamingException
Constructs an initial DirContext with the option of not initializing it. This may be used by a constructor in a subclass when the value of the environment parameter is not yet known at the time the InitialDirContext
constructor is called. The subclass's constructor will call this constructor, compute the value of the environment, and then call init()
before returning.
- Parameters:
-
lazy
- true means do not initialize the initial DirContext; false is equivalent to callingnew InitialDirContext()
- Throws:
-
NamingException
- if a naming exception is encountered - Since:
- 1.3
- See Also:
InitialContext.init(Hashtable)
InitialDirContext
public InitialDirContext() throws NamingException
Constructs an initial DirContext. No environment properties are supplied. Equivalent to new InitialDirContext(null)
.
- Throws:
-
NamingException
- if a naming exception is encountered - See Also:
InitialDirContext(Hashtable)
InitialDirContext
public InitialDirContext(Hashtable<?,?> environment) throws NamingException
Constructs an initial DirContext using the supplied environment. Environment properties are discussed in the javax.naming.InitialContext
class description.
This constructor will not modify environment
or save a reference to it, but may save a clone. Caller should not modify mutable keys and values in environment
after it has been passed to the constructor.
- Parameters:
-
environment
- environment used to create the initial DirContext. Null indicates an empty environment. - Throws:
-
NamingException
- if a naming exception is encountered
© 1993, 2020, Oracle and/or its affiliates. All rights reserved.
Documentation extracted from Debian's OpenJDK Development Kit package.
Licensed under the GNU General Public License, version 2, with the Classpath Exception.
Various third party code in OpenJDK is licensed under different licenses (see Debian package).
Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
https://docs.oracle.com/en/java/javase/11/docs/api/java.naming/javax/naming/directory/InitialDirContext.html