java.lang.Object
org.eclipse.persistence.internal.oxm.IDResolver
- Direct Known Subclasses:
IDResolver
IDResolver can be subclassed to allow customization of the ID/IDREF processing of Unmarshaller. A custom IDResolver can be specified on the Unmarshaller as follows:
IDResolver customResolver = new MyIDResolver();
unmarshaller.setIDResolver(customResolver);
- Since:
- EclipseLink 2.5.0
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionabstract void
Bind the objectobj
to the identifierid
.abstract void
Bind the objectobj
to the composite key information specified in theid
Map.void
Called when unmarshalling ends.abstract Callable
<?> Resolve the object of Classtype
, uniquely identified byid
.abstract Callable
<?> Resolve the object of Classtype
, uniquely identified by the composite key information specified in theid
Map.void
startDocument
(ErrorHandler errorHandler) Called when unmarshalling begins.
-
Constructor Details
-
IDResolver
protected IDResolver()Default constructor.
-
-
Method Details
-
resolve
Resolve the object of Class
type
, uniquely identified byid
.- Parameters:
id
- TheObject
that uniquely identifies the object to be found.type
- TheClass
of the object to be found.- Returns:
- a
Callable
that will return the resolved object. - Throws:
SAXException
-
resolve
Resolve the object of Class
type
, uniquely identified by the composite key information specified in theid
Map.- Parameters:
id
- AMap
of id values, keyed on the attribute name.type
- TheClass
of the object to be found.- Returns:
- a
Callable
that will return the resolved object. - Throws:
SAXException
-
bind
Bind the object
obj
to the identifierid
.- Parameters:
id
- The idObject
that uniquely identifies the object to be bound.obj
- The object that will be bound to this id.- Throws:
SAXException
-
bind
Bind the object
obj
to the composite key information specified in theid
Map.- Parameters:
id
- AMap
of id values, keyed on attribute name.obj
- The object that will be bound to this id.- Throws:
SAXException
-
startDocument
Called when unmarshalling begins.
- Parameters:
errorHandler
- Any errors encountered during the unmarshal process should be reported to this handler.- Throws:
SAXException
-
endDocument
Called when unmarshalling ends.
- Throws:
SAXException
-