1 package ar.com.epere4.java2excel.parser;
2
3 import java.util.Iterator;
4
5 /***
6 * This interface represents the body tag in the
7 * configuration xml file.
8 *
9 * Properties defined in this interface are documented in the dtd schema that
10 * you can find in the url defined by
11 * {@link ar.com.epere4.java2excel.parser.Parser#JAVA2EXCEL_SYSTEM_ID} or in the
12 * resource you can find in
13 * {@link ar.com.epere4.java2excel.parser.Parser#JAVA2EXCEL_LOCAL_DTD_URL}.
14 *
15 * @author epere4
16 * @since 06/02/2006
17 */
18 public interface BodyDtd {
19
20 /***
21 *
22 * @return an {@link Iterator} of
23 * {@link ar.com.epere4.java2excel.parser.PropertyDtd}.
24 */
25 Iterator propertiesIterator();
26
27 /***
28 * @return la propiedad includeExtraLevel.
29 * @since 18/02/2006
30 */
31 int getIncludeExtraLevel();
32
33 /***
34 * If {@link #getIncludeExtraLevel()} returns a value greater than -1, it
35 * will {@link #addProperty(PropertyDtd) add properties} to this instances
36 * that will be obtained by reflection from the beanClass. The beanClass
37 * will be search by reflection for properties up to the
38 * {@link #getIncludeExtraLevel() configured level}. See the
39 * comments in the dtd, for more details.
40 * After using this method, {@link #getIncludeExtraLevel()} will return -1;
41 *
42 * @param beanClass the class where properties will be read from.
43 * @since 20/02/2006
44 */
45 void completeProperties(Class beanClass);
46
47 /***
48 * Adds a property to this instance. Implementations must ensure that
49 * no similar properties can be added acording to
50 * {@link PropertyDtd#getExpression()}. If a similar property is added, it
51 * should overwrite the previous one.
52 * @param property the {@link PropertyDtd} to be added. These are the
53 * properties that will be returned by {@link BodyDtd#propertiesIterator()}.
54 * @since 18/02/2006
55 */
56 void addProperty(PropertyDtd property);
57 }