com.epam.xml.engine
Class SAXUnmarshaler<T>

java.lang.Object
  extended by com.epam.xml.engine.AbstractUnmarshaler<T>
      extended by com.epam.xml.engine.SAXUnmarshaler<T>
Type Parameters:
T -
All Implemented Interfaces:
UnmarshalerListener, XMLUnmarshaler<T>

public class SAXUnmarshaler<T>
extends AbstractUnmarshaler<T>
implements UnmarshalerListener

Author:
Serhiy_Zahriychuk

Field Summary
 
Fields inherited from class com.epam.xml.engine.AbstractUnmarshaler
xmlInstanceBuilder
 
Constructor Summary
SAXUnmarshaler()
           
 
Method Summary
 void endElement(String name)
          The end of element.
 void endMarshaling()
          (non-Javadoc)
 T getRootObject()
           
 void lookup(String name, Attributes attributes)
          Find the property with given name in current node.
 void setAttribute(String name, String value)
          Sets attribute value for property name.
 void setValue(String value)
          Sets the value for current element.
 void startElement(String name)
          The start of element.
 void startMarshaling()
          Start marshaling.
 T unmarshal(Class<?> source, DocumentReader documentReader, boolean replaceData)
           
 T unmarshal(T source, DocumentReader documentReader, boolean replaceData)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SAXUnmarshaler

public SAXUnmarshaler()
Method Detail

lookup

public void lookup(String name,
                   Attributes attributes)
Description copied from interface: UnmarshalerListener
Find the property with given name in current node.

Specified by:
lookup in interface UnmarshalerListener
Parameters:
name - the name of an element
attributes - the attributes of current element

setAttribute

public void setAttribute(String name,
                         String value)
Description copied from interface: UnmarshalerListener
Sets attribute value for property name.

Specified by:
setAttribute in interface UnmarshalerListener
Parameters:
name - the property name
value - the property value

setValue

public void setValue(String value)
Description copied from interface: UnmarshalerListener
Sets the value for current element.

Specified by:
setValue in interface UnmarshalerListener
Parameters:
value - the property value

startMarshaling

public void startMarshaling()
Description copied from interface: UnmarshalerListener
Start marshaling.

Specified by:
startMarshaling in interface UnmarshalerListener

endElement

public void endElement(String name)
Description copied from interface: UnmarshalerListener
The end of element.

Specified by:
endElement in interface UnmarshalerListener
Parameters:
name - the name of an element

startElement

public void startElement(String name)
Description copied from interface: UnmarshalerListener
The start of element.

Specified by:
startElement in interface UnmarshalerListener
Parameters:
name - the name of an element

getRootObject

public T getRootObject()

endMarshaling

public void endMarshaling()
(non-Javadoc)

Specified by:
endMarshaling in interface UnmarshalerListener
See Also:
UnmarshalerListener.endMarshaling()

unmarshal

public T unmarshal(Class<?> source,
                   DocumentReader documentReader,
                   boolean replaceData)
Specified by:
unmarshal in interface XMLUnmarshaler<T>

unmarshal

public T unmarshal(T source,
                   DocumentReader documentReader,
                   boolean replaceData)
Specified by:
unmarshal in interface XMLUnmarshaler<T>


Copyright © 2000-2014 EPAM Systems. All Rights Reserved.