CkHtmlToText C++ Class Reference (Visual C++)
CkHtmlToText
HTML to plain-text conversion component. The internal conversion process is much more sophisticated than can be accomplished with the simple regular-expression freeware codes found in the Internet. This is more than simply removing HTML tags from an HTML document.
Properties
void LastErrorHtml(CkString &str);
Error information in HTML format for the last method called.
void LastErrorText(CkString &str);
Error information in plain-text format for the last method called.
void LastErrorXml(CkString &str);
Error information in XML format for the last method called.
bool get_Utf8(void) const; void put_Utf8(bool b);
To be documented soon...
Methods
bool IsUnlocked();
Returns true if the component is already unlocked. Otherwise returns false.
bool ReadFileToString(const char * filename, const char * srcCharset, CkString & str);
Convenience method for reading a text file into a string. The character encoding of the text file is specified by srcCharset. Valid values, such as "iso-8895-1" or "utf-8" are listed at: List of Charsets. Returns true for success, false for failure.
bool SaveLastError(const char * filename);
Saves the last error information to an XML formatted file.
bool ToText(const char * html, CkString & outStr);
Converts HTML to plain-text. Returns true for success, false for failure.
bool UnlockComponent(const char * code);
Unlocks the component. An arbitrary unlock code may be passed to automatically begin a 30-day trial.
This class is included with the Chilkat HTML-to-XML conversion component license. A permanent unlock code for Chilkat HTML-to-XML should be used to unlock this object.
bool WriteStringToFile(const char * stringToWrite, const char * filename, const char * outpuCharset);
Convenience method for saving a string to a file. The character encoding of the output text file is specified by outpuCharset (the string is converted to this charset when writing). Valid values, such as "iso-8895-1" or "utf-8" are listed at: List of Charsets.
const char * lastErrorHtml();
Error information in HTML format for the last method called.
const char * lastErrorText();
Error information in plain-text format for the last method called.
const char * lastErrorXml();
Error information in XML format for the last method called.
const char * readFileToString(const char * filename, const char * srcCharset);
Convenience method for reading a text file into a string. The character encoding of the text file is specified by srcCharset. Valid values, such as "iso-8895-1" or "utf-8" are listed at: List of Charsets.
const char * toText(const char * html);
Converts HTML to plain-text.
|