Base class for aggregated types like Compound and Intersection

A Aggregated Type is not so much a special keyword or object reference but is a series of Types that are separated
using separator.

  • psalm-immutable
  • template-implements IteratorAggregate
Abstract
ChildrenphpDocumentor\Reflection\Types\Compound
phpDocumentor\Reflection\Types\Intersection
ImplementsIteratorAggregate
phpDocumentor\Reflection\Type
Traversable
Methods
public __construct(array $types, string $token)
 
    public __toString() : string
     

    Returns a rendered output of the Type as it would be used in a DocBlock.

    public contains(phpDocumentor\Reflection\Type $type) : bool
     

    Tests if this compound type contains the given type.

    public get(int $index) : phpDocumentor\Reflection\Type
     

    Returns the type at the given index.

    public getIterator() : ArrayIterator
     
    • return ArrayIterator
    public has(int $index) : bool
     

    Tests if this compound type has a type with the given index.

    Properties
    private $token
     
    • var string
    private $types
     
    • psalm-allow-private-mutation
    • var array
    Methods
    private add(phpDocumentor\Reflection\Type $type) : void
     
    • psalm-suppress ImpureMethodCall
    © 2020 Bruce Wells
    Search Namespaces \ Classes
    ConfigurationNumbers (0-9.) only