PHPackages                             kwizer/hydrator - 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. kwizer/hydrator

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

kwizer/hydrator
===============

Hydrator

1.0.0(8y ago)012MITPHP

Since Apr 9Pushed 8y ago1 watchersCompare

[ Source](https://github.com/kwizer15/hydrator)[ Packagist](https://packagist.org/packages/kwizer/hydrator)[ RSS](/packages/kwizer-hydrator/feed)WikiDiscussions master Synced 2w ago

READMEChangelogDependencies (2)Versions (2)Used By (0)

Hydrator
========

[](#hydrator)

[![Build Status](https://camo.githubusercontent.com/108890175b4d8b7cd736bed06bdac95787e0869eec2680449050be15f3d5aeb7/68747470733a2f2f7472617669732d63692e6f72672f6b77697a657231352f6879647261746f722e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/kwizer15/hydrator)

A simple hydrator without mapping.

Why
---

[](#why)

Hydrate an instance simply with a data source.

How
---

[](#how)

Instantiate the hydrator and call the hydrate method with the object to hydrate and the data source

```
class MyClass
{
    private $foo;
}

$myDatas = ['foo' => 'bar'];
$hydrator = new \Kwizer\Hydrator\Hydrator();
$myObject = $hydrator->hydrate(MyClass::class, $myDatas);
```

You can directly hydrate an object already instantiated.

```
$myObject = new MyClass();
$myObject = $hydrator->hydrate($myObject, $myDatas);
```

Or hydrate with an object source

```
$datas = new \stdClass();
$datas->foo = 'bar';
$myObject = $hydrator->hydrate(MyClass::class, $myDatas);
```

The hyrator uses the with methods and set methods first if presents, then directly the property, breaking accessibility if necessary.

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

[](#installation)

```
composer require kwizer/hydrator
```

###  Health Score

26

—

LowBetter than 41% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity63

Established project with proven stability

 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

Unknown

Total

1

Last Release

3004d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/567118?v=4)[kwizer15](/maintainers/kwizer15)[@kwizer15](https://github.com/kwizer15)

---

Top Contributors

[![kwizer15](https://avatars.githubusercontent.com/u/567118?v=4)](https://github.com/kwizer15 "kwizer15 (3 commits)")

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/kwizer-hydrator/health.svg)

```
[![Health](https://phpackages.com/badges/kwizer-hydrator/health.svg)](https://phpackages.com/packages/kwizer-hydrator)
```

PHPackages © 2026

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