Macromedia dreamweaver 8-extending dreamweaver User Manual

Page of 504
256
Reports
The Reports API
The only required function for the Reports API is the 
processFile()
 function. All other 
functions are optional.
processFile()
Availability
Dreamweaver 4.
Description
This function is called when there is a file to process. The Report command should process 
the file without modifying it and use the 
dw.ResultsPalette.SiteReports()
 function, the 
addResultItem()
 function, or the 
resWin.addItem()
 function to return information about 
the file. Dreamweaver automatically releases each file’s DOM when it finishes.
Arguments
strFilePath
 
The 
strFilePath
 argument is the full path and filename of the file to process.
Returns
Dreamweaver expects nothing.
beginReporting()
Availability
Dreamweaver 4.
Description
This function is called at the start of the reporting process, before any reports are run. If the 
Report command returns a 
false
 value from this function, the Report command is excluded 
from the report run. 
Arguments
target
The 
target
 argument is a string that indicates the target of the report session. It can be 
one of the following values: 
"CurrentDoc"
"CurrentSite"
"CurrentSiteSelection"
 
(for the selected files in a site), or 
"Folder:
the path to the folder the user 
selected"
 (for example, 
"Folder:c:temp"
).