PHPackages                             mfn/php-reflection-gen - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. mfn/php-reflection-gen

AbandonedArchivedLibrary[Utility &amp; Helpers](/categories/utility)

mfn/php-reflection-gen
======================

Generates PHP source code shells from the current runtime via Reflections

v0.0.4(11y ago)0611MITPHPPHP &gt;=5.4.0

Since Oct 12Pushed 7y ago1 watchersCompare

[ Source](https://github.com/mfn/php-reflection-gen)[ Packagist](https://packagist.org/packages/mfn/php-reflection-gen)[ Docs](http://github.com/mfn/php-reflection-gen)[ RSS](/packages/mfn-php-reflection-gen/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (1)Versions (5)Used By (1)

Reflection based PHP stub generator
===================================

[](#reflection-based-php-stub-generator)

Homepage:

Blurb
=====

[](#blurb)

Uses the reflection capabilities of the current PHP runtime and emits all classes, interfaces, traits and functions in parsable (but probably not runnable) PHP code.

Install / Usage
===============

[](#install--usage)

```
composer require mfn/php-reflection-gen 0.0.5

```

`php_reflection_gen.php`

Will output all reflected data to stdout. Optionally you can write it to a file or to a directory.

In case using `--directory`, for each PHP extension a separate file is created.

TODOs / Ideas
=============

[](#todos--ideas)

- Properly handle namespaces (currently not a concern because of no PHP internals use Namespaces)
- Handle non-internal PHP reflections
- Support older (&lt;5.4) PHP versions

© Markus Fischer

###  Health Score

24

—

LowBetter than 31% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity51

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 ~5 days

Total

4

Last Release

4265d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/4f0d4e7638e419a48dde77f4c481fb1eb2dbe8f5fe913e68e26269ee7e051ade?d=identicon)[mfn](/maintainers/mfn)

---

Top Contributors

[![mfn](https://avatars.githubusercontent.com/u/87493?v=4)](https://github.com/mfn "mfn (15 commits)")

---

Tags

codereflectiongenerator

### Embed Badge

![Health badge](/badges/mfn-php-reflection-gen/health.svg)

```
[![Health](https://phpackages.com/badges/mfn-php-reflection-gen/health.svg)](https://phpackages.com/packages/mfn-php-reflection-gen)
```

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M346](/packages/psalm-plugin-laravel)[friendsoftypo3/content-blocks

TYPO3 CMS Content Blocks - Content Types API | Define reusable components via YAML

103519.9k53](/packages/friendsoftypo3-content-blocks)[phel-lang/phel-lang

Phel is a functional programming language that compiles to PHP

5186.0k18](/packages/phel-lang-phel-lang)[dagger/dagger

Dagger PHP SDK

261.1k](/packages/dagger-dagger)

PHPackages © 2026

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