2011-04-18 19:02:30 +02:00
|
|
|
<?php
|
|
|
|
|
2011-05-29 12:20:47 +02:00
|
|
|
/**
|
2011-06-05 18:40:04 +02:00
|
|
|
* @property PHPParser_Node_Expr $expr Expression
|
2011-08-11 10:25:51 +02:00
|
|
|
* @property int $type Type of include
|
2011-05-29 12:20:47 +02:00
|
|
|
*/
|
2011-06-05 18:40:04 +02:00
|
|
|
class PHPParser_Node_Expr_Include extends PHPParser_Node_Expr
|
2011-04-18 19:02:30 +02:00
|
|
|
{
|
|
|
|
const TYPE_INCLUDE = 1;
|
|
|
|
const TYPE_INCLUDE_ONCE = 2;
|
|
|
|
const TYPE_REQUIRE = 3;
|
|
|
|
const TYPE_REQUIRE_ONCE = 4;
|
2011-08-11 10:25:51 +02:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Constructs an include node.
|
|
|
|
*
|
|
|
|
* @param PHPParser_Node_Expr $expr Expression
|
|
|
|
* @param int $type Type of include
|
2012-04-29 23:32:09 +02:00
|
|
|
* @param array $attributes Additional attributes
|
2011-08-11 10:25:51 +02:00
|
|
|
*/
|
2012-04-29 23:32:09 +02:00
|
|
|
public function __construct(PHPParser_Node_Expr $expr, $type, array $attributes = array()) {
|
2011-08-11 10:25:51 +02:00
|
|
|
parent::__construct(
|
|
|
|
array(
|
|
|
|
'expr' => $expr,
|
|
|
|
'type' => $type
|
|
|
|
),
|
2012-04-29 23:32:09 +02:00
|
|
|
$attributes
|
2011-08-11 10:25:51 +02:00
|
|
|
);
|
|
|
|
}
|
2011-04-18 19:02:30 +02:00
|
|
|
}
|