01: package uk.org.ponder.saxalizer;
02:
03: /** The DeSAXalizable interface is implemented by any object wishing
04: * to call on the services of the DeSAXalizer class for serialization to
05: * a SAX stream. The interface requires the object to report
06: * a list of get methods for querying existing subobjects
07: * requiring serialisation. */
08:
09: public interface DeSAXalizable {
10: /** This method returns a list of <code>get</code> methods which the <code>DeSAXalizer</code>
11: * will call when wishes to write this object to a stream.
12: * The <code>DeSAXalizer</code> will call this method on one object of each
13: * <code>DeSAXalizable</code> class that it decides to serialize to an XML stream.
14: * <p>The returned array of method specifications has an entry specifying the
15: * XML tagname, method name and return type of each suitable get method of this
16: * class. The <code>DeSAXalizer</code> will use reflection to locate and invoke
17: * the specified method, so it must be a public method of a public class.
18: *
19: * @return An array of get method specifications; <code>null</code> is allowed if
20: * there are no such get methods.
21: */
22: SAXAccessMethodSpec[] getSAXGetMethods();
23:
24: }
|