PHPackages                             sinema/data-entities - 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. sinema/data-entities

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

sinema/data-entities
====================

1.0.4(2y ago)02.6k↓33.3%MITPHPPHP ^8.1.0

Since Jun 4Pushed 2y ago1 watchersCompare

[ Source](https://github.com/SineMah/data-entities)[ Packagist](https://packagist.org/packages/sinema/data-entities)[ Docs](https://github.com/SineMah/data-entities)[ RSS](/packages/sinema-data-entities/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (4)Dependencies (1)Versions (5)Used By (0)

Data Entities
=============

[](#data-entities)

A small lib to transfer from one application layer to another.
Valinor and Laravel-Data ain't focussing on a DTO core principle. Data Entities has some convenient methods included.

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

[](#installation)

```
composer require sinema/data-entities
```

Attributes
----------

[](#attributes)

### Basic Attributes

[](#basic-attributes)

```
use Sinemah\DataEntities\Data;

class Message extends Data
{
    public string $text;
    public string $user;
    public int $created_at;
}
```

### Required Attributes

[](#required-attributes)

```
use Sinemah\DataEntities\Data;
use Sinemah\DataEntities\Entity\Requireable;

class Message extends Data
{
    use Requireable;

    protected array $requireable = [
        'text',
        'user',
        'created_at',
    ];

    public string $text;
    public string $user;
    public int $created_at;
}
```

Load from Array
---------------

[](#load-from-array)

```
$message = Message::from(['user' => 'John Smith', 'text' => 'Lorem Ipsum']);
```

To Array
--------

[](#to-array)

```
$message->toArray();
```

Get Single Values
-----------------

[](#get-single-values)

Also works neither attributes are not initialized nor exists.

```
$message->get('user');
```

###  Health Score

29

—

LowBetter than 59% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity20

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity56

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

Total

4

Last Release

858d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/4c724946ecaf2263bfb587aee2290213b844f9169c4173836dac26f1fa863eab?d=identicon)[SineMah](/maintainers/SineMah)

---

Top Contributors

[![SineMah](https://avatars.githubusercontent.com/u/8180962?v=4)](https://github.com/SineMah "SineMah (11 commits)")

---

Tags

data transfer objects

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/sinema-data-entities/health.svg)

```
[![Health](https://phpackages.com/badges/sinema-data-entities/health.svg)](https://phpackages.com/packages/sinema-data-entities)
```

PHPackages © 2026

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