Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x

ArrayShapeUnsealedTypeNode.php

Namespace

PHPStan\PhpDocParser\Ast\Type

File

vendor/phpstan/phpdoc-parser/src/Ast/Type/ArrayShapeUnsealedTypeNode.php

View source
<?php

declare (strict_types=1);
namespace PHPStan\PhpDocParser\Ast\Type;

use PHPStan\PhpDocParser\Ast\Node;
use PHPStan\PhpDocParser\Ast\NodeAttributes;
use function sprintf;
class ArrayShapeUnsealedTypeNode implements Node {
    use NodeAttributes;
    
    /** @var TypeNode */
    public $valueType;
    
    /** @var TypeNode|null */
    public $keyType;
    public function __construct(TypeNode $valueType, ?TypeNode $keyType) {
        $this->valueType = $valueType;
        $this->keyType = $keyType;
    }
    public function __toString() : string {
        if ($this->keyType !== null) {
            return sprintf('<%s, %s>', $this->keyType, $this->valueType);
        }
        return sprintf('<%s>', $this->valueType);
    }

}

Classes

Title Deprecated Summary
ArrayShapeUnsealedTypeNode

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal