PHPackages                             sanmai/callable-reflection - 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. sanmai/callable-reflection

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

sanmai/callable-reflection
==========================

ReflectionFunctionAbstract for any callable

1.0.1(1mo ago)10Apache-2.0PHPPHP ^8.2CI passing

Since Jul 26Pushed 1mo agoCompare

[ Source](https://github.com/sanmai/callable-reflection)[ Packagist](https://packagist.org/packages/sanmai/callable-reflection)[ GitHub Sponsors](https://github.com/sanmai)[ RSS](/packages/sanmai-callable-reflection/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (2)Dependencies (10)Versions (8)Used By (0)

CallableReflection
==================

[](#callablereflection)

Get `ReflectionFunctionAbstract` for any callable.

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

[](#installation)

```
composer require sanmai/callable-reflection
```

Usage
-----

[](#usage)

```
use CallableReflection\CallableReflection;

$reflection = new CallableReflection();
$params = $reflection->reflect($callable)->getNumberOfParameters();
```

Works with closures, functions, methods, invokable objects, and first-class callables.

Unlike with `ReflectionFunction(Closure::fromCallable($callable))`, you can dependency-inject it.

###  Health Score

42

—

FairBetter than 88% of packages

Maintenance94

Actively maintained with recent releases

Popularity2

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity54

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 55.6% 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 ~357 days

Total

2

Last Release

30d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/edcb8dde95c71b1c97c3c91e57d3548795fa2014c657744fb878e2be3b5949fc?d=identicon)[sanmai](/maintainers/sanmai)

---

Top Contributors

[![sanmai](https://avatars.githubusercontent.com/u/139488?v=4)](https://github.com/sanmai "sanmai (5 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (4 commits)")

---

Tags

callablemetaprogrammingrelfectionrelfection-api

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/sanmai-callable-reflection/health.svg)

```
[![Health](https://phpackages.com/badges/sanmai-callable-reflection/health.svg)](https://phpackages.com/packages/sanmai-callable-reflection)
```

PHPackages © 2026

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