Links
dtSearch Text Retrieval Engine Programmer's Reference 7.70
DOutputBase Class
Data Members | Classes | Legend | Members | Methods | Send Feedback

Class wrapper around dtsOutputInfo, which is used in DSearchReportJob and DFileConvertJob to specify the output format for file conversion and search reports

Class Hierarchy
class DOutputBase : public DJobBase;
File

dtsfc.h

Remarks

The header, footer, beforeHit, and afterHit markings should be in the format of the output. For example, if the output format is HTML, then beforeHit and afterHit markings could be <b> and </b>. 

BeforeHit, AfterHit, Header, and Footer control the appearance of converted text. 

The Header and Footer strings are inserted before and after the body of the document. 

The BeforeHit and AfterHit markers are inserted before and after each hit word. The BeforeHit and AfterHit markers can contain hypertext links. 

To facilitate creation of hit navigation markers, the strings "%%ThisHit%%", "%%NextHit%%", and "%%PrevHit%%" will be replaced with ordinals representing the current hit, the next hit, and the previous hit in the document. 

For example, the following code makes the beforeHit and nextHit marks act as HTML "Previous Hit" and "Next Hit" buttons.

    job.BeforeHit =
                 "<A NAME="hit%%ThisHit%%">"
                       "<A HREF="#hit%%PrevHit%%">"
                 "<IMG SRC="hit1.gif" ALIGN="middle" ALT="[Prev Hit]" BORDER=0>";
    job.AfterHit =
                    "<A HREF="#hit%%NextHit%%">"
                    "<IMG SRC="hit2.gif" ALIGN="middle" ALT="[Next Hit]" BORDER=0>";
Data Members
DOutputBase Class
Data Member 
Description 
Text inserted after each hit 
Text inserted before each hit 
Text inserted at the end of the file 
Text inserted at the start of the file 
For HTML output, an HREF for a BASE tag to be inserted in the header. 
For HTML output, HTML tags to insert in the header 
Name of file to create, if the output is to be written to a file. 
Group
Methods
Method 
Description 
Requests termination of the job in progress. 
Requests immediate termination of the job in progress. 
Called to execute a job. 
Returns non-zero if the job failed 
Format all errors that occurred during execution as a single string, with line breaks separating the errors 
Returns the number of errors recorded during execution 
Returns a dtsErrorInfo with any errors that occurred during execution 
Returns true if the job has been cancelled 
Returns true if the job has started and is not yet done. 
Called while a job is executing every time the dtSearch Engine checks to see if the job has been cancelled. 
Called while a job is executing if an error is encountered, with the error code and message. 
Not used 
SetTimeout() causes a job to cancel automatically after the specified number of seconds 
Do not pump waiting windows messages during callbacks 
DOutputBase Class
Method 
Description 
Clear all fields to default values 
Called to execute a job. 
If output was to a string, returns a pointer to the output string 
Get the length of the output string 
Returns true if output was directed to a string 
Called while a job is executing every time the dtSearch Engine checks to see if the job has been cancelled. 
 
Callback function to receive output as it is generated 
Callback function to update the progress of the conversion or search report 
Specifies the format of the converted text. 
Send output only to the virtual callback function, OnOutput 
Send output to a file 
Send output to a string buffer managed by the class, and set the maximum length of the output string. 
Legend
 
Method 
 
virtual 
 
abstract 
 
Data Member 
Links
You are here: C++ Support Classes > dtSearch Namespace > Classes > DOutputBase Class
Copyright (c) 1995-2012 dtSearch Corp. All rights reserved.