StaticCall.php 913 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. namespace PhpParser\Node\Expr;
  3. use PhpParser\Node;
  4. use PhpParser\Node\Expr;
  5. class StaticCall extends Expr
  6. {
  7. /** @var Node\Name|Expr Class name */
  8. public $class;
  9. /** @var string|Expr Method name */
  10. public $name;
  11. /** @var Node\Arg[] Arguments */
  12. public $args;
  13. /**
  14. * Constructs a static method call node.
  15. *
  16. * @param Node\Name|Expr $class Class name
  17. * @param string|Expr $name Method name
  18. * @param Node\Arg[] $args Arguments
  19. * @param array $attributes Additional attributes
  20. */
  21. public function __construct($class, $name, array $args = array(), array $attributes = array()) {
  22. parent::__construct($attributes);
  23. $this->class = $class;
  24. $this->name = $name;
  25. $this->args = $args;
  26. }
  27. public function getSubNodeNames() {
  28. return array('class', 'name', 'args');
  29. }
  30. }