File "HasAttributes.php"

Full path: /var/www/html/back/vendor/phpdocumentor/reflection/src/phpDocumentor/Reflection/Php/HasAttributes.php
File size: 0.39 KB (399 B bytes)
MIME-type: text/x-php
Charset: utf-8

Download   Open   Edit   Advanced Editor   Back

<?php

declare(strict_types=1);

namespace phpDocumentor\Reflection\Php;

trait HasAttributes
{
    /** @var Attribute[] */
    private array $attributes = [];

    public function addAttribute(Attribute $attribute): void
    {
        $this->attributes[] = $attribute;
    }

    /** @return Attribute[] */
    public function getAttributes(): array
    {
        return $this->attributes;
    }
}