ReflectionDocBlock

Overview

License: MIT Qa workflow Coveralls Coverage Scrutinizer Code Coverage Scrutinizer Code Quality Stable Version Unstable Version

ReflectionDocBlock

Introduction

The ReflectionDocBlock component of phpDocumentor provides a DocBlock parser that is 100% compatible with the PHPDoc standard.

With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.

Installation

composer require phpdocumentor/reflection-docblock

Usage

In order to parse the DocBlock one needs a DocBlockFactory that can be instantiated using its createInstance factory method like this:

$factory  = \phpDocumentor\Reflection\DocBlockFactory::createInstance();

Then we can use the create method of the factory to interpret the DocBlock. Please note that it is also possible to provide a class that has the getDocComment() method, such as an object of type ReflectionClass, the create method will read that if it exists.

$docComment = <<<DOCCOMMENT
/**
 * This is an example of a summary.
 *
 * This is a Description. A Summary and Description are separated by either
 * two subsequent newlines (thus a whiteline in between as can be seen in this
 * example), or when the Summary ends with a dot (`.`) and some form of
 * whitespace.
 */
DOCCOMMENT;

$docblock = $factory->create($docComment);

The create method will yield an object of type \phpDocumentor\Reflection\DocBlock whose methods can be queried:

// Contains the summary for this DocBlock
$summary = $docblock->getSummary();

// Contains \phpDocumentor\Reflection\DocBlock\Description object
$description = $docblock->getDescription();

// You can either cast it to string
$description = (string) $docblock->getDescription();

// Or use the render method to get a string representation of the Description.
$description = $docblock->getDescription()->render();

For more examples it would be best to review the scripts in the /examples folder.

Comments
  • Exporting tags

    Exporting tags

    The export functions are not yet implemented, because it says it has to see what reflection outputs. Doesn't the getDocComment function just return the comments, as found in the php file?

    What are you planning to do with the export, let the tags return the line without the * (so just @param int $i for example), and let the docblock itself just loop through the tags and call the export function, and place the lines in the docblok comment style?

    Are you planning on implementing that, or would you like to let me make a PR?

    opened by barryvdh 21
  • Generics containing spaces not parsed correctly

    Generics containing spaces not parsed correctly

    In v4.3.2 calling \phpDocumentor\Reflection\DocBlockFactory::create for this phpDoc:

    /**
     * @return array<string, Channel>
     */
    

    will cause a RuntimeException from \phpDocumentor\Reflection\TypeResolver::parseTypes:263 with message 'A type is missing in a collection expression'.

    The bug seems to be in \phpDocumentor\Reflection\DocBlock\Tags\Return_::create:50. This split:

    $parts = preg_split('/\s+/Su', $body, 2);
    

    doesn't take generics into account. array<string, is being read as type and Channel> becomes the description. Removing the space after comma solves the problem.

    I've tried to determine if those spaces are actually a valid syntax and it seems like they kind-of-are:

    1. Grammar on phpdoc.org doesn't allow for them (on a side note, the "phpDocumentor" link in top left leads to a 404)
    2. PSR-5 grammar currently doesn't support generics too
    3. However the PSR-5 draft did allow for them before Oct 16, 2018 and spaces were allowed.
    4. The file that throws exception phpdocumentor/type-resolver/src/TypeResolver.php does itself use spaces on lines 64-65:
      /**
       * @var array<string, string> List of recognized keywords and unto which Value Object they map
       * @psalm-var array<string, class-string<Type>>
       */
      

    So the implementation seems to be inconsistent with grammar in PSR and usage in phpDocumentor/TypeResolver.

    opened by gronostajo 20
  • Use PHPUnit\Framework\TestCase instead of PHPUnit_Framework_TestCase

    Use PHPUnit\Framework\TestCase instead of PHPUnit_Framework_TestCase

    I use the PHPUnit\Framework\TestCase notation instead of PHPUnit_Framework_TestCase while extending our TestCases. This will help us migrate to PHPUnit 6, that no longer support snake case class names.

    I just need to bump PHPUnit version to ^4.8.35, that support this namespace.

    The only problem is that I could not apply this changes to the composer.lock file. If someone can help me, I'd be grateful :smile:

    opened by carusogabriel 20
  • Psalm: switch from Phive to Composer + fix (most) issues

    Psalm: switch from Phive to Composer + fix (most) issues

    Psalm: switch from Phive to Composer

    This switches the installation method for Psalm from Phive to Composer, while still using a Phar file for running Psalm.

    Includes:

    • Removing Psalm from the Phive configuration.
    • Adding Psalm to the Composer configuration. Includes upgrading from version 3.11.2 to version 4.8.1.
    • Adjusting the script used in the Makefile. 👉 Please verify and test this as things work differently on different OS-es and this should work for you.
    • Adjusting the GH Actions script to use the Composer installed version of Psalm.

    Note: due to the committed composer.lock file, Psalm will not automatically upgrade when newer versions are available.

    Refs:

    • https://github.com/vimeo/psalm/releases
    • https://github.com/psalm/phar/releases

    Utils::pregSplit: limit is not nullable

    Correctly flagged by Psalm:

    ERROR: PossiblyNullArgument - src\Utils.php:50:53 - Argument 3 of preg_split cannot be null, possibly null value provided (see https://psalm.dev/078)
            $parts = php_preg_split($pattern, $subject, $limit, $flags);
    

    The $limit argument of the PHP native preg_split() function is not nullable.

    Ref: https://www.php.net/manual/en/function.preg-split

    Tags::__toString(): remove redundant type casts

    Psalm flags these type casts as redundant:

    ERROR: RedundantCastGivenDocblockType - src/DocBlock/Tags/Author.php:80:23 - Redundant cast to string given docblock-provided type (see https://psalm.dev/263)
            $authorName = (string) $this->authorName;
    
    ERROR: RedundantCastGivenDocblockType - src/DocBlock/Tags/Example.php:150:21 - Redundant cast to string given docblock-provided type (see https://psalm.dev/263)
            $filePath = (string) $this->filePath;
    
    ERROR: RedundantCastGivenDocblockType - src/DocBlock/Tags/Link.php:74:17 - Redundant cast to string given docblock-provided type (see https://psalm.dev/263)
            $link = (string) $this->link;
    
    ERROR: RedundantCastGivenDocblockType - src/DocBlock/Tags/Method.php:228:23 - Redundant cast to string given docblock-provided type (see https://psalm.dev/263)
            $methodName = (string) $this->methodName;
    

    I have verified each and can confirm that these are redundant. They are probably a left-over from the time when the __construct() method in these classes did not yet have type declarations.

    Tags/Return: remove redundant condition

    Psalm flags this condition as redundant:

    ERROR: RedundantCondition - src/DocBlock/Tags/Return_.php:62:48 - "" can never contain non-empty-lowercase-string (see https://psalm.dev/122)
            return $type . ($description !== '' ? ($type !== '' ? ' ' : '') . $description : '');
    

    Based on the statement in the line above - $type = $this->type ? '' . $this->type : 'mixed'; -, Psalm is correct and the $type variable can never be an empty string.

    Psalm: suppress two notices

    The current version of Psalm flags the following issues:

    ERROR: InvalidReturnType - src\Utils.php:44:16 - The declared return type 'array<array-key, string>' for phpDocumentor\Reflection\Utils::pregSplit is incorrect, got 'list<list<int|string>|string>' (see https://psalm.dev/011)
         * @return string[] Returns an array containing substrings of subject split along boundaries matched by pattern
    
    ERROR: InvalidReturnStatement - src\Utils.php:55:16 - The inferred type 'list<list<int|string>|string>' does not match the declared return type 'array<array-key, string>' for phpDocumentor\Reflection\Utils::pregSplit (see https://psalm.dev/128)
            return $parts;
    

    I'm suggest ignoring this as list isn't an officially supported type.


    After this PR, there is still one issue remaining.

    Argument 4 of preg_split expects 0|1|2|3|4|5|6|7, parent type int provided (see https://psalm.dev/193)
    

    I believe this issue is for the phpDocumentor\Reflection\Utils class and expects the pregSplit() method to apply input validation to the value received for $flags before passing it off to the PHP native preg_split() function.

    IMO that's taking things a little too far as PHP will handle this internally without errors. Want me to add it to the list of issues to be ignored ? See: https://3v4l.org/NdDRK

    Side-note: the weird thing is that this issue does show up in CI, but with the same PHP + Psalm Phar version, I cannot reproduce this locally.

    opened by jrfnl 16
  • PhpStan based tag parsing

    PhpStan based tag parsing

    In this PR I'm working on an attempt to replace the regex-based parsing in each tag with a more battle tested parser that allows us to support all modern types like tools as phpstan and psalm are defining.

    • [x] implement param tag
    • [x] implement method tag
    • [x] implement return tag
    • [x] implement var tag
    • [x] implement property tag
    • [x] introduce callable params
    • [x] introduce callable return type
    • [ ] document new features
    • [ ] document new architecture
    • [x] deprecate replaced tag factories
    • [x] implement constant types

    BC promise

    This library has existed for many years and is used in many projects to get information from docblocks. We can do this fast, and reliably. The new implementation should be introduced without any BC breaks. Only changed and improved tags.

    The current approach allows external consumers to create tags based on instanciated factories. Not just the static factory methods as we knew them before. This will enable us to introduce more complex logic in the factories and add extra dependencies. Which as not fully possible in the past.

    opened by jaapio 15
  • Incorrect type resolution (parentheses, generic, etc.)

    Incorrect type resolution (parentheses, generic, etc.)

    <?php
    
    require "vendor/autoload.php";
    
    $comment = '/**
     * @return (string|Apple)
     */';
    
    $block = new \phpDocumentor\Reflection\DocBlock($comment);
    var_dump($block->getTagsByName("return")[0]->getType()); // \(string|\Apple)
    
    $block = new \phpDocumentor\Reflection\DocBlock($comment, new \phpDocumentor\Reflection\DocBlock\Context("A"));
    var_dump($block->getTagsByName("return")[0]->getType()); // \A\(string|\A\Apple)
    

    Generic types are parsed incorrectly as well; and there may be other issues. Since PSR-5 is still a draft, I didn't expect 100% compliance, but the values returned now are pretty useless. Not getting correctly parsed types blocks my project, so I'd gladly help out with this.

    The current API for getting types is getType: string and getTypes: Type\Collection (the latter basically being string[]). Unfortunately, PSR-5's types are more complicated... As a consumer I want an API that allows me to handle complex types. Something like:

    interface TypeInterface
    class ScalarType implements TypeInterface {
        public function getType() // 'string', 'int', etc.
    }
    class ArrayOfType implements TypeInterface {
        public function getItemType() // TypeInterface of the items
    }
    class GenericType implements TypeInterface {
        public function getTemplateType()
        public function getParameterTypes()
    }
    ...
    

    I think this belongs in the ReflectionDocBlock library, but I'd like some feedback before I implement this.

    opened by rainbow-alex 14
  • Make Context leaner and enable third parties to create them

    Make Context leaner and enable third parties to create them

    Contexts are necessary for factories to resolve QSEN into FQSENs based on partial namespaces and namespace aliases. These provide DocBlocks with the namespace name and namespace aliases.

    The new ContextFactory will enable third parties who don't use phpDocumentor's Reflection component to construct a Context based on a class reflector or namespace name (and file contents).

    opened by mvriel 13
  • Fix method tag for longer method names

    Fix method tag for longer method names

    I have added a testcase that currently fails, although it shouldn't. There seems to be a problem with @method annotations, when the method name gets a little bit longer. According to Regex101 it seems to result in a catastrophic backtrack, which gives me the feeling that this regex is too complicated. I tried to simplify it, but couldn't find any solution that generally worked.

    The problem is this regex, if anybody has an idea how to improve it, I am happy to implement it.

    opened by danrot 11
  • Serializer - add  test for tag removal extra spaces

    Serializer - add test for tag removal extra spaces

    When I remove last tag, extra spaces are added, that mailform the docblock. Especially with space after asterix: {$indent}* \n.

    I fixed it by condition on value in $text.

    See tests for more

    opened by TomasVotruba 11
  • do not resolve types if it's not possible

    do not resolve types if it's not possible

    Build errors: ⇾ https://travis-ci.org/github/JetBrains/phpstorm-stubs/builds/723069982

    Pull request where I try to add "&" and "..." in the docs: ⇾ https://github.com/JetBrains/phpstorm-stubs/pull/892


    This change is Reviewable

    opened by voku 10
  • PHP 7.4 fix - Ensure the existence of the 'args' key.

    PHP 7.4 fix - Ensure the existence of the 'args' key.

    This simple fix for ensuring the existence of the 'args' key.

    With PHP 7.4 on Linux and Windows, it fails without it. Weird thing is that it doesn't break on MacOSX.

    See it live here: https://github.com/ecphp/cas-bundle/actions/runs/36937260

    opened by drupol 10
  • Add more information when an InvalidTag occurs and a link to the phpDocumentor documentation

    Add more information when an InvalidTag occurs and a link to the phpDocumentor documentation

    In issue https://github.com/phpDocumentor/phpDocumentor/issues/3378, there was some confusion because the Author tag does not support a description. When the StandardTagFactory encounters a situation where an InvalidTag is generated, it would be nice if it could ask the Tag class what the expected format is and a link to the documentation; and include that in the InvalidTag so that phpDocumentor can provide better error messages in the error report

    opened by mvriel 0
  • Referring a global variable with @see $varname in a docblock causes

    Referring a global variable with @see $varname in a docblock causes

    Let's say I have the following PHP Code

    /**
     * This is a global var.
     *
     * @see $varname
     */
    $varname = "test";
    
    /**
     * This is a class
     *
     * @see $varname
     */
    class Base
    {
    }
    

    When I try to parse it

    $factory  = \phpDocumentor\Reflection\DocBlockFactory::createInstance();
    $docblock = $factory->create($docComment);
    
    

    Ir crashes the PHP engine in version 8.0.6 and 8.1.6.

    opened by oschildt 0
  • Issue with substituting curly braces {}

    Issue with substituting curly braces {}

    The DescriptionFactory class is replacing all instances of {} with }, and does not (and cannot) revert them back to {} upon render. As a result, any instance of {} in any docblock is incorrectly changed.

    This happens here. The only way I can see to get around it is to create a new DescriptionFactory class, which contains the identical code to this class, with the exception of that one line.

    I request that this library either:

    1. Properly substitute the {} back in during render
    2. Provide an easier way to bypass replacing {}.

    I'm happy to submit the fix myself if the maintainers would like to weigh in on their preference. When I removed the substitution of {}, I have found no adverse effects, so I may need more guidance as to why this is necessary before submitting a change.

    Thanks for this great library!

    Related: https://github.com/phpDocumentor/ReflectionDocBlock/issues/274

    in discussion 
    opened by bshaffer 1
  • Candidate fix for issue #255 : loosen up inline tag splitting regexp

    Candidate fix for issue #255 : loosen up inline tag splitting regexp

    Test output before :

    There was 1 failure:
    
    1) phpDocumentor\Reflection\DocBlock\DescriptionFactoryTest::testDescriptionCanParseStringWithInlineTagAndBraces
    Failed asserting that two strings are identical.
    --- Expected
    +++ Actual
    @@ @@
    -'This description has a {@link http://phpdoc.org/ This contains {braces} }'
    +'This description has a {@link http://phpdoc.org/ This contains {braces}} }'
    
    

    Test output after :

    There was 1 failure:
    
    1) phpDocumentor\Reflection\DocBlock\DescriptionFactoryTest::testDescriptionCanParseStringWithInlineTagAndBraces
    Failed asserting that two strings are identical.
    --- Expected
    +++ Actual
    @@ @@
    -'This description has a {@link http://phpdoc.org/ This contains {braces} }'
    +'This description has a {@link http://phpdoc.org/ This contains {braces}}
    
    

    The new test case still doesn't pass because the trailing space at the end of the inline tag got cleared in StandardTagFactory::create() which seems to be intended behavior (removing it solves the issue but also breaks two other tests). Discussion / guidance needed in order to move forward.

    opened by tipiak75 4
  • Inline tag handling with nested braces is not working as expected

    Inline tag handling with nested braces is not working as expected

    Given the following test case, our Description doesn't work as expected with nested braces in inline tags.

       /**
         * @uses \phpDocumentor\Reflection\DocBlock\Description
         * @uses \phpDocumentor\Reflection\DocBlock\Tags\Link
         * @uses \phpDocumentor\Reflection\DocBlock\Tags\BaseTag
         * @uses \phpDocumentor\Reflection\DocBlock\Tags\Formatter\PassthroughFormatter
         * @uses \phpDocumentor\Reflection\Types\Context
         *
         * @covers ::__construct
         * @covers ::create
         */
        public function testDescriptionCanParseStringWithInlineTagAndBraces() : void
        {
            $contents   = 'This description has a {@link http://phpdoc.org/ This contains {braces} }';
            $context    = new Context('');
            $tagFactory = m::mock(TagFactory::class);
            $tagFactory->shouldReceive('create')
                ->twice()
                ->andReturnValues(
                    [
                        new LinkTag('http://phpdoc.org/', new Description('This contains {braces}')),
                    ]
                );
    
            $factory     = new DescriptionFactory($tagFactory);
            $description = $factory->create($contents, $context);
    
            $this->assertSame($contents, $description->render());
            $this->assertSame('This description has a %1$s', $description->getBodyTemplate());
        }
    
    bug help wanted 
    opened by jaapio 5
Releases(5.3.0)
  • 5.3.0(Oct 19, 2021)

    Added

    • Get tags with type by name by @voku in https://github.com/phpDocumentor/ReflectionDocBlock/pull/260

    Deprecated

    • Nothing

    Fixed

    • Tests: fix typo in test method name by @jrfnl in https://github.com/phpDocumentor/ReflectionDocBlock/pull/279
    • Tests: fix incorrect namespace by @jrfnl in https://github.com/phpDocumentor/ReflectionDocBlock/pull/280
    • Docblock/Tags/Author: fix typo in method docblock by @jrfnl in https://github.com/phpDocumentor/ReflectionDocBlock/pull/283
    • Tests: fix missing @covers tag by @jrfnl in https://github.com/phpDocumentor/ReflectionDocBlock/pull/286
    • Tests: mark test without assertions as such by @jrfnl in https://github.com/phpDocumentor/ReflectionDocBlock/pull/285
    • GH Actions: allow for manually triggering a workflow by @jrfnl in https://github.com/phpDocumentor/ReflectionDocBlock/pull/281
    • GH Actions: simplify Composer caching by @jrfnl in https://github.com/phpDocumentor/ReflectionDocBlock/pull/282
    • Composer: fix autoload-dev directive by @jrfnl in https://github.com/phpDocumentor/ReflectionDocBlock/pull/289
    • DocBlock/Tags/Source: remove redundant code by @jrfnl in https://github.com/phpDocumentor/ReflectionDocBlock/pull/288
    • Improve line-endings for windows. by @jaapio in https://github.com/phpDocumentor/ReflectionDocBlock/pull/296
    • Fix undefined index by @villfa in https://github.com/phpDocumentor/ReflectionDocBlock/pull/298
    • PHPUnit: update configuration by @jrfnl in https://github.com/phpDocumentor/ReflectionDocBlock/pull/303
    • Phive: upgrade used version of PHPUnit by @jrfnl in https://github.com/phpDocumentor/ReflectionDocBlock/pull/292
    • Remove deprecated StaticMethod and fix comment by @kea in https://github.com/phpDocumentor/ReflectionDocBlock/pull/306

    Removed

    • Nothing

    Security

    • Nothing

    New Contributors

    • @jrfnl made their first contribution in https://github.com/phpDocumentor/ReflectionDocBlock/pull/279
    • @villfa made their first contribution in https://github.com/phpDocumentor/ReflectionDocBlock/pull/298
    • @kea made their first contribution in https://github.com/phpDocumentor/ReflectionDocBlock/pull/306

    Full Changelog: https://github.com/phpDocumentor/ReflectionDocBlock/compare/5.2.2...5.3.0

    Source code(tar.gz)
    Source code(zip)
  • 5.2.2(Sep 17, 2020)

    Added

    • Nothing

    Deprecated

    • Nothing

    Fixed

    • Update Link.php #239, thanks to @Kasp42
    • Param: fix phpdoc with reference hint #253, thanks to @voku
    • Do not resolve types if it's not possible #254, thanks to @voku

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 5.2.1(Aug 15, 2020)

    Added

    • Nothing

    Deprecated

    • Nothing

    Fixed

    • InvalidTag::flattenExceptionBacktrace() corrupts reference arguments #249, thanks to @nikic
    • Fix modified backtrace #250, thanks to @jaapio

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 5.2.0(Jul 20, 2020)

    Added

    • php 8 support, #240 thanks to @DerManoMann
    • improved php8 support, #242 thanks to @GrahamCampbell

    Deprecated

    • Nothing

    Fixed

    • Nothing

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 5.1.0(Feb 25, 2020)

    Added

    • Improved psalm support, #212 thanks to @orklah
    • BC check, thanks to @jaapio

    Deprecated

    • StaticMethod interface, #211 thanks to @orklah

    Fixed

    • ensure 'args' exist in trace, #202 thanks to @drupol
    • don't rely on 'args' in trace, not available in 7.4, #205 thanks to @remicollet
    • Restore support for long @method names, #203 thanks to @danrot and @rvanvelzen

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 5.0.0(Feb 9, 2020)

    Added

    • Support for tag specialization as described in PRS-5 using :, thanks to @jaapio

    Deprecated

    • Nothing

    Fixed

    • restore [ to be allowed as the first character of tag body, thanks to @jaapio

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 5.0.0-beta(Jan 27, 2020)

    Added

    • Nothing

    Deprecated

    • Nothing

    Fixed

    • Fix invalid return of null in standard tag factory, thanks to @jaapio

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 5.0.0-alpha9(Jan 16, 2020)

    This patch release contains a fix to enable serialization of the refelected docblocks. Before release 5.0.0-alpha8 it was possible to serialize the result of the docblock factory. With the introduction of the InvalidTag which contained an exception this option was broken. This new version restores the option to serialize the docblock result. Which is recommended to do when you need to process a lot of docblocks for caching purposes.

    Added

    • Nothing

    Deprecated

    • Nothing

    Fixed

    • Fix serialization error on InvalidTag, thanks to @jaapio

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 5.0.0-alpha8(Jan 13, 2020)

    This patch release contains a breaking change for libraries/applications collecting exceptions from reflected docblocks. The library will now create an InvalidTag type and adds that to the output. The InvalidTag object will contain full information about the tag that could not be processed and the triggered exception during the processing of the tag.

    Added

    • InvalidTag tag. #198, thanks to @jaapio

    Deprecated

    • Nothing

    Fixed

    • Docblocks containing invalid / misused tags will now be processed, #198 thanks to @jaapio

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 4.3.4(Dec 28, 2019)

    This patch release fixes a BC break in the previous release of this series. Due a change in the collection handling a different exception was thrown when a generic type hint was read. array<string, string> this library will not support the generics notation. We just made sure that we are behaving equally to what we did before.

    Added

    • Nothing

    Deprecated

    • Nothing

    Fixed

    • Fixed invalid implementation on example tag #181, thanks to @mvriel
    • Fixed breaking change of different exception thrown with generics, #186
    • Travis build is back to green, thanks to @GrahamCampbell and @mvriel

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 5.0.0-alpha7(Dec 28, 2019)

    This patch release fixes a BC break in the previous release of this series. Due to a change in the collection handling a different exception was thrown when a generic type hint was read. array<string, string> this library will not support the generics notation. We just made sure that we are behaving equally to what we did before.

    Added

    • Nothing

    Deprecated

    • Nothing

    Fixed

    • Fixed invalid implementation on example tag #181, thanks to @mvriel
    • Fixed breaking change of different exception thrown with generics, #186
    • Travis build is back to green, thanks to @GrahamCampbell and @mvriel

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 5.0.0-alpha6(Dec 20, 2019)

    Added

    • Nothing

    Deprecated

    • Nothing

    Fixed

    • @method Invalid method name with no arguments #174 thanks to @othercorey

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 4.3.3(Dec 20, 2019)

    Added

    • Nothing

    Deprecated

    • Nothing

    Fixed

    • @method Invalid method name with no arguments #174 thanks to @othercorey

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 4.3.2(Sep 12, 2019)

    Added

    • Support for TypeResolver v1 #177 #178 thanks to @alexander-schranz

    Deprecated

    • Nothing

    Fixed

    • Nothing

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 5.0.0-alpha5(Jun 15, 2019)

    Added

    • Nothing

    Deprecated

    • Nothing

    Fixed

    • Prevent invalid bodies for tags to break the whole parsing process. They are now silently ignored

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 5.0.0-alpha4(Apr 30, 2019)

  • 4.3.1(Apr 30, 2019)

  • 5.0.0-alpha3(Jun 20, 2018)

  • 5.0.0-alpha2(Jun 14, 2018)

  • 5.0.0-alpha1(Jan 31, 2018)

  • 4.2.0(Nov 27, 2017)

    Added

    • Added getTags method to Description
    • Added removeTag method to Docblock
    • Improved code analysis.

    Deprecated

    • Nothing

    Fixed

    • Improved validation of method tag.

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 3.3.2(Nov 20, 2017)

  • 3.3.0(Sep 11, 2017)

    Added

    • getTags on descriptor #122 thanks to @Warxcell

    Deprecated

    • Nothing

    Fixed

    • Switched to stable release of reflection-common library

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 4.1.1(Aug 30, 2017)

    Added

    • Nothing

    Deprecated

    • Nothing

    Fixed

    • Namespace error in ExampleFinder
    • Example tag is not returning its name
    • Bug with @var tag in docblock #117 thanks to @Warxcell

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 3.2.3(Aug 30, 2017)

    Added

    • Nothing

    Deprecated

    • Nothing

    Fixed

    • Namespace error in ExampleFinder
    • Example tag is not returning its name
    • Bug with @var tag in docblock #117 thanks to @Warxcell

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 4.1.0(Aug 19, 2017)

    Added

    • Improved example tag handling

    Deprecated

    • Nothing

    Fixed

    • Error when fetching the content of an example tag without description

    Removed

    • Nothing

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 4.0.1(Aug 8, 2017)

  • 4.0.0(Aug 4, 2017)

    Please note that this version contains several BC breaks. Type-resolver has some breaking changes when upgrading from 0.3 to 0.4. And the constructor of the @see tag was changed to support urls and fqsen. See #104 for more details.

    Added

    • Upgraded type-resolver to 0.4.0 to support more php 7.1 features.
    • Allow see tag to url #104

    Deprecated

    • Nothing

    Fixed

    • Nothing

    Removed

    • Drop php 5 support
    • Drop hhvm support

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
  • 3.2.1(Aug 4, 2017)

    Added

    • Nothing

    Deprecated

    • Nothing

    Fixed

    • Release 3.2.0 fails when parsing annotations #108
    • 3.2.0 has breaking change #109

    Removed

    • Removed support for type resolver 0.4.0 since it contains a BC break.

    Security

    • Nothing
    Source code(tar.gz)
    Source code(zip)
Owner
phpDocumentor
phpDocumentor