PHPackages                             dannykopping/docblock - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. dannykopping/docblock

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

dannykopping/docblock
=====================

A simple library for parsing PHP DocBlock comments

0.5.2(12y ago)191.8k12MITPHPPHP &gt;=5.3.0

Since Oct 5Pushed 12y ago2 watchersCompare

[ Source](https://github.com/dannykopping/PHPDocBlock-lite)[ Packagist](https://packagist.org/packages/dannykopping/docblock)[ Docs](https://github.com/dannykopping/PHPDocBlock-lite)[ RSS](/packages/dannykopping-docblock/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (1)Versions (8)Used By (2)

PHP DocBlock *Lite*
===================

[](#php-docblock-lite)

[![Build Status](https://camo.githubusercontent.com/9228d687bb831d82fd61ee7eeb84fa47e15469099cc31788f33f0fd65384f542/68747470733a2f2f7365637572652e7472617669732d63692e6f72672f64616e6e796b6f7070696e672f504850446f63426c6f636b2d6c6974652e706e67)](http://travis-ci.org/dannykopping/PHPDocBlock-lite)[![Scrutinizer Quality Score](https://camo.githubusercontent.com/e234380085acbff821623a3510622cfd9f495dd01cef94be202e530db4e67e75/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f64616e6e796b6f7070696e672f504850446f63426c6f636b2d6c6974652f6261646765732f7175616c6974792d73636f72652e706e673f733d37346630373132653036633438376633626330366334616464303864656465303863643831306631)](https://scrutinizer-ci.com/g/dannykopping/PHPDocBlock-lite/)

### WTF is a DocBlock?

[](#wtf-is-a-docblock)

A DocBlock is a block comment in PHP (with optional annotations):

```
/**
* Optional DocBlock comment
*
* @annotation	I'm an annotation!
*/
```

Installation
------------

[](#installation)

Download or clone the repository and add a `require_once` statement to include the `Parser` class.

```

```

Usage
-----

[](#usage)

phpDBL (PHP DocBlock Lite) uses the `Reflection` API (available from PHP 5) to allow you to retrieve the DocBlock comments. phpDBL will then inspect all the methods available in any given class and examine their DocBlocks.

```

```

You can also retrieve a list of given annotations:

```

```

Which will produce:

```
test
@param
Array
(
    [0] => $data
    [1] => The data to be passed in
)
```

Full Example
------------

[](#full-example)

```

```

Contact
-------

[](#contact)

Feel free to suggest feature requests by creating an "Issue" or by forking the repo, making the changes yourself and sending me a pull request.

###  Health Score

30

—

LowBetter than 62% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity24

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity53

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~93 days

Recently: every ~135 days

Total

7

Last Release

4461d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/373762?v=4)[Danny Kopping](/maintainers/dannykopping)[@dannykopping](https://github.com/dannykopping)

---

Top Contributors

[![dannykopping](https://avatars.githubusercontent.com/u/373762?v=4)](https://github.com/dannykopping "dannykopping (39 commits)")

---

Tags

parserreflectiondocblockparse

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/dannykopping-docblock/health.svg)

```
[![Health](https://phpackages.com/badges/dannykopping-docblock/health.svg)](https://phpackages.com/packages/dannykopping-docblock)
```

###  Alternatives

[doctrine/lexer

PHP Doctrine Lexer parser library that can be used in Top-Down, Recursive Descent Parsers.

11.2k959.4M160](/packages/doctrine-lexer)[phpowermove/docblock

PHP Docblock parser and generator. An API to read and write Docblocks.

2527.3M4](/packages/phpowermove-docblock)[olamedia/nokogiri

HTML Parser

23178.0k3](/packages/olamedia-nokogiri)[jan-swiecki/simple-annotations

Simple annotation parser

68638.8k19](/packages/jan-swiecki-simple-annotations)[adci/full-name-parser

Parses a human name

29751.3k7](/packages/adci-full-name-parser)[dimabdc/php-fast-simple-html-dom-parser

PHP Fast Simple HTML DOM parser.

9055.5k](/packages/dimabdc-php-fast-simple-html-dom-parser)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
