1<?php
2
3declare(strict_types=1);
4
5/**
6 * This file is part of phpDocumentor.
7 *
8 * For the full copyright and license information, please view the LICENSE
9 * file that was distributed with this source code.
10 *
11 * @link      http://phpdoc.org
12 */
13
14namespace phpDocumentor\Reflection\DocBlock\Tags\Formatter;
15
16use phpDocumentor\Reflection\DocBlock\Tag;
17use phpDocumentor\Reflection\DocBlock\Tags\Formatter;
18use function trim;
19
20class PassthroughFormatter implements Formatter
21{
22    /**
23     * Formats the given tag to return a simple plain text version.
24     */
25    public function format(Tag $tag) : string
26    {
27        return trim('@' . $tag->getName() . ' ' . $tag);
28    }
29}
30