<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>ODF Toolkit for Java</title>
	<atom:link href="http://odf4j.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://odf4j.wordpress.com</link>
	<description>Weblog of the odf4j Project</description>
	<lastBuildDate>Thu, 10 Apr 2008 22:09:58 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='odf4j.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>ODF Toolkit for Java</title>
		<link>http://odf4j.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://odf4j.wordpress.com/osd.xml" title="ODF Toolkit for Java" />
	<atom:link rel='hub' href='http://odf4j.wordpress.com/?pushpress=hub'/>
		<item>
		<title>Last post here: Time to move;</title>
		<link>http://odf4j.wordpress.com/2008/04/10/last-post-here-time-to-move/</link>
		<comments>http://odf4j.wordpress.com/2008/04/10/last-post-here-time-to-move/#comments</comments>
		<pubDate>Thu, 10 Apr 2008 22:09:58 +0000</pubDate>
		<dc:creator>Amit</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://odf4j.wordpress.com/?p=21</guid>
		<description><![CDATA[This is the last post on this blog, time to move on and get all my stuffs on one blog. From now on, all things on &#8216;odf4j&#8217; will be available at this link See you!<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=21&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>This is the last post on this blog, time to move on and get all my stuffs on one <a href="http://amitksaha.blogspot.com">blog</a>. From now on, all things on &#8216;odf4j&#8217; will be available at this <a href="http://amitksaha.blogspot.com/search/label/odf4j">link</a></p>
<p>See you!</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/odf4j.wordpress.com/21/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/odf4j.wordpress.com/21/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/odf4j.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/odf4j.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/odf4j.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/odf4j.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/odf4j.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/odf4j.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/odf4j.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/odf4j.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/odf4j.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/odf4j.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/odf4j.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/odf4j.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/odf4j.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/odf4j.wordpress.com/21/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=21&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://odf4j.wordpress.com/2008/04/10/last-post-here-time-to-move/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e649984086cb48e24a6dfd040a86fe96?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Amit</media:title>
		</media:content>
	</item>
		<item>
		<title>Style Tree Implementation</title>
		<link>http://odf4j.wordpress.com/2007/10/05/style-tree-implementation/</link>
		<comments>http://odf4j.wordpress.com/2007/10/05/style-tree-implementation/#comments</comments>
		<pubDate>Fri, 05 Oct 2007 07:25:51 +0000</pubDate>
		<dc:creator>Amit</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[code]]></category>

		<guid isPermaLink="false">http://odf4j.wordpress.com/2007/10/05/style-tree-implementation/</guid>
		<description><![CDATA[/* * StyleTree.java * * Created on 28 Sep, 2007, 2:43:06 PM * * */ package org.openoffice.odf.style; /** * * @author amitksaha &#60;amitksaha@openoffice.org&#62; */ import javax.swing.tree.DefaultMutableTreeNode; import java.util.Enumeration; /* * Implementation of the Style Hierarchy in ODF documents * EXPERIMENTAL CODE */ public class StyleTree { private DefaultMutableTreeNode top; public void getStyle(String style_name) { //Create [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=20&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><code>/*<br />
* StyleTree.java<br />
*<br />
* Created on 28 Sep, 2007, 2:43:06 PM<br />
*<br />
*<br />
*/</code></p>
<p>package org.openoffice.odf.style;</p>
<p>/**<br />
*<br />
* @author amitksaha &lt;amitksaha@openoffice.org&gt;<br />
*/<br />
import javax.swing.tree.DefaultMutableTreeNode;<br />
import java.util.Enumeration;</p>
<p>/*<br />
* Implementation of the Style Hierarchy in ODF documents<br />
* EXPERIMENTAL CODE<br />
*/</p>
<p>public class StyleTree {<br />
private DefaultMutableTreeNode top;</p>
<p>public void getStyle(String style_name) {</p>
<p>//Create the nodes.<br />
top = new DefaultMutableTreeNode(&#8220;ODT Style Families&#8221;);</p>
<p>createNodes(top);<br />
search(style_name);<br />
}</p>
<p>private void createNodes(DefaultMutableTreeNode top) {<br />
DefaultMutableTreeNode style_family = null;<br />
DefaultMutableTreeNode parent_style = null;<br />
DefaultMutableTreeNode style_name_1 = null;<br />
DefaultMutableTreeNode style_name_2 = null;<br />
DefaultMutableTreeNode style_name_3 = null;</p>
<p>style_family = new DefaultMutableTreeNode(&#8220;graphic&#8221;);<br />
top.add(style_family);</p>
<p>style_family = new DefaultMutableTreeNode(&#8220;Paragraph&#8221;);<br />
top.add(style_family);</p>
<p>parent_style = new DefaultMutableTreeNode(&#8220;standard&#8221;);<br />
style_family.add(parent_style);</p>
<p>style_name_1 = new DefaultMutableTreeNode(&#8220;index&#8221;);<br />
parent_style.add(style_name_1);</p>
<p>style_name_2 = new DefaultMutableTreeNode(&#8220;Text_20_body&#8221;);<br />
parent_style.add(style_name_2);</p>
<p>style_name_1 = new DefaultMutableTreeNode(&#8220;P1&#8243;);<br />
style_name_2.add(style_name_1);</p>
<p>style_name_1 = new DefaultMutableTreeNode(&#8220;P2&#8243;);<br />
style_name_2.add(style_name_1);</p>
<p>style_name_1 = new DefaultMutableTreeNode(&#8220;Heading&#8221;);<br />
style_name_2.add(style_name_1);</p>
<p>style_name_1 = new DefaultMutableTreeNode(&#8220;List&#8221;);<br />
style_name_2.add(style_name_1);</p>
<p>style_name_3 = new DefaultMutableTreeNode(&#8220;caption&#8221;);<br />
parent_style.add(style_name_3);</p>
<p>style_family = new DefaultMutableTreeNode(&#8220;table&#8221;);<br />
top.add(style_family);</p>
<p>style_family = new DefaultMutableTreeNode(&#8220;table_row&#8221;);<br />
top.add(style_family);</p>
<p>}</p>
<p>private void search(String item){</p>
<p>Enumeration res = top.depthFirstEnumeration();</p>
<p>for (; res.hasMoreElements() <img src='http://s1.wp.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' />  {<br />
Object obj = res.nextElement();</p>
<p>//trivial typecast</p>
<p>DefaultMutableTreeNode node = (DefaultMutableTreeNode)obj;</p>
<p>if(item.equals(node.toString())){</p>
<p>//traverse up the tree for the style information</p>
<p>System.out.println(&#8220;Style Information for: &#8221; + item);<br />
System.out.println(&#8220;Style Family: &#8221; + node.getParent().getParent().getParent().toString());<br />
System.out.println(&#8220;Parent Style: &#8221; + node.getParent().getParent().toString());<br />
System.out.println(&#8220;Previous Higher Style Category: &#8221; + node.getParent().toString());</p>
<p>}</p>
<p>}</p>
<p>}</p>
<p>}</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/odf4j.wordpress.com/20/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/odf4j.wordpress.com/20/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/odf4j.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/odf4j.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/odf4j.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/odf4j.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/odf4j.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/odf4j.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/odf4j.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/odf4j.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/odf4j.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/odf4j.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/odf4j.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/odf4j.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/odf4j.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/odf4j.wordpress.com/20/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=20&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://odf4j.wordpress.com/2007/10/05/style-tree-implementation/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e649984086cb48e24a6dfd040a86fe96?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Amit</media:title>
		</media:content>
	</item>
		<item>
		<title>Style Hierarchy in ODT documents</title>
		<link>http://odf4j.wordpress.com/2007/09/04/style-hierarchy-in-odt-documents/</link>
		<comments>http://odf4j.wordpress.com/2007/09/04/style-hierarchy-in-odt-documents/#comments</comments>
		<pubDate>Tue, 04 Sep 2007 13:30:07 +0000</pubDate>
		<dc:creator>Amit</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://odf4j.wordpress.com/2007/09/04/style-hierarchy-in-odt-documents/</guid>
		<description><![CDATA[I have identified a hierarchical relationship among the way Style information is stored in &#8220;style.xml&#8221; file. Based on my findings I have represented them in a Style tree. Now, using this Style tree we can retrieve style information associated with each style, like the Parent-style, Style family, etc by using the style-name which are the [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=18&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I have identified a hierarchical relationship among the way Style information is stored in &#8220;style.xml&#8221; file. Based on my findings I have represented them in a Style tree.<br />
<a href="http://odf4j.files.wordpress.com/2007/09/style-tree.png" title="Style Tree"><img src="http://odf4j.files.wordpress.com/2007/09/style-tree.png?w=597&#038;h=488" alt="Style Tree" height="488" width="597" /></a></p>
<p>Now, using this Style tree we can retrieve style information associated with each style, like the Parent-style, Style family, etc by using the style-name which are the leaves of the tree. This will save us from parsing the &#8220;style.xml&#8221; everytime.</p>
<p><a href="http://odf4j.files.wordpress.com/2007/09/style-tree.png" title="Style Tree"></a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/odf4j.wordpress.com/18/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/odf4j.wordpress.com/18/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/odf4j.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/odf4j.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/odf4j.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/odf4j.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/odf4j.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/odf4j.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/odf4j.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/odf4j.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/odf4j.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/odf4j.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/odf4j.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/odf4j.wordpress.com/18/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/odf4j.wordpress.com/18/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/odf4j.wordpress.com/18/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=18&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://odf4j.wordpress.com/2007/09/04/style-hierarchy-in-odt-documents/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e649984086cb48e24a6dfd040a86fe96?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Amit</media:title>
		</media:content>

		<media:content url="http://odf4j.files.wordpress.com/2007/09/style-tree.png" medium="image">
			<media:title type="html">Style Tree</media:title>
		</media:content>
	</item>
		<item>
		<title>A possible approach to Style Handling using Java Beans</title>
		<link>http://odf4j.wordpress.com/2007/08/19/a-possible-approach-to-style-handling-using-java-beans/</link>
		<comments>http://odf4j.wordpress.com/2007/08/19/a-possible-approach-to-style-handling-using-java-beans/#comments</comments>
		<pubDate>Sun, 19 Aug 2007 13:36:56 +0000</pubDate>
		<dc:creator>Amit</dc:creator>
				<category><![CDATA[ideas]]></category>
		<category><![CDATA[odf4j]]></category>

		<guid isPermaLink="false">http://odf4j.wordpress.com/2007/08/19/a-possible-approach-to-style-handling-using-java-beans/</guid>
		<description><![CDATA[I shall make an effort to explain how we could possibly work with Styles using Java Beans. I understand, the entry point for retrieving the style information for an element, is the &#60;text:style-name &#62; using which we dig down further in the &#8220;content.xml&#8221; &#60;office:automatic-styles&#62;. What we can do here is that for each element&#8217;s style [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=17&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I shall make an effort to explain how we could possibly work with<br />
Styles using Java Beans.</p>
<p>I understand, the entry point for retrieving the style information for<br />
an element, is the &lt;text:style-name &gt; using which we dig down further<br />
in the &#8220;content.xml&#8221; &lt;office:automatic-styles&gt;.</p>
<p>What we can do here is that for each element&#8217;s style information we<br />
have an associated Java Bean with properly defined properties to<br />
reflect the style information. Being a Java bean we automatically have<br />
getter/setter methods for the style information for each element. This<br />
Java bean will be created automatically when the user makes a call to<br />
get/set the style information methods from the API.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/odf4j.wordpress.com/17/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/odf4j.wordpress.com/17/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/odf4j.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/odf4j.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/odf4j.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/odf4j.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/odf4j.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/odf4j.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/odf4j.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/odf4j.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/odf4j.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/odf4j.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/odf4j.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/odf4j.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/odf4j.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/odf4j.wordpress.com/17/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=17&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://odf4j.wordpress.com/2007/08/19/a-possible-approach-to-style-handling-using-java-beans/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e649984086cb48e24a6dfd040a86fe96?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Amit</media:title>
		</media:content>
	</item>
		<item>
		<title>Interfaces based approach to Style Handling</title>
		<link>http://odf4j.wordpress.com/2007/08/19/interfaces-based-approach-to-style-handling/</link>
		<comments>http://odf4j.wordpress.com/2007/08/19/interfaces-based-approach-to-style-handling/#comments</comments>
		<pubDate>Sun, 19 Aug 2007 13:35:32 +0000</pubDate>
		<dc:creator>Amit</dc:creator>
				<category><![CDATA[ideas]]></category>
		<category><![CDATA[odf4j]]></category>

		<guid isPermaLink="false">http://odf4j.wordpress.com/2007/08/19/interfaces-based-approach-to-style-handling/</guid>
		<description><![CDATA[Bernd Eilers suggested a interfaces based approach to handle Style information in odf4j: My approach would be to use something like the following which is almost completely interface based and hides the real implementation classes as inner class of a factory making it unavailable for the API to construct objects without using their factory. Also [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=16&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Bernd Eilers suggested a interfaces based approach to handle Style information in odf4j:</p>
<p>My approach would be to use something like the following which is almost<br />
completely interface based and hides the real implementation classes as<br />
inner class of a factory making it unavailable for the API to construct<br />
objects without using their factory. Also I would not want to have a<br />
generic Object getProperty(String name) and expose static String<br />
constants for attribute names or something like this as I consider the<br />
list of things to get/set fixed by the specification and thus we only<br />
need specific getter and setter methods and nothing generic. I would<br />
also like to suggest to derive specific Styles from a common base Style<br />
interface for each different Style family.</p>
<pre>public interface Style {</pre>
<pre>
        public String getDisplayName();</pre>
<pre>
        public String getStyleFamily();</pre>
<pre>
        ...</pre>
<pre>
        public Style getParentStyle()</pre>
<pre>
}</pre>
<pre>
public interface SectionStyle extends Style {</pre>
<pre>
        public String getBackgroundColor();</pre>
<pre>
        public StyleBackgroundImage getBackgroundImage();</pre>
<pre>
        ...</pre>
<pre>
}</pre>
<pre>
public interface TextStyle extends Style {</pre>
<pre>}</pre>
<pre>
// note this is a little bit special because ParagraphStyles</pre>
<pre>// contain the same things as TextStyles plus some more</pre>
<pre>// and so we can inherit here</pre>
<pre>public interface ParagraphStyle extends TextStyle {</pre>
<pre>
        public int getBackgroundTransperancy();</pre>
<pre>
        ...</pre>
<pre>}</pre>
<pre></pre>
<pre>// special stuff eg. for subelements of styles gets</pre>
<pre>// into own interfaces, for example</pre>
<pre>
public interface StyleBackgroundImage {</pre>
<pre>
        public static final String REPEAT_NO="no-repeat";</pre>
<pre>        ...</pre>
<pre>
        public String getRepeat();</pre>
<p><!-- D(["mb"," &nbsp; &nbsp; &nbsp; &nbsp;public String getRepeat();\u003cbr /\&gt; &nbsp; &nbsp; &nbsp; &nbsp;public void setRepeat(String newRepeat);\u003cbr /\&gt;\u003cbr /\&gt; &nbsp; &nbsp; &nbsp; &nbsp;..\u003cbr /\&gt;\u003cbr /\&gt;}\u003cbr /\&gt;\u003cbr /\&gt;\u003cbr /\&gt;\u003cbr /\&gt;and now in Style Factory have an abstract implementation base class as\u003cbr /\&gt;inner class plus implementation classes derived from it as inner classes\u003cbr /\&gt;\u003cbr /\&gt;\u003cbr /\&gt;public class StyleFactory {\u003cbr /\&gt;\u003cbr /\&gt; &nbsp; &nbsp; &nbsp; &nbsp;public class StyleImpl implements Style {\u003cbr /\&gt;\u003cbr /\&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;// constructor\u003cbr /\&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;public StyleImpl(Node node)\u003cbr /\&gt; &nbsp; &nbsp; &nbsp; &nbsp;}\u003cbr /\&gt;\u003cbr /\&gt; &nbsp; &nbsp; &nbsp; &nbsp;public class TextStyleImpl extends StyleImpl implements TextStyle {\u003cbr /\&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;...\u003cbr /\&gt; &nbsp; &nbsp; &nbsp; &nbsp;}\u003cbr /\&gt;\u003cbr /\&gt; &nbsp; &nbsp; &nbsp; &nbsp;public class ParagraphStyleImpl extends TextStyleImpl implements\u003cbr /\&gt;ParagraphStyle {\u003cbr /\&gt; &nbsp; &nbsp; &nbsp; &nbsp;...\u003cbr /\&gt; &nbsp; &nbsp; &nbsp; &nbsp;}\u003cbr /\&gt;\u003cbr /\&gt;}\u003cbr /\&gt;\u003cbr /\&gt;\u003cbr /\&gt;\u003cbr /\&gt;Would like to suggest to do the similar thing than with existing classes\u003cbr /\&gt;like Element and ElementFactory that is to convert Element, BlockElement\u003cbr /\&gt;etc to interfaces and have ElementImpl, BlockElementImpl etc. as inner\u003cbr /\&gt;classes inside the ElementFactory class implement them.\u003cbr /\&gt;\u003cbr /\&gt;\u003cbr /\&gt;Kind regards,\u003cbr /\&gt;\u003c/div\&gt;",1] );  //--></p>
<pre>        public void setRepeat(String newRepeat);</pre>
<pre>
        ..</pre>
<pre>
}</pre>
<p>and now in Style Factory have an abstract implementation base class as<br />
inner class plus implementation classes derived from it as inner classes</p>
<pre>public class StyleFactory {</pre>
<pre>
     public final abstract class StyleImpl implements Style {</pre>
<pre>
         // constructor</pre>
<pre>         public StyleImpl(Node node)</pre>
<pre>     }</pre>
<pre>
     public final class TextStyleImpl extends StyleImpl implements</pre>
<pre>TextStyle {</pre>
<pre>         ...</pre>
<pre>     }</pre>
<pre>
     public final class ParagraphStyleImpl extends TextStyleImpl</pre>
<pre>implements ParagraphStyle {</pre>
<pre>     ...</pre>
<pre>     }</pre>
<p>}Would like to suggest to do the similar thing than with existing classes<br />
like Element and ElementFactory that is to convert Element, BlockElement<br />
etc to interfaces and have ElementImpl, BlockElementImpl etc. as inner<br />
classes inside the ElementFactory class implement them.</p>
<p>Forgot to mention one main reason why to use that more interface centric<br />
approach with inner classes for implementation.</p>
<p>Later on when we move forward this APIU can be expressed in UNO IDL<br />
while classes with constructors that have java specific org.w3c.dom.Node<br />
elements as arguments can not as easily expressed in UNO IDL.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/odf4j.wordpress.com/16/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/odf4j.wordpress.com/16/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/odf4j.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/odf4j.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/odf4j.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/odf4j.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/odf4j.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/odf4j.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/odf4j.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/odf4j.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/odf4j.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/odf4j.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/odf4j.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/odf4j.wordpress.com/16/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/odf4j.wordpress.com/16/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/odf4j.wordpress.com/16/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=16&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://odf4j.wordpress.com/2007/08/19/interfaces-based-approach-to-style-handling/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e649984086cb48e24a6dfd040a86fe96?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Amit</media:title>
		</media:content>
	</item>
		<item>
		<title>odf4j Class Diagrams</title>
		<link>http://odf4j.wordpress.com/2007/07/19/odf4j-class-diagrams/</link>
		<comments>http://odf4j.wordpress.com/2007/07/19/odf4j-class-diagrams/#comments</comments>
		<pubDate>Thu, 19 Jul 2007 09:41:37 +0000</pubDate>
		<dc:creator>Amit</dc:creator>
				<category><![CDATA[class diagrams]]></category>
		<category><![CDATA[odf4j]]></category>
		<category><![CDATA[UML]]></category>

		<guid isPermaLink="false">http://odf4j.wordpress.com/2007/07/19/odf4j-class-diagrams/</guid>
		<description><![CDATA[Available for download here (recommended) is the high level package structure reproduced below: I created an entry at http://odftoolkit.openoffice.org/servlets/ProjectDocumentList under the &#8220;odf4j&#8221; project folders to store the UML class diagrams of the &#8220;odf4j&#8221; project. The class diagrams can be accessed here<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=15&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Available for download <a href="http://odftoolkit.openoffice.org/files/documents/254/4047/odf_diag1.PNG">here</a> (recommended) is the high level package structure reproduced below:</p>
<p><img src="http://odftoolkit.openoffice.org/files/documents/254/4047/odf_diag1.PNG" alt="High Level Package structure of odf4j" align="left" height="700" width="600" /></p>
<p>I created an entry at <a href="http://odftoolkit.openoffice.org/servlets/ProjectDocumentList">http://odftoolkit.openoffice.org/servlets/ProjectDocumentList</a> under the &#8220;odf4j&#8221; project folders to store the <strong>UML class diagrams</strong> of the &#8220;odf4j&#8221; project.<br />
The class diagrams can be accessed <a href="http://odftoolkit.openoffice.org/servlets/ProjectDocumentList?folderID=705&amp;expandFolder=705&amp;folderID=705">here</a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/odf4j.wordpress.com/15/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/odf4j.wordpress.com/15/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/odf4j.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/odf4j.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/odf4j.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/odf4j.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/odf4j.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/odf4j.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/odf4j.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/odf4j.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/odf4j.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/odf4j.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/odf4j.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/odf4j.wordpress.com/15/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/odf4j.wordpress.com/15/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/odf4j.wordpress.com/15/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=15&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://odf4j.wordpress.com/2007/07/19/odf4j-class-diagrams/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e649984086cb48e24a6dfd040a86fe96?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Amit</media:title>
		</media:content>

		<media:content url="http://odftoolkit.openoffice.org/files/documents/254/4047/odf_diag1.PNG" medium="image">
			<media:title type="html">High Level Package structure of odf4j</media:title>
		</media:content>
	</item>
		<item>
		<title>Updates</title>
		<link>http://odf4j.wordpress.com/2007/06/16/updates/</link>
		<comments>http://odf4j.wordpress.com/2007/06/16/updates/#comments</comments>
		<pubDate>Sat, 16 Jun 2007 04:15:36 +0000</pubDate>
		<dc:creator>Amit</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://odf4j.wordpress.com/2007/06/16/updates/</guid>
		<description><![CDATA[After a fortnight of coding inactivity, I am currently working on Style Handling in ODT documents. In the meantime,my role has also been upgraded to a developer.<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=14&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>After a fortnight of coding inactivity, I am currently working on <span style="font-weight:bold;">Style Handling</span> in ODT documents.</p>
<p>In the meantime,my <span style="font-weight:bold;">role</span> has also been upgraded to a developer.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/odf4j.wordpress.com/14/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/odf4j.wordpress.com/14/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/odf4j.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/odf4j.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/odf4j.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/odf4j.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/odf4j.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/odf4j.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/odf4j.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/odf4j.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/odf4j.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/odf4j.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/odf4j.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/odf4j.wordpress.com/14/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/odf4j.wordpress.com/14/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/odf4j.wordpress.com/14/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=14&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://odf4j.wordpress.com/2007/06/16/updates/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e649984086cb48e24a6dfd040a86fe96?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Amit</media:title>
		</media:content>
	</item>
		<item>
		<title>OdtToText2.java &#8211; Revision 1.2</title>
		<link>http://odf4j.wordpress.com/2007/05/29/odttotext2java-revision-12/</link>
		<comments>http://odf4j.wordpress.com/2007/05/29/odttotext2java-revision-12/#comments</comments>
		<pubDate>Tue, 29 May 2007 17:34:54 +0000</pubDate>
		<dc:creator>Amit</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[odf4j]]></category>

		<guid isPermaLink="false">http://odf4j.wordpress.com/2007/05/29/odttotext2java-revision-12/</guid>
		<description><![CDATA[Added support for &#8220;sections&#8221; in ODT documents. View the CVS log here<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=13&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Added support for &#8220;<span style="font-style:italic;">sections</span>&#8221; in ODT documents.</p>
<p>View the CVS log <a href="http://odftoolkit.openoffice.org/source/browse/odftoolkit/odf4j/src/org/openoffice/odf/tools/OdtToText2.java?rev=1.2&amp;view=log">here</a></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/odf4j.wordpress.com/13/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/odf4j.wordpress.com/13/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/odf4j.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/odf4j.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/odf4j.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/odf4j.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/odf4j.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/odf4j.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/odf4j.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/odf4j.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/odf4j.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/odf4j.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/odf4j.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/odf4j.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/odf4j.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/odf4j.wordpress.com/13/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=13&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://odf4j.wordpress.com/2007/05/29/odttotext2java-revision-12/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e649984086cb48e24a6dfd040a86fe96?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Amit</media:title>
		</media:content>
	</item>
		<item>
		<title>OdtToText2.java (Initial Version Committed)</title>
		<link>http://odf4j.wordpress.com/2007/05/21/odttotext2java-initial-version-committed/</link>
		<comments>http://odf4j.wordpress.com/2007/05/21/odttotext2java-initial-version-committed/#comments</comments>
		<pubDate>Mon, 21 May 2007 20:09:46 +0000</pubDate>
		<dc:creator>Amit</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[odf4j]]></category>

		<guid isPermaLink="false">http://odf4j.wordpress.com/2007/05/21/odttotext2java-initial-version-committed/</guid>
		<description><![CDATA[The initial version of OdtToText2.java was committed to the CVS by Bernd Eilers. View the CVS log here Features Extracts text, headings from a ODT file Uses the classes TextBody, BlockContent, Element, etc, in odf.text No manual SAX parsing To Do&#8217;s Extend it to extract other information from a ODT file,like table information and etc. [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=12&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>The initial version of OdtToText2.java was committed to the CVS by Bernd Eilers. View the CVS log <a href="http://odftoolkit.openoffice.org/source/browse/odftoolkit/odf4j/src/org/openoffice/odf/tools/OdtToText2.java?rev=1.1&amp;view=log">here</a></p>
<p>Features</p>
<ol>
<li>Extracts text, headings from a ODT file</li>
<li>Uses the classes <em>TextBody, BlockContent</em>, <em>Element</em>, etc, in odf.text</li>
<li>No manual SAX parsing</li>
</ol>
<p>To Do&#8217;s</p>
<ol>
<li>Extend it to extract other information from a ODT file,like table information and etc.</li>
</ol>
<ol></ol>
<p><strong><em>Test Run:</em></strong></p>
<ul>
<li>Input &#8211; ODT file containing simple text, a heading and List of elements</li>
</ul>
<ul>
<li>Output :</li>
</ul>
<blockquote><p>DEBUG unhandled elem is org.openoffice.odf.text.UnknownElement node=office:forms<br />
DEBUG unhandled elem is org.openoffice.odf.text.UnknownElement node=text:sequence-decls<br />
He heard quiet steps behind him. That didn&#8217;t bode well. Who could be following him this late at night and in this deadbeat part of town? And at this particular moment, just after he pulled off the big time and was making off with the greenbacks. Was there another crook who&#8217;d had the same idea, and was now watching him and waiting for a chance to grab the fruit of his labor?</p>
<p>*  aaa<br />
*  bbb<br />
*  ccc<br />
*  ddd<br />
*  eee<br />
*  ffff</p>
<p>==== Heading ====<br />
text below heading<br />
*  aaa<br />
*  bbb<br />
*  ccc<br />
*  ddd<br />
*  eee<br />
*  ffff</p></blockquote>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/odf4j.wordpress.com/12/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/odf4j.wordpress.com/12/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/odf4j.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/odf4j.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/odf4j.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/odf4j.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/odf4j.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/odf4j.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/odf4j.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/odf4j.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/odf4j.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/odf4j.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/odf4j.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/odf4j.wordpress.com/12/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/odf4j.wordpress.com/12/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/odf4j.wordpress.com/12/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=12&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://odf4j.wordpress.com/2007/05/21/odttotext2java-initial-version-committed/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e649984086cb48e24a6dfd040a86fe96?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Amit</media:title>
		</media:content>
	</item>
		<item>
		<title>Challenge to be taken care of (Bernd Eilers)</title>
		<link>http://odf4j.wordpress.com/2007/05/19/challenge-to-be-taken-care-of-bernd-eilers/</link>
		<comments>http://odf4j.wordpress.com/2007/05/19/challenge-to-be-taken-care-of-bernd-eilers/#comments</comments>
		<pubDate>Sat, 19 May 2007 15:12:32 +0000</pubDate>
		<dc:creator>Amit</dc:creator>
				<category><![CDATA[code]]></category>
		<category><![CDATA[odf4j]]></category>

		<guid isPermaLink="false">http://odf4j.wordpress.com/2007/05/19/challenge-to-be-taken-care-of-bernd-eilers/</guid>
		<description><![CDATA[What´s returned as java.util.List at that textBody.getContent() call is in fact an instance of class BlockContent which extends java.util.AbstractList. What the listIterator() and iterator() methods of that AbstractList returns which are curently not overriden in BlockContent would likely call the get(int index) method with an advancing index for every next() call on the Iterator. The [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=11&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>What´s returned as java.util.List at that textBody.getContent() call is<br />
in fact an instance of class BlockContent which extends<br />
java.util.AbstractList. What the listIterator() and iterator() methods<br />
of that AbstractList returns which are curently not overriden in<br />
BlockContent would likely call the get(int index) method with an<br />
advancing index for every next() call on the Iterator. The get(int<br />
index) method which we have in BlockContent now basically starts every<br />
time at the first childElement advancing until it gets to the index<br />
element at each call. Adding that together means that the current<br />
iterator is highly inefficent especially when considering large<br />
documents. So this means it would be a good idea to implement some inner<br />
class which implements ListIterator for BlockContent and to override the<br />
iterator and listIterator methods to return an instance of that class.<br />
This inner class should keep an pointer into the DOM tree for<br />
remembering where it is and just call factory.getElement() similar as it<br />
is done in the get(int index) Method.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/odf4j.wordpress.com/11/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/odf4j.wordpress.com/11/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/odf4j.wordpress.com/11/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/odf4j.wordpress.com/11/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/odf4j.wordpress.com/11/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/odf4j.wordpress.com/11/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/odf4j.wordpress.com/11/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/odf4j.wordpress.com/11/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/odf4j.wordpress.com/11/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/odf4j.wordpress.com/11/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/odf4j.wordpress.com/11/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/odf4j.wordpress.com/11/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/odf4j.wordpress.com/11/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/odf4j.wordpress.com/11/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/odf4j.wordpress.com/11/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/odf4j.wordpress.com/11/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=odf4j.wordpress.com&amp;blog=1048277&amp;post=11&amp;subd=odf4j&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://odf4j.wordpress.com/2007/05/19/challenge-to-be-taken-care-of-bernd-eilers/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e649984086cb48e24a6dfd040a86fe96?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Amit</media:title>
		</media:content>
	</item>
	</channel>
</rss>
