|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface GenericObjectModelFactory
Direct implementations of ObjectModelFactory
interface can be thought of as "typed" factories
in a sense that parameter types of newChild
, addChild
and setValue
methods
(discovered by the framework at runtime with introspection) are supposed to be of specific Java classes
(other than java.lang.Object
) from the target class hierarchy.
newChild
, addChild
and setValue
methods are defined
with arguments of type java.lang.Object
.
newChild
, addChild
and setValue
methods.
Instead it will call the declared generic methods and it's the responsibility of the implementation
of this interface to recognize the types and build the object graph appropriately.
Method Summary | |
---|---|
void |
addChild(Object parent,
Object child,
UnmarshallingContext ctx,
String namespaceURI,
String localName)
This method is called when parsing of a not top-level XML element completed. |
Object |
newChild(Object parent,
UnmarshallingContext ctx,
String namespaceURI,
String localName,
Attributes attrs)
This method is called when parsing of a new not top-level XML element started. |
void |
setValue(Object o,
UnmarshallingContext ctx,
String namespaceURI,
String localName,
String value)
This method is called when a new not top-level simple XML element (with text content) was parsed. |
Methods inherited from interface org.jboss.xb.binding.ObjectModelFactory |
---|
completeRoot, newRoot |
Method Detail |
---|
Object newChild(Object parent, UnmarshallingContext ctx, String namespaceURI, String localName, Attributes attrs)
parent
- an object that represents the parent XML element in the object modelctx
- unmarshalling contextnamespaceURI
- namespace URI of the XML elementlocalName
- local name of the XML elementattrs
- attributes of the XML element
void addChild(Object parent, Object child, UnmarshallingContext ctx, String namespaceURI, String localName)
parent
- an object that represents the parent XML element in the object modelchild
- an object that was returned by the newChild
method that
was called when parsing of this XML element startedctx
- unmarshalling contextnamespaceURI
- namespace URI of the XML elementlocalName
- local name of the XML elementvoid setValue(Object o, UnmarshallingContext ctx, String namespaceURI, String localName, String value)
o
- an object that represents the parent XML element in the Java object modelctx
- unmarshalling contextnamespaceURI
- namespace URI of the XML elementlocalName
- local name of the XML elementvalue
- value of the XML element as it appears in the XML content
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |