PHPackages                             talesoft/tale-factory - 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. talesoft/tale-factory

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

talesoft/tale-factory
=====================

A generic factory implementation

0.3(7y ago)142.0k↑23.5%3MITPHPPHP &gt;=7.1.0

Since May 20Pushed 7y ago3 watchersCompare

[ Source](https://github.com/Talesoft/tale-factory)[ Packagist](https://packagist.org/packages/talesoft/tale-factory)[ Docs](http://docs.talesoft.codes/php/tale/factory)[ RSS](/packages/talesoft-tale-factory/feed)WikiDiscussions master Synced 1mo ago

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

Tale Factory
============

[](#tale-factory)

What is Tale Factory?
---------------------

[](#what-is-tale-factory)

A generic implementation of the factory pattern.

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

[](#installation)

```
composer require talesoft/tale-factory
```

Usage
-----

[](#usage)

```
use Tale\Factory;

interface AdapterInterface
{
    public function sayHello(): void;
}

class TestAdapter
{
    private $message;

    public function __construct(string $message)
    {
        $this->message = $message;
    }

    public function sayHello(): void
    {
        echo $this->message;
    }
}

$factory = new Factory(
    AdapterInterface::class,
    ['Hello from adapter!'],
    [
        'test' => TestAdapter::class
    ]
);

$instance = $factory->get('test');
$instance->sayHello(); //"Hello from adapter!"
```

TODO: More docs.

###  Health Score

31

—

LowBetter than 68% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity29

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity50

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

Total

3

Last Release

2675d ago

PHP version history (2 changes)0.1PHP &gt;=5.5.0

0.2PHP &gt;=7.1.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/75a80e0830e63c723808d021d3a1648a2643db60f4ac2e40842da05f227f956b?d=identicon)[TorbenKoehn](/maintainers/TorbenKoehn)

---

Top Contributors

[![TorbenKoehn](https://avatars.githubusercontent.com/u/1403556?v=4)](https://github.com/TorbenKoehn "TorbenKoehn (14 commits)")

---

Tags

factory

### Embed Badge

![Health badge](/badges/talesoft-tale-factory/health.svg)

```
[![Health](https://phpackages.com/badges/talesoft-tale-factory/health.svg)](https://phpackages.com/packages/talesoft-tale-factory)
```

###  Alternatives

[aura/dispatcher

Creates objects from a factory and invokes methods using named parameters; also provides a trait for invoking closures and object methods with named parameters.

3695.0k3](/packages/aura-dispatcher)[nikolaposa/cascader

Utility for creating objects in PHP from constructor parameters definitions.

12237.5k3](/packages/nikolaposa-cascader)[illuminatech/array-factory

Allows DI aware object creation from array definition

2159.6k6](/packages/illuminatech-array-factory)[aerni/factory

Quickly whip up fake content

193.5k](/packages/aerni-factory)

PHPackages © 2026

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