PHPackages                             unofficialmc2/instance-resolver - 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. unofficialmc2/instance-resolver

ActiveLibrary

unofficialmc2/instance-resolver
===============================

Resolver d'instance, auto link

v2.2.1(3mo ago)01.4k↓100%MITPHPPHP ^8.3

Since Jul 16Pushed 3mo agoCompare

[ Source](https://github.com/unofficialmc2/instance-resolver)[ Packagist](https://packagist.org/packages/unofficialmc2/instance-resolver)[ RSS](/packages/unofficialmc2-instance-resolver/feed)WikiDiscussions main Synced today

READMEChangelogDependencies (5)Versions (13)Used By (0)

instance-resolver
=================

[](#instance-resolver)

Usage
-----

[](#usage)

```
use InstanceResolver\ResolverClass;
class A
{
    public $prop = 0;
}
class B extends A
{
    public $prop = 0;
}
class C
{
    public function __construct(A $a){}
}
class D
{
    public function __construct($x){}
}
$resolver = new ResolverClass($container);
$a = $resolver(A::class);
$b = $resolver(B::class);
$c = $resolver(C::class);
$d = $resolver(D::class); // throw new InstanceResolver\Exception\UnresolvedParameter
                          // --> le paramètre $x ne peut pas être résolu
$e = $resolver('E'); // throw new InstanceResolver\Exception\UnresolvedClass
                     // --> la classe E n'existe pas et n'a pas été trouvé par l'autoloader
```

Pour déclarer les dépendance dans le Container, il faut utiliser les nom de classe complet.

TODO
----

[](#todo)

### version 1.0

[](#version-10)

- résoudre le problème de namespace
- coriger tout les tests
- faire l'ébauche de la doc
- publier la version 1.0

###  Health Score

51

—

FairBetter than 96% of packages

Maintenance79

Regular maintenance activity

Popularity18

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity80

Battle-tested with a long release history

 Bus Factor1

Top contributor holds 90.2% 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 ~211 days

Recently: every ~289 days

Total

12

Last Release

111d ago

Major Versions

v1.5.1 → v2.0.02022-09-29

PHP version history (3 changes)v1.2.0PHP ^7.2

v2.0.0PHP ^8.1

v2.2.0PHP ^8.3

### Community

Maintainers

![](https://www.gravatar.com/avatar/948a3fbddec48cf11b010a0c70603ad8a9ce74675ce382f741e3dca16cf315f6?d=identicon)[unofficialmc2](/maintainers/unofficialmc2)

---

Top Contributors

[![fzed51](https://avatars.githubusercontent.com/u/1201984?v=4)](https://github.com/fzed51 "fzed51 (37 commits)")[![gillesVasse](https://avatars.githubusercontent.com/u/127934677?v=4)](https://github.com/gillesVasse "gillesVasse (3 commits)")[![f4-b1](https://avatars.githubusercontent.com/u/125667350?v=4)](https://github.com/f4-b1 "f4-b1 (1 commits)")

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP\_CodeSniffer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/unofficialmc2-instance-resolver/health.svg)

```
[![Health](https://phpackages.com/badges/unofficialmc2-instance-resolver/health.svg)](https://phpackages.com/packages/unofficialmc2-instance-resolver)
```

###  Alternatives

[akrabat/ip-address-middleware

PSR-15 middleware that determines the client IP address and stores it as a ServerRequest attribute

1702.4M15](/packages/akrabat-ip-address-middleware)[internal/dload

Downloads binaries.

97124.8k6](/packages/internal-dload)

PHPackages © 2026

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