--- old/src/java.naming/share/classes/javax/naming/spi/NamingManager.java 2015-08-04 13:15:10.208901188 +0300 +++ new/src/java.naming/share/classes/javax/naming/spi/NamingManager.java 2015-08-04 13:15:09.824901179 +0300 @@ -49,7 +49,7 @@ * NamingManager is safe for concurrent access by multiple threads. *
* Except as otherwise noted, - * a Name or environment parameter + * a {@code Name} or environment parameter * passed to any method is owned by the caller. * The implementation will not modify the object or keep a reference * to it, although it may keep a reference to a clone or copy. @@ -164,8 +164,8 @@ /** * Creates an object using the factories specified in the - * Context.OBJECT_FACTORIES property of the environment - * or of the provider resource file associated with nameCtx. + * {@code Context.OBJECT_FACTORIES} property of the environment + * or of the provider resource file associated with {@code nameCtx}. * * @return factory created; null if cannot create */ @@ -205,69 +205,69 @@ * create a factory for creating the object. * Otherwise, the following rules are used to create the object: *
refInfo
is a Reference
- * or Referenceable
containing a factory class name,
+ * refInfo
if the factory cannot be created.
+ * Return {@code refInfo} if the factory cannot be created.
* Under JDK 1.1, if the factory class must be loaded from a location
- * specified in the reference, a SecurityManager must have
+ * specified in the reference, a {@code SecurityManager} must have
* been installed or the factory creation will fail.
* If an exception is encountered while creating the factory,
* it is passed up to the caller.
- * refInfo
.
+ * return {@code refInfo}.
* If an exception is encountered while creating the object, the
* exception is passed up to the caller.
*- * Service providers that implement the DirContext + * Service providers that implement the {@code DirContext} * interface should use - * DirectoryManager.getObjectInstance(), not this method. - * Service providers that implement only the Context + * {@code DirectoryManager.getObjectInstance()}, not this method. + * Service providers that implement only the {@code Context} * interface should use this method. *
* Note that an object factory (an object that implements the ObjectFactory * interface) must be public and must have a public constructor that * accepts no arguments. *
- * The name
and nameCtx
parameters may
+ * The {@code name} and {@code nameCtx} parameters may
* optionally be used to specify the name of the object being created.
- * name
is the name of the object, relative to context
- * nameCtx
. This information could be useful to the object
+ * {@code name} is the name of the object, relative to context
+ * {@code nameCtx}. This information could be useful to the object
* factory or to the object implementation.
* If there are several possible contexts from which the object
* could be named -- as will often be the case -- it is up to
* the caller to select one. A good rule of thumb is to select the
* "deepest" context available.
- * If nameCtx
is null, name
is relative
+ * If {@code nameCtx} is null, {@code name} is relative
* to the default initial context. If no name is being specified, the
- * name
parameter should be null.
+ * {@code name} parameter should be null.
*
* @param refInfo The possibly null object for which to create an object.
- * @param name The name of this object relative to nameCtx
.
+ * @param name The name of this object relative to {@code nameCtx}.
* Specifying a name is optional; if it is
- * omitted, name
should be null.
- * @param nameCtx The context relative to which the name
- * parameter is specified. If null, name
is
+ * omitted, {@code name} should be null.
+ * @param nameCtx The context relative to which the {@code name}
+ * parameter is specified. If null, {@code name} is
* relative to the default initial context.
* @param environment The possibly null environment to
* be used in the creation of the object factory and the object.
- * @return An object created using refInfo
; or
- * refInfo
if an object cannot be created using
+ * @return An object created using {@code refInfo}; or
+ * {@code refInfo} if an object cannot be created using
* the algorithm described above.
* @exception NamingException if a naming exception was encountered
* while attempting to get a URL context, or if one of the
@@ -404,23 +404,23 @@
/**
- * Retrieves a context identified by obj
, using the specified
+ * Retrieves a context identified by {@code obj}, using the specified
* environment.
* Used by ContinuationContext.
*
* @param obj The object identifying the context.
* @param name The name of the context being returned, relative to
- * nameCtx
, or null if no name is being
+ * {@code nameCtx}, or null if no name is being
* specified.
- * See the getObjectInstance
method for
+ * See the {@code getObjectInstance} method for
* details.
- * @param nameCtx The context relative to which name
is
+ * @param nameCtx The context relative to which {@code name} is
* specified, or null for the default initial context.
- * See the getObjectInstance
method for
+ * See the {@code getObjectInstance} method for
* details.
* @param environment Environment specifying characteristics of the
* resulting context.
- * @return A context identified by obj
.
+ * @return A context identified by {@code obj}.
*
* @see #getObjectInstance
*/
@@ -480,7 +480,7 @@
* Creates a context for the given URL scheme id.
*
* The resulting context is for resolving URLs of the
- * scheme scheme
. The resulting context is not tied
+ * scheme {@code scheme}. The resulting context is not tied
* to a specific URL. It is able to handle arbitrary URLs with
* the specified scheme.
*
@@ -488,7 +488,7 @@ * has the naming convention scheme-idURLContextFactory * (e.g. "ftpURLContextFactory" for the "ftp" scheme-id), * in the package specified as follows. - * The Context.URL_PKG_PREFIXES environment property (which + * The {@code Context.URL_PKG_PREFIXES} environment property (which * may contain values taken from system properties, * or application resource files) * contains a colon-separated list of package prefixes. @@ -500,7 +500,7 @@ * concatenated with the scheme id. *
* For example, if the scheme id is "ldap", and the - * Context.URL_PKG_PREFIXES property + * {@code Context.URL_PKG_PREFIXES} property * contains "com.widget:com.wiz.jndi", * the naming manager would attempt to load the following classes * until one is successfully instantiated: @@ -514,7 +514,7 @@ * If a factory is instantiated, it is invoked with the following * parameters to produce the resulting context. *
- * factory.getObjectInstance(null, environment);
+ * {@code factory.getObjectInstance(null, environment);}
*
* For example, invoking getObjectInstance() as shown above
* on a LDAP URL context factory would return a
@@ -530,8 +530,8 @@
* @param environment The possibly null environment properties to be
* used in the creation of the object factory and the context.
* @return A context for resolving URLs with the
- * scheme id scheme
;
- * null
if the factory for creating the
+ * scheme id {@code scheme};
+ * {@code null} if the factory for creating the
* context is not found.
* @exception NamingException If a naming exception occurs while creating
* the context.
@@ -575,7 +575,7 @@
* context factory for the URL scheme.
* @param scheme the URL scheme id for the context
* @param urlInfo information used to create the context
- * @param name name of this object relative to nameCtx
+ * @param name name of this object relative to {@code nameCtx}
* @param nameCtx Context whose provider resource file will be searched
* for package prefix values (or null if none)
* @param environment Environment properties for creating the context
@@ -630,7 +630,7 @@
* it is used to create the factory for creating the initial
* context
*
CannotProceedException
containing information
+ * {@code CannotProceedException} containing information
* pinpointing how far it has proceeded. It then obtains a
* continuation context from JNDI by calling
- * getContinuationContext
. The context
+ * {@code getContinuationContext}. The context
* implementation should then resume the context operation by
* invoking the same operation on the continuation context, using
* the remainder of the name that has not yet been resolved.
*- * Before making use of the cpe parameter, this method + * Before making use of the {@code cpe} parameter, this method * updates the environment associated with that object by setting - * the value of the property CPE - * to cpe. This property will be inherited by the + * the value of the property {@code CPE} + * to {@code cpe}. This property will be inherited by the * continuation context, and may be used by that context's * service provider to inspect the fields of this exception. * @@ -826,15 +826,15 @@ /** * Retrieves the state of an object for binding. *
- * Service providers that implement the DirContext interface - * should use DirectoryManager.getStateToBind(), not this method. - * Service providers that implement only the Context interface + * Service providers that implement the {@code DirContext} interface + * should use {@code DirectoryManager.getStateToBind()}, not this method. + * Service providers that implement only the {@code Context} interface * should use this method. *
* This method uses the specified state factories in - * the Context.STATE_FACTORIES property from the environment + * the {@code Context.STATE_FACTORIES} property from the environment * properties, and from the provider resource file associated with - * nameCtx, in that order. + * {@code nameCtx}, in that order. * The value of this property is a colon-separated list of factory * class names that are tried in order, and the first one that succeeds * in returning the object's state is the one used. @@ -848,35 +848,35 @@ * interface) must be public and must have a public constructor that * accepts no arguments. *
- * The name
and nameCtx
parameters may
+ * The {@code name} and {@code nameCtx} parameters may
* optionally be used to specify the name of the object being created.
* See the description of "Name and Context Parameters" in
* {@link ObjectFactory#getObjectInstance
* ObjectFactory.getObjectInstance()}
* for details.
*
- * This method may return a Referenceable object. The
+ * This method may return a {@code Referenceable} object. The
* service provider obtaining this object may choose to store it
* directly, or to extract its reference (using
- * Referenceable.getReference()) and store that instead.
+ * {@code Referenceable.getReference()}) and store that instead.
*
* @param obj The non-null object for which to get state to bind.
- * @param name The name of this object relative to nameCtx
,
+ * @param name The name of this object relative to {@code nameCtx},
* or null if no name is specified.
- * @param nameCtx The context relative to which the name
- * parameter is specified, or null if name
is
+ * @param nameCtx The context relative to which the {@code name}
+ * parameter is specified, or null if {@code name} is
* relative to the default initial context.
* @param environment The possibly null environment to
* be used in the creation of the state factory and
* the object's state.
- * @return The non-null object representing obj's state for
- * binding. It could be the object (obj) itself.
+ * @return The non-null object representing {@code obj}'s state for
+ * binding. It could be the object ({@code obj}) itself.
* @exception NamingException If one of the factories accessed throws an
* exception, or if an error was encountered while loading
* and instantiating the factory and object classes.
* A factory should only throw an exception if it does not want
* other factories to be used in an attempt to create an object.
- * See StateFactory.getStateToBind().
+ * See {@code StateFactory.getStateToBind()}.
* @see StateFactory
* @see StateFactory#getStateToBind
* @see DirectoryManager#getStateToBind