ResolveResult (Java SE 11 & JDK 11 ) (original) (raw)
- javax.naming.spi.ResolveResult
All Implemented Interfaces:
[Serializable](../../../../java.base/java/io/Serializable.html "interface in java.io")
public class ResolveResult
extends Object
implements Serializable
This class represents the result of resolution of a name. It contains the object to which name was resolved, and the portion of the name that has not been resolved.
A ResolveResult instance is not synchronized against concurrent multithreaded access. Multiple threads trying to access and modify a single ResolveResult instance should lock the object.
Since:
1.3
See Also:
Serialized Form
Field Summary
Fields
Modifier and Type Field Description protected Name remainingName Field containing the remaining name yet to be resolved. protected Object resolvedObj Field containing the Object that was resolved to successfully. Constructor Summary
Constructors
Modifier Constructor Description protected ResolveResult() Constructs an instance of ResolveResult with the resolved object and remaining name both initialized to null. ResolveResult(Object robj,String rcomp) Constructs a new instance of ResolveResult consisting of the resolved object and the remaining unresolved component. ResolveResult(Object robj,Name rname) Constructs a new instance of ResolveResult consisting of the resolved Object and the remaining name. Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type Method Description void appendRemainingComponent(String name) Adds a single component to the end of remaining name. void appendRemainingName(Name name) Adds components to the end of remaining name. Name getRemainingName() Retrieves the remaining unresolved portion of the name. Object getResolvedObj() Retrieves the Object to which resolution was successful. void setRemainingName(Name name) Sets the remaining name field of this result to name. void setResolvedObj(Object obj) Sets the resolved Object field of this result to obj. * ### Methods declared in class java.lang.[Object](../../../../java.base/java/lang/Object.html "class in java.lang") `[clone](../../../../java.base/java/lang/Object.html#clone%28%29), [equals](../../../../java.base/java/lang/Object.html#equals%28java.lang.Object%29), [finalize](../../../../java.base/java/lang/Object.html#finalize%28%29), [getClass](../../../../java.base/java/lang/Object.html#getClass%28%29), [hashCode](../../../../java.base/java/lang/Object.html#hashCode%28%29), [notify](../../../../java.base/java/lang/Object.html#notify%28%29), [notifyAll](../../../../java.base/java/lang/Object.html#notifyAll%28%29), [toString](../../../../java.base/java/lang/Object.html#toString%28%29), [wait](../../../../java.base/java/lang/Object.html#wait%28%29), [wait](../../../../java.base/java/lang/Object.html#wait%28long%29), [wait](../../../../java.base/java/lang/Object.html#wait%28long,int%29)`
Field Detail
* #### resolvedObj protected [Object](../../../../java.base/java/lang/Object.html "class in java.lang") resolvedObj Field containing the Object that was resolved to successfully. It can be null only when constructed using a subclass. Constructors should always initialize this. * #### remainingName protected [Name](../Name.html "interface in javax.naming") remainingName Field containing the remaining name yet to be resolved. It can be null only when constructed using a subclass. Constructors should always initialize this.
Constructor Detail
* #### ResolveResult protected ResolveResult() Constructs an instance of ResolveResult with the resolved object and remaining name both initialized to null. * #### ResolveResult public ResolveResult([Object](../../../../java.base/java/lang/Object.html "class in java.lang") robj, [String](../../../../java.base/java/lang/String.html "class in java.lang") rcomp) Constructs a new instance of ResolveResult consisting of the resolved object and the remaining unresolved component. Parameters: `robj` \- The non-null object resolved to. `rcomp` \- The single remaining name component that has yet to be resolved. Cannot be null (but can be empty). * #### ResolveResult public ResolveResult([Object](../../../../java.base/java/lang/Object.html "class in java.lang") robj, [Name](../Name.html "interface in javax.naming") rname) Constructs a new instance of ResolveResult consisting of the resolved Object and the remaining name. Parameters: `robj` \- The non-null Object resolved to. `rname` \- The non-null remaining name that has yet to be resolved.
Method Detail
* #### getRemainingName public [Name](../Name.html "interface in javax.naming") getRemainingName() Retrieves the remaining unresolved portion of the name. Returns: The remaining unresolved portion of the name. Cannot be null but empty OK. See Also: [appendRemainingName(javax.naming.Name)](#appendRemainingName%28javax.naming.Name%29), [appendRemainingComponent(java.lang.String)](#appendRemainingComponent%28java.lang.String%29), [setRemainingName(javax.naming.Name)](#setRemainingName%28javax.naming.Name%29) * #### getResolvedObj public [Object](../../../../java.base/java/lang/Object.html "class in java.lang") getResolvedObj() Retrieves the Object to which resolution was successful. Returns: The Object to which resolution was successful. Cannot be null. See Also: [setResolvedObj(java.lang.Object)](#setResolvedObj%28java.lang.Object%29) * #### setRemainingName public void setRemainingName([Name](../Name.html "interface in javax.naming") name) Sets the remaining name field of this result to name. A copy of name is made so that modifying the copy within this ResolveResult does not affect `name` and vice versa. Parameters: `name` \- The name to set remaining name to. Cannot be null. See Also: [getRemainingName()](#getRemainingName%28%29), [appendRemainingName(javax.naming.Name)](#appendRemainingName%28javax.naming.Name%29), [appendRemainingComponent(java.lang.String)](#appendRemainingComponent%28java.lang.String%29) * #### appendRemainingName public void appendRemainingName([Name](../Name.html "interface in javax.naming") name) Adds components to the end of remaining name. Parameters: `name` \- The components to add. Can be null. See Also: [getRemainingName()](#getRemainingName%28%29), [setRemainingName(javax.naming.Name)](#setRemainingName%28javax.naming.Name%29), [appendRemainingComponent(java.lang.String)](#appendRemainingComponent%28java.lang.String%29) * #### appendRemainingComponent public void appendRemainingComponent([String](../../../../java.base/java/lang/String.html "class in java.lang") name) Adds a single component to the end of remaining name. Parameters: `name` \- The component to add. Can be null. See Also: [getRemainingName()](#getRemainingName%28%29), [appendRemainingName(javax.naming.Name)](#appendRemainingName%28javax.naming.Name%29) * #### setResolvedObj public void setResolvedObj([Object](../../../../java.base/java/lang/Object.html "class in java.lang") obj) Sets the resolved Object field of this result to obj. Parameters: `obj` \- The object to use for setting the resolved obj field. Cannot be null. See Also: [getResolvedObj()](#getResolvedObj%28%29)
Report a bug or suggest an enhancement
For further API reference and developer documentation see the Java SE Documentation, which contains more detailed, developer-targeted descriptions with conceptual overviews, definitions of terms, workarounds, and working code examples.
Java is a trademark or registered trademark of Oracle and/or its affiliates in the US and other countries.
Copyright © 1993, 2025, Oracle and/or its affiliates, 500 Oracle Parkway, Redwood Shores, CA 94065 USA.
All rights reserved. Use is subject to license terms and the documentation redistribution policy.