Skip to content

icms_ipf_export_Handler

Raimondas Rimkevičius edited this page Mar 9, 2020 · 1 revision
Notice: Wiki was automatic generated from project sources as project API documentation. Do not edit manually!

icms_ipf_export_Handler

Class to easily export data from IcmsPersistables

  • Class name: icms_ipf_export_Handler
  • Namespace:

Properties

$handler

public \icms_ipf_Handler $handler

Handler that can provide data

  • Visibility: public

$criteria

public \icms_db_criteria_Element $criteria

criteria how to filter exported data

  • Visibility: public

$fields

public array $fields = \false

Fields to be exported. If FALSE then all fields will be exported

  • Visibility: public

$format

public string $format = csv

Format of the ouputed export. Currently only supports CSV

  • Visibility: public

$filename

public string $filename

Name of the file to be created

  • Visibility: public

$filepath

public string $filepath

Path where the file will be saved

  • Visibility: public

$options

public array $options = array()

Options of the format to be exported in

  • Visibility: public

$outputMethods

public bool $outputMethods = \false

Output methods used for formating exported data

  • Visibility: public

$notDisplayFields

public array $notDisplayFields = array()

Fields data should not be included in generated result

  • Visibility: public

Methods

__construct

mixed icms_ipf_export_Handler::__construct(\icms_ipf_Handler objectHandler, \icms_db_criteria_Element criteria, array|bool fields, string filename, string filepath, string format, array options)

Constructor

  • Visibility: public

Arguments

  • objectHandler icms_ipf_Handler - <p>IcmsPersistableHandler handling the data we want to export</p>
  • criteria icms_db_criteria_Element - <p>Containing the criteria of the query fetching the objects to be exported</p>
  • fields array|bool - <p>Fields to be exported. If FALSE then all fields will be exported</p>
  • filename string - <p>Name of the file to be created</p>
  • filepath string - <p>Path where the file will be saved</p>
  • format string - <p>Format of the ouputed export. Currently only supports CSV</p>
  • options array - <p>Options of the format to be exported in</p>

render

mixed icms_ipf_export_Handler::render(mixed filename)

Renders the export

  • Visibility: public

Arguments

  • filename mixed

setOuptutMethods

mixed icms_ipf_export_Handler::setOuptutMethods(array outputMethods)

Set an array contaning the alternate methods to use instead of the default getVar()

  • Visibility: public

Arguments

  • outputMethods array - <p>array example : 'uid' => 'getUserName'...</p>

setNotDisplayFields

mixed icms_ipf_export_Handler::setNotDisplayFields(mixed fields)
  • Visibility: public

Arguments

  • fields mixed
Clone this wiki locally