ru.novosoft.dc.rtf.dom
Class RTFParagraph

java.lang.Object
  |
  +--ru.novosoft.dc.rtf.dom.RTFParagraph

public class RTFParagraph
extends java.lang.Object
implements RTFBlock

A paragraph contains paragraph context and up to two lists of inline objects of the RTFObject type, namely a marker and content. If the marker presents it hangs to the left of content.


Constructor Summary
RTFParagraph()
           
 
Method Summary
 void attachContext(ParagraphContext context)
          Attach a context to the paragraph.
 void attachLabel(java.util.List label)
          Attach a list label to the paragraph.
 void complete(CharacterContext context)
          This method should be applied right after adding the paragraph mark to the content of this object.
 java.util.List content()
          Return the paragraph content.
 ParagraphContext context()
          Return the paragraph context or null if no context attached.
 void exportTo(org.w3c.dom.Element elem)
          Export the contents of this object to the specified DOM element.
 int inlineCount()
          Return a total number of inline objects in the paragraph label and content.
 java.util.List label()
          Return the paragraph label or null if no label attached.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RTFParagraph

public RTFParagraph()
Method Detail

attachContext

public final void attachContext(ParagraphContext context)
Attach a context to the paragraph.

attachLabel

public final void attachLabel(java.util.List label)
Attach a list label to the paragraph.

context

public final ParagraphContext context()
Return the paragraph context or null if no context attached.

inlineCount

public final int inlineCount()
Return a total number of inline objects in the paragraph label and content.

label

public final java.util.List label()
Return the paragraph label or null if no label attached.

content

public final java.util.List content()
Return the paragraph content.

complete

public void complete(CharacterContext context)
This method should be applied right after adding the paragraph mark to the content of this object. It modifies the character context of paragraph label (if it is attached) using the properties of the paragraph mark context passed in the parameter. If no paragraph label specified, the method does nothing

exportTo

public void exportTo(org.w3c.dom.Element elem)
Export the contents of this object to the specified DOM element.