PHP Class Ublaboo\DataGrid\CsvDataModel

Show file Open project: ublaboo/datagrid Class Usage Examples

Protected Properties

Property Type Description
$columns Ublaboo\DataGrid\Column\Column[]
$data array
$translator Nette\Localization\ITranslator

Public Methods

Method Description
__construct ( array $data, array $columns, Nette\Localization\ITranslator $translator )
getHeader ( ) : array Get data header
getRow ( mixed $item ) : array Get item values saved into row
getSimpleData ( $include_header = TRUE ) : array Get data with header and "body"

Method Details

__construct() public method

public __construct ( array $data, array $columns, Nette\Localization\ITranslator $translator )
$data array
$columns array
$translator Nette\Localization\ITranslator

getHeader() public method

Get data header
public getHeader ( ) : array
return array

getRow() public method

Get item values saved into row
public getRow ( mixed $item ) : array
$item mixed
return array

getSimpleData() public method

Get data with header and "body"
public getSimpleData ( $include_header = TRUE ) : array
return array

Property Details

$columns protected property

protected Column[],Ublaboo\DataGrid\Column $columns
return Ublaboo\DataGrid\Column\Column[]

$data protected property

protected array $data
return array

$translator protected property

protected ITranslator,Nette\Localization $translator
return Nette\Localization\ITranslator