ExportHelper Class Reference

#include <exporthelper.h>

List of all members.

Static Public Member Functions

static bool exportHTML (const int qryheadid, ParameterList &params, QString &filename, QString &errmsg)
static bool exportXML (const int qryheadid, ParameterList &params, QString &filename, QString &errmsg, const int xsltmapid=-1)
 Export the results of a query set to an XML file.
static QString generateDelimited (QString qtext, ParameterList &params, QString &errmsg)
static QString generateDelimited (const int qryheadid, ParameterList &params, QString &errmsg)
static QString generateHTML (QString qtext, ParameterList &params, QString &errmsg)
static QString generateHTML (const int qryheadid, ParameterList &params, QString &errmsg)
static QString generateXML (QString qtext, QString tableElemName, ParameterList &params, QString &errmsg, int xsltmapid=-1)
static QString generateXML (const int qryheadid, ParameterList &params, QString &errmsg, int xsltmapid=-1)
static bool XSLTConvertFile (QString inputfilename, QString outputfilename, int xsltmapid, QString &errmsg)
static QString XSLTConvertString (QString input, int xsltmapid, QString &errmsg)

Member Function Documentation

bool ExportHelper::exportHTML ( const int  qryheadid,
ParameterList &  params,
QString filename,
QString errmsg 
) [static]
bool ExportHelper::exportXML ( const int  qryheadid,
ParameterList &  params,
QString filename,
QString errmsg,
const int  xsltmapid = -1 
) [static]

Export the results of a query set to an XML file.

Run all of the queries in the given Query Set in the given order and write the results to an XML file. The XML file is constructed very simply: <tablename> <column1name>columnvalue</column1name> <column2name>columnvalue</column2name> ... </tablename>

If the caller passes in an XSLT map id, the simple XML will be processed using the export XSLT.

Parameters:
qryheadid The internal ID of the query set (qryhead record) to run.
params A list of parameters and values to use when building SQL statements from MetaSQL statements.
filename[in,out] The name of the file to create. If passed in empty, a file named after the query set will be created in the current directory (context-dependent) and this filename will be passed back out.
errmsg[out] An message describing why the processing failed if there was a problem.
xsltmapid An optional parameter. If this is set, it should be the internal ID of an xsltmap record. The xsltmap_export field of this record and the XSLTDefaultDir will be used to find the XSLT script to run on the generated XML.
QString ExportHelper::generateDelimited ( QString  qtext,
ParameterList &  params,
QString errmsg 
) [static]
QString ExportHelper::generateDelimited ( const int  qryheadid,
ParameterList &  params,
QString errmsg 
) [static]
QString ExportHelper::generateHTML ( QString  qtext,
ParameterList &  params,
QString errmsg 
) [static]
QString ExportHelper::generateHTML ( const int  qryheadid,
ParameterList &  params,
QString errmsg 
) [static]
QString ExportHelper::generateXML ( QString  qtext,
QString  tableElemName,
ParameterList &  params,
QString errmsg,
int  xsltmapid = -1 
) [static]
QString ExportHelper::generateXML ( const int  qryheadid,
ParameterList &  params,
QString errmsg,
int  xsltmapid = -1 
) [static]
bool ExportHelper::XSLTConvertFile ( QString  inputfilename,
QString  outputfilename,
int  xsltmapid,
QString errmsg 
) [static]
QString ExportHelper::XSLTConvertString ( QString  input,
int  xsltmapid,
QString errmsg 
) [static]

The documentation for this class was generated from the following files:

Generated on Tue Apr 20 12:03:06 2010 xTuple ERP Programmer Reference, Version 3.5.0 doxygen 1.6.1