Package org.simpleframework.xml.core
Class Composite.Builder
- java.lang.Object
-
- org.simpleframework.xml.core.Composite.Builder
-
- Direct Known Subclasses:
Composite.Injector
- Enclosing class:
- Composite
private static class Composite.Builder extends java.lang.Object
This takes the approach that the object is instantiated first and then the annotated fields and methods are deserialized from the XML elements and attributes. When all the details have be read they are set on the internal contacts of the object. This is used for places where we have a default no argument constructor.
-
-
Field Summary
Fields Modifier and Type Field Description protected Composite
composite
This is the composite converter that the builder will use.protected Criteria
criteria
This is the criteria object used to collect the values.protected Schema
schema
This is the schema object that contains the XML definition.protected Instance
value
This is the object instance created by the strategy object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object
read(InputNode node)
Thisread
method performs deserialization of the XML schema class type by traversing the contacts and using details from the provided XML element.
-
-
-
Field Detail
-
composite
protected final Composite composite
This is the composite converter that the builder will use.
-
criteria
protected final Criteria criteria
This is the criteria object used to collect the values.
-
schema
protected final Schema schema
This is the schema object that contains the XML definition.
-
value
protected final Instance value
This is the object instance created by the strategy object.
-
-
Constructor Detail
-
Builder
public Builder(Composite composite, Criteria criteria, Schema schema, Instance value)
Constructor for theBuilder
object. This creates a builder object capable of instantiating a object using a default no argument constructor. All fields are deserialized after the object has been instantiated.- Parameters:
composite
- this is the composite object used by thiscriteria
- this collects the objects being deserializedschema
- this is the class schema used by thisvalue
- this is the instance created by the strategy
-
-
Method Detail
-
read
public java.lang.Object read(InputNode node) throws java.lang.Exception
Thisread
method performs deserialization of the XML schema class type by traversing the contacts and using details from the provided XML element. Here an instance is created first then the contacts are traversed, this is done when a default constructor is the only option.- Parameters:
node
- the XML element that will be deserialized by this- Returns:
- this returns the fully deserialized object graph
- Throws:
java.lang.Exception
-
-