se.biltmore.tools.odttoapt.maven.plugin.models
Class APTList

java.lang.Object
  extended by se.biltmore.tools.odttoapt.maven.plugin.models.APT
      extended by se.biltmore.tools.odttoapt.maven.plugin.models.APTParent
          extended by se.biltmore.tools.odttoapt.maven.plugin.models.APTListItem
              extended by se.biltmore.tools.odttoapt.maven.plugin.models.APTList
Direct Known Subclasses:
APTListLetteredLowerCase, APTListLetteredUpperCase, APTListNumbered, APTListRomanLowerCase, APTListRomanUpperCase

public class APTList
extends APTListItem

This represents a bulleted list in a APT document. This is also a base class for all other types of lists.

The bulleted or dotted (or whatever you want to call it) list has the following format:

   * Text ...
     more text ..

     Possible other paragraph in same list item.
     ...
 

Lists have the following model structure:

 APTList (or sublcass)
     APTListItem (any number)
         APTParagraph (any order, any number)
         APTList (any order, any number)
 
This reflects both how the content.xml looks like and the APT list structure.

APTList extends APTListItem due to that only the "text:list" item in the xml contains the list style specification. Items have no style at all, and paragraphs within a list item has an OpenOffice internal style which a document writer has no controll over (OK, I'm not an expert on OpenOffice! It might be possible, but it is at least not obvious how to do it, and I dont want to put too high demands on the users). I dont know if APT allows mixing list styles whitin a list, but this tool does not allow it.

That means that each list item must inherit style information from the list it is added to, so both APTList and APTListItem need to sit on the same formatting values. They are implemented in APTListItem and inherited by APTList. If you look at addChild() below you can see that these formatting attributes are copied to each APTListItem added.


Constructor Summary
APTList()
          Creates a new APTList instance.
 
Method Summary
 void addChild(APT apt)
          Adds the specified APT object as a child to this APT object.
 String getValue()
          Returns the value.
 
Methods inherited from class se.biltmore.tools.odttoapt.maven.plugin.models.APTListItem
getBulletType, getLevel, setBulletType, setLevel
 
Methods inherited from class se.biltmore.tools.odttoapt.maven.plugin.models.APTParent
getChildren, getLastChild, getUnformattedValue, hasChildren
 
Methods inherited from class se.biltmore.tools.odttoapt.maven.plugin.models.APT
done, formatText, getParent, hasValue, isAllowFormat, isLink, setAllowFormat, setLink, setParent, setValue, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

APTList

public APTList()
Creates a new APTList instance.

Method Detail

addChild

public void addChild(APT apt)
Adds the specified APT object as a child to this APT object.

Overrides:
addChild in class APTListItem
Parameters:
apt - The APT object to add.

getValue

public String getValue()
Returns the value.

Overrides:
getValue in class APTListItem


Copyright © 2009-2010 Biltmore Group AB. All Rights Reserved.