The export interface

Exporting survey-data can be done for various sorts of output formats, this interface describes the methods needed to implement an output format

package Gems
subpackage Export
copyright Copyright (c) 2011 Erasmus MC
license New BSD License
since Class available since version 1.6.1
inherited_from \Gems_Export_ExportInterface

 Methods

This method handles setting up all needed steps for the batch export

handleExportBatch(array $filter, string $language, array $data) 

Normally this will initialize the file to download and set up as much steps as needed and the final job to close the file.

To offer a file for download, add a message with the key 'file' to the batch. The message must be an array of 'headers' that contains an array of headers to set for the download and 'file' that holds the path to the file relative to GEMS_ROOT_DIR . '/var/tmp/'

Parameters

$filter

array

The filter to use

$language

string

The language used / to use for the export

$data

array

The formdata

Set the batch to be used by this source

setBatch(\Gems_Task_TaskRunnerBatch $batch) 

Use $this->hasBatch to check for existence

Parameters

$batch

\Gems_Task_TaskRunnerBatch