forked from ghunti/HighchartsPHP
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathHighchartJsExpr.php
43 lines (41 loc) · 944 Bytes
/
HighchartJsExpr.php
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
<?php
/**
*
* Copyright 2012-2012 Portugalmail Comunicações S.A (http://www.portugalmail.net/)
*
* See the enclosed file LICENCE for license information (GPLv3). If you
* did not receive this file, see http://www.gnu.org/licenses/gpl-3.0.html.
*
* @author Gonçalo Queirós <[email protected]>
*/
class HighchartJsExpr
{
/**
* The javascript expression
*
* @var string
*/
private $_expression;
/**
* The HighchartJsExpr constructor
*
* @param string $expression The javascript expression
*/
public function __construct($expression)
{
$this->_expression = iconv(
mb_detect_encoding($expression),
"UTF-8",
$expression
);
}
/**
* Returns the javascript expression
*
* @return string The javascript expression
*/
public function getExpression()
{
return $this->_expression;
}
}