Class RtfDestination
- Namespace
- iTextSharp.text.rtf.parser.destinations
- Assembly
- iTextSharp.LGPLv2.Core.dll
RtfDestination is the base class for destinations according to the RTF Specification. All destinations must extend from this class. @author Howard Shank (hgshank@yahoo.com @since 2.0.8
public abstract class RtfDestination
- Inheritance
-
RtfDestination
- Derived
- Inherited Members
Constructors
RtfDestination()
Constructor.
protected RtfDestination()
RtfDestination(RtfParser)
Constructor
protected RtfDestination(RtfParser parser)
Parameters
parser
RtfParserRtfParser object.
Fields
LastCtrlWord
The last control word handled by this destination
protected RtfCtrlWordData LastCtrlWord
Field Value
Modified
Is data in destination modified?
protected bool Modified
Field Value
RtfParser
Parser object
protected RtfParser RtfParser
Field Value
Methods
AddListener(IRtfDestinationListener)
Adds a RtfDestinationListener to the RtfDestinationMgr . the new RtfDestinationListener.
public static bool AddListener(IRtfDestinationListener listener)
Parameters
listener
IRtfDestinationListener
Returns
AfterCharacter(int)
protected static int AfterCharacter(int ch)
Parameters
ch
int
Returns
AfterCtrlWord(RtfCtrlWordData)
protected static RtfCtrlWordData AfterCtrlWord(RtfCtrlWordData ctrlWordData)
Parameters
ctrlWordData
RtfCtrlWordData
Returns
BeforeCharacter(int)
protected static int BeforeCharacter(int ch)
Parameters
ch
int
Returns
BeforeCtrlWord(RtfCtrlWordData)
protected static RtfCtrlWordData BeforeCtrlWord(RtfCtrlWordData ctrlWordData)
Parameters
ctrlWordData
RtfCtrlWordData
Returns
CloseDestination()
Clean up when destination is closed.
public abstract bool CloseDestination()
Returns
- bool
true if handled, false if not handled
GetNewTokeniserState()
public virtual int GetNewTokeniserState()
Returns
HandleCharacter(int)
Handle text for this destination
public abstract bool HandleCharacter(int ch)
Parameters
ch
int
Returns
- bool
true if handled, false if not handled
HandleCloseGroup()
Clean up when group is closed.
public abstract bool HandleCloseGroup()
Returns
- bool
true if handled, false if not handled
HandleControlWord(RtfCtrlWordData)
Handle control word for this destination
public abstract bool HandleControlWord(RtfCtrlWordData ctrlWordData)
Parameters
ctrlWordData
RtfCtrlWordDataThe control word and parameter information object
Returns
- bool
true if handled, false if not handled
HandleOpenGroup()
Setup when group is opened.
public abstract bool HandleOpenGroup()
Returns
- bool
true if handled, false if not handled
HandleOpeningSubGroup()
Handle a new subgroup contained within this group
public abstract bool HandleOpeningSubGroup()
Returns
- bool
true if handled, false if not handled
IsModified()
Method to indicate if data in this destination has changed.
public bool IsModified()
Returns
- bool
true if modified, false if not modified.
OnCharacter(int)
protected static int OnCharacter(int ch)
Parameters
ch
int
Returns
OnCloseGroup()
protected static bool OnCloseGroup()
Returns
OnCtrlWord(RtfCtrlWordData)
protected static RtfCtrlWordData OnCtrlWord(RtfCtrlWordData ctrlWordData)
Parameters
ctrlWordData
RtfCtrlWordData
Returns
OnOpenGroup()
protected static bool OnOpenGroup()
Returns
RemoveListener(IRtfDestinationListener)
listener methods
public static bool RemoveListener(IRtfDestinationListener listener)
Parameters
listener
IRtfDestinationListener
Returns
SetParser(RtfParser)
Set the parser to use with the RtfDestination object.
public virtual void SetParser(RtfParser parser)
Parameters
parser
RtfParserThe RtfParser object.
SetToDefaults()
Method to set this object to the default values. Must be implemented in child class.
public abstract void SetToDefaults()