Overview

Namespaces

  • Pharborist
    • Constants
    • ControlStructures
    • Exceptions
    • Functions
    • Generators
    • Namespaces
    • Objects
    • Operators
    • Types
    • Variables

Classes

  • NameNode
  • NamespaceNode
  • UseDeclarationBlockNode
  • UseDeclarationNode
  • UseDeclarationStatementNode

Traits

  • IdentifierNameTrait
  • Overview
  • Namespace
  • Class

Trait IdentifierNameTrait

Trait that gives a node an identifier in a namespace.

Functions, constants, classes, interfaces, and traits all have an identifier.

Direct Known Users

Pharborist\Constants\ConstantDeclarationNode, Pharborist\Functions\FunctionDeclarationNode, Pharborist\Objects\InterfaceNode, Pharborist\Objects\SingleInheritanceNode

Indirect Known Users

Pharborist\Objects\ClassNode, Pharborist\Objects\TraitNode
Namespace: Pharborist\Namespaces
Located at Namespaces/IdentifierNameTrait.php
Methods summary
public Pharborist\Namespaces\NameNode
# getName( )

Returns

Pharborist\Namespaces\NameNode
public Pharborist\Namespaces\NamespaceNode
# getNamespace( )

Returns

Pharborist\Namespaces\NamespaceNode
public
# setName( string $name )

Set the identifier name of this node.

Set the identifier name of this node.

Parameters

$name
New name.

Returns


$this
public boolean
# inNamespace( string|Pharborist\Namespaces\NamespaceNode $ns )

Determine if this node belongs to namespace.

Determine if this node belongs to namespace.

Parameters

$ns
Either the absolute namespace path or a NamespaceNode.

Returns

boolean
TRUE if the node belongs to the given namespace.
Pharborist API documentation generated by ApiGen