summaryrefslogtreecommitdiff
path: root/reportbuilder/java/com/sun/star/report/pentaho/parser/style/StyleDefinitionReadHandler.java
diff options
context:
space:
mode:
Diffstat (limited to 'reportbuilder/java/com/sun/star/report/pentaho/parser/style/StyleDefinitionReadHandler.java')
-rw-r--r--reportbuilder/java/com/sun/star/report/pentaho/parser/style/StyleDefinitionReadHandler.java87
1 files changed, 42 insertions, 45 deletions
diff --git a/reportbuilder/java/com/sun/star/report/pentaho/parser/style/StyleDefinitionReadHandler.java b/reportbuilder/java/com/sun/star/report/pentaho/parser/style/StyleDefinitionReadHandler.java
index 6eb99dec3ee0..0fd0655d4e22 100644
--- a/reportbuilder/java/com/sun/star/report/pentaho/parser/style/StyleDefinitionReadHandler.java
+++ b/reportbuilder/java/com/sun/star/report/pentaho/parser/style/StyleDefinitionReadHandler.java
@@ -27,8 +27,6 @@
* for a copy of the LGPLv3 License.
*
************************************************************************/
-
-
package com.sun.star.report.pentaho.parser.style;
import java.util.ArrayList;
@@ -48,54 +46,53 @@ import org.xml.sax.SAXException;
*/
public class StyleDefinitionReadHandler extends ElementReadHandler
{
- private final Section rawSection;
- private final List childs;
-
- public StyleDefinitionReadHandler()
- {
- this.rawSection = new Section();
- this.childs = new ArrayList();
- }
- /**
- * Returns the handler for a child element.
- *
- * @param tagName the tag name.
- * @param atts the attributes.
- * @return the handler or null, if the tagname is invalid.
- *
- * @throws org.xml.sax.SAXException if there is a parsing error.
- */
- protected XmlReadHandler getHandlerForChild(final String uri,
- final String tagName,
- final Attributes atts)
- throws SAXException
- {
- final StyleDefinitionReadHandler readHandler =
- new StyleDefinitionReadHandler();
- childs.add(readHandler);
- return readHandler;
- }
+ private final Section rawSection;
+ private final List childs;
+ public StyleDefinitionReadHandler()
+ {
+ this.rawSection = new Section();
+ this.childs = new ArrayList();
+ }
- /**
- * Done parsing.
- *
- * @throws org.xml.sax.SAXException if there is a parsing error.
- */
- protected void doneParsing()
- throws SAXException
- {
- for (int i = 0; i < childs.size(); i++)
+ /**
+ * Returns the handler for a child element.
+ *
+ * @param tagName the tag name.
+ * @param atts the attributes.
+ * @return the handler or null, if the tagname is invalid.
+ *
+ * @throws org.xml.sax.SAXException if there is a parsing error.
+ */
+ protected XmlReadHandler getHandlerForChild(final String uri,
+ final String tagName,
+ final Attributes atts)
+ throws SAXException
{
- final ElementReadHandler handler = (ElementReadHandler) childs.get(i);
- rawSection.addNode(handler.getElement());
+ final StyleDefinitionReadHandler readHandler =
+ new StyleDefinitionReadHandler();
+ childs.add(readHandler);
+ return readHandler;
}
- }
+ /**
+ * Done parsing.
+ *
+ * @throws org.xml.sax.SAXException if there is a parsing error.
+ */
+ protected void doneParsing()
+ throws SAXException
+ {
+ for (int i = 0; i < childs.size(); i++)
+ {
+ final ElementReadHandler handler = (ElementReadHandler) childs.get(i);
+ rawSection.addNode(handler.getElement());
+ }
+ }
- public Element getElement()
- {
- return rawSection;
- }
+ public Element getElement()
+ {
+ return rawSection;
+ }
}