PHPackages                             mheinzerling/entity - 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. [Database &amp; ORM](/categories/database)
4. /
5. mheinzerling/entity

ActiveLibrary[Database &amp; ORM](/categories/database)

mheinzerling/entity
===================

Simple ORM

3.0.0(9y ago)030MITPHPPHP ^7.1.0

Since Nov 2Pushed 8y ago1 watchersCompare

[ Source](https://github.com/mheinzerling/php-entity)[ Packagist](https://packagist.org/packages/mheinzerling/entity)[ RSS](/packages/mheinzerling-entity/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependencies (9)Versions (7)Used By (0)

[![Build Status](https://camo.githubusercontent.com/870ef1c2396558e6e137800bd367d66a79b338d6ae66122178155015dd6ad4c0/68747470733a2f2f7472617669732d63692e6f72672f6d6865696e7a65726c696e672f7068702d656e746974792e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/mheinzerling/php-entity) [![Code Climate](https://camo.githubusercontent.com/29c07188fc4421655a40fff31ebc14df845a49012eabf2b9f021a475867dad3c/68747470733a2f2f636f6465636c696d6174652e636f6d2f6769746875622f6d6865696e7a65726c696e672f7068702d656e746974792f6261646765732f6770612e737667)](https://codeclimate.com/github/mheinzerling/php-entity) [![Test Coverage](https://camo.githubusercontent.com/2d05e01b95d295a9830ae96a54d10357559e311d630c3d99dbbc12bc67fa01f7/68747470733a2f2f636f6465636c696d6174652e636f6d2f6769746875622f6d6865696e7a65726c696e672f7068702d656e746974792f6261646765732f636f7665726167652e737667)](https://codeclimate.com/github/mheinzerling/php-entity/coverage) [![Issue Count](https://camo.githubusercontent.com/b50d27138741bf2b63755912cc44a6792a97304b819708aeaf9b6f4e4c9773d9/68747470733a2f2f636f6465636c696d6174652e636f6d2f6769746875622f6d6865696e7a65726c696e672f7068702d656e746974792f6261646765732f69737375655f636f756e742e737667)](https://codeclimate.com/github/mheinzerling/php-entity)

\#mheinzerling/entity

Simple ORM

\##Composer "require": { "mheinzerling/entity": "^3.0.1" },

\##Types

```
Integer     -> INT (length)
String
 length VARCHAR
            -> TEXT
\DateTime   -> DATETIME
Boolean     -> INT (1)
Entity      -> INT(11)

optional    -> NULL vs NOT NULL
auto        -> AUTO_INCREMENT
primary     -> default

```

\##Example

See `resources/tests/entities.json` and `build.xml gen`. The parser will tell you invalid configurations.

\##Changelog

### 3.0.0

[](#300)

- update to PHP 7.1

### 2.0.0

[](#200)

- update to PHP 7
- update enumeration library and symphony console
- !!! PDO toObject seems to change in 7.1; Test broken !!!

### 1.2.0

[](#120)

- update dependencies
- add foreign keys

### 1.1.0

[](#110)

- improve enums
- add double
- improve datetime mapping

### 1.0.0

[](#100)

initial version

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity62

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

Every ~12 days

Total

6

Last Release

3466d ago

Major Versions

1.2.0 → 2.0.02016-11-04

2.0.1 → 3.0.02017-01-01

PHP version history (3 changes)2.0.0PHP &gt;=7.0.0

2.0.1PHP ^7.0.0

3.0.0PHP ^7.1.0

### Community

Maintainers

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

---

Top Contributors

[![mheinzerling](https://avatars.githubusercontent.com/u/2889071?v=4)](https://github.com/mheinzerling "mheinzerling (46 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/mheinzerling-entity/health.svg)

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

###  Alternatives

[perplorm/perpl

Perpl is an improved and still maintained fork of Propel2, an open-source Object-Relational Mapping (ORM) for PHP.

249.4k](/packages/perplorm-perpl)

PHPackages © 2026

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