com.catcode.odf
Class ElementPostProcess

java.lang.Object
  extended bycom.catcode.odf.ElementPostProcess
All Implemented Interfaces:
java.lang.Comparable

public class ElementPostProcess
extends java.lang.Object
implements java.lang.Comparable

Describes what character the OpenDocumentTextInputStream class should emit when an element closes. For example, after closing a <text:p> or <text:h> element, emit a '\n'. If you want to specify an element with no post-processing, set its postProcess field to '\0'


Field Summary
protected  java.lang.String name
           
protected  char postProcess
           
 
Constructor Summary
ElementPostProcess()
          Constructs a placeholder element descriptor.
ElementPostProcess(java.lang.String name)
          Constructs an element descriptor with the given name and '\0' post-processing character.
ElementPostProcess(java.lang.String name, char postProcess)
          Constructs an element descriptor with the given name and post-processing character.
 
Method Summary
 int compareTo(java.lang.Object o)
          See Comparator interface for details.
 java.lang.String getName()
          Returns the element name.
 char getPostProcess()
          Returns the element's post-processing character.
 void setName(java.lang.String name)
          Sets the element name to the given value.
 void setPostProcess(char postProcess)
          Sets element post-processing character to the given value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

name

protected java.lang.String name

postProcess

protected char postProcess
Constructor Detail

ElementPostProcess

public ElementPostProcess()
Constructs a placeholder element descriptor.


ElementPostProcess

public ElementPostProcess(java.lang.String name)
Constructs an element descriptor with the given name and '\0' post-processing character.

Parameters:
name - the element name, without a namespace prefix.

ElementPostProcess

public ElementPostProcess(java.lang.String name,
                          char postProcess)
Constructs an element descriptor with the given name and post-processing character.

Parameters:
name - the element name, without a namespace prefix.
postProcess - the character to emit after the element closes.
Method Detail

getPostProcess

public char getPostProcess()
Returns the element's post-processing character.

Returns:
the post-processing character.

setPostProcess

public void setPostProcess(char postProcess)
Sets element post-processing character to the given value.

Parameters:
postProcess - the post-processing character for this element.

getName

public java.lang.String getName()
Returns the element name.

Returns:
The element name.

setName

public void setName(java.lang.String name)
Sets the element name to the given value.

Parameters:
name - the desired name.

compareTo

public int compareTo(java.lang.Object o)
See Comparator interface for details.

Specified by:
compareTo in interface java.lang.Comparable