PHPackages                             synga/inheritance-finder - 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. synga/inheritance-finder

ActiveLibrary

synga/inheritance-finder
========================

This package can find classes which are extended, implemented by a certain class or is using a certain trait.

1.0.9(10y ago)08651MITPHPPHP &gt;=5.4

Since Jan 19Pushed 10y ago1 watchersCompare

[ Source](https://github.com/synga-nl/inheritance-finder)[ Packagist](https://packagist.org/packages/synga/inheritance-finder)[ RSS](/packages/synga-inheritance-finder/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)Dependencies (3)Versions (15)Used By (1)

Inheritance Finder
==================

[](#inheritance-finder)

This package can find classes which are extended, implemented or is using a certain trait. It builds a cache and uses it to find the desired files.

\##Usage

```
$config = new \Synga\InheritanceFinder\File\FileConfig();
$config->setApplicationRoot(__DIR__);
$config->setCacheDirectory(__DIR__);

$inheritanceFinder = Synga\InheritanceFinder\InheritanceFinderFactory::getInheritanceFinder($config);
$inheritanceFinder->findExtends('SomeNamespace\OtherNamespacePath\Class');

```

It will now find all classes which inherit from class `SomeNamespace\OtherNamespacePath\Class` whithin your `ApplicationRoot` directory

\##Possible options:

- `findClass('full qualified namespace')` - Can locate a file with the given namespace in the given directory
- `findExtends('full qualified namespace')` - Can locate multiple classes which inherit from the given class in the given directory
- `findImplements('full qualified namespace')` - Can locate multiple classes which implement or inherit from the given interface in the given directory
- `findTraitUse('full qualified namespace')` - Can locate multiple classes which uses the given trait in the given directory
- `findMultiple('Classes [string or array of strings]', 'Interfaces [string or array of strings]', 'Traits [string or array of strings]')` - Can locate multiple classes at once, it uses the methods discribed above.

\##Acknowledgements:

- Right now this package cannot handle multiple classes in one file. I will try to fix this in the near future.
- The first run will be slow, because it is indexing all the files in your project root. I'm thinking off a manner to make it faster. I am planning of using react php for this so we can use multiple processes.
- Don't use this code in production (you can use it FOR production, to build a cache of files). The performance results are strongly depending your hardware.

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity66

Established project with proven stability

 Bus Factor1

Top contributor holds 91.9% 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 ~8 days

Recently: every ~22 days

Total

14

Last Release

3653d ago

Major Versions

0.2.2 → 1.0.02016-02-03

### Community

Maintainers

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

---

Top Contributors

[![rpouls](https://avatars.githubusercontent.com/u/2946593?v=4)](https://github.com/rpouls "rpouls (34 commits)")[![synga-nl](https://avatars.githubusercontent.com/u/16606813?v=4)](https://github.com/synga-nl "synga-nl (3 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/synga-inheritance-finder/health.svg)

```
[![Health](https://phpackages.com/badges/synga-inheritance-finder/health.svg)](https://phpackages.com/packages/synga-inheritance-finder)
```

###  Alternatives

[zircote/swagger-php

Generate interactive documentation for your RESTful API using PHP attributes (preferred) or PHPDoc annotations

5.3k132.9M468](/packages/zircote-swagger-php)[infection/infection

Infection is a Mutation Testing framework for PHP. The mutation adequacy score can be used to measure the effectiveness of a test set in terms of its ability to detect faults.

2.2k26.2M1.8k](/packages/infection-infection)[humbug/php-scoper

Prefixes all PHP namespaces in a file or directory.

7963.0M35](/packages/humbug-php-scoper)[silverstripe/framework

The SilverStripe framework

7213.5M2.5k](/packages/silverstripe-framework)[prestashop/prestashop

PrestaShop is an Open Source e-commerce platform, committed to providing the best shopping cart experience for both merchants and customers.

9.0k15.4k](/packages/prestashop-prestashop)[coenjacobs/mozart

Composes all dependencies as a package inside a WordPress plugin

4723.6M20](/packages/coenjacobs-mozart)

PHPackages © 2026

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