<?php

namespace lib\Core;

abstract class Entity
{
    private $_values = [];
    protected function __construct($datas)
    {
        $this->_values = $datas;
    } //
    final public function __get($name)
    {
        return $this->_values[$name];
    }
    final public function __set($name, $value)
    {
        $this->_values[$name] = $value;
    }
    final public function toArray(): array
    {
        return $this->_values;
    }
} //Class
