2013-10-15 12:48:33 +02:00
|
|
|
<?php
|
2015-02-03 16:27:59 +01:00
|
|
|
/* Icinga Web 2 | (c) 2013-2015 Icinga Development Team | http://www.gnu.org/licenses/gpl-2.0.txt */
|
2013-10-15 12:48:33 +02:00
|
|
|
|
|
|
|
namespace Icinga\Module\Monitoring\DataView;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Represent customvar view
|
|
|
|
*/
|
|
|
|
class Customvar extends DataView
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* Retrieve columns provided by this view
|
|
|
|
*
|
|
|
|
* @return array
|
|
|
|
*/
|
|
|
|
public function getColumns()
|
|
|
|
{
|
|
|
|
return array(
|
|
|
|
'varname',
|
|
|
|
'varvalue',
|
2014-11-06 16:13:17 +01:00
|
|
|
'is_json',
|
2013-10-15 12:48:33 +02:00
|
|
|
'object_type'
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Retrieve default sorting rules for particular columns. These involve sort order and potential additional to sort
|
|
|
|
*
|
|
|
|
* @return array
|
|
|
|
*/
|
|
|
|
public function getSortRules()
|
|
|
|
{
|
|
|
|
return array(
|
|
|
|
'varname' => array(
|
|
|
|
'varname' => self::SORT_ASC,
|
|
|
|
'varvalue' => self::SORT_ASC,
|
|
|
|
)
|
|
|
|
);
|
|
|
|
}
|
|
|
|
}
|