blob: 7519da4bca14fe736cb4673833259ee70e7f420e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
<?php
// Icinga Web 2 Cube Module | (c) 2016 Icinga GmbH | GPLv2
namespace Icinga\Module\Cube;
/**
* Dimension interface
*
* All available dimensions must implement this interface
*
* @package Icinga\Module\Cube
*/
interface Dimension
{
/**
* The name of this dimension
*
* @return string
*/
public function getName();
/**
* The label of this dimension
*
* @return string
*/
public function getLabel();
/**
* Column expression
*
* This is the expression used to fetch the related column. Usually an SQL
* snippet when a relational database is involved
*
* @param Cube $cube
*
* @return string
*/
public function getColumnExpression(Cube $cube);
/**
* Add this dimension to a cube
*
* This allows your dimension to apply itself to the Cube. That way your
* dimension is able to join optional tables and more
*
* @param Cube $cube
* @return void
*/
public function addToCube(Cube $cube);
}
|