Удалил мусор

This commit is contained in:
Artem Vasilev 2024-03-06 12:52:45 +03:00
parent 341a6f3ac1
commit c8e9e4127a

View File

@ -1,47 +0,0 @@
<?php
namespace Webmasterskaya\Component\OauthServer\Administrator\Table;
use Webmasterskaya\Component\OauthServer\Administrator\Helper\CasesHelper;
trait PropertyManagerTrait
{
public function __get($name)
{
// All protected properties names must start with _
if (str_starts_with($name, '_')) {
return null;
}
// If class has getter for property
$getterName = 'get' . CasesHelper::camelize($name, true);
if (method_exists($this, $getterName)) {
return call_user_func([$this, $getterName]);
}
if (isset($this->$name)) {
return $name;
}
return null;
}
public function __set($name, $value)
{
// All protected properties names must start with _
if (str_starts_with($name, '_')) {
return;
}
// If class has setter for property
$setterName = 'set' . CasesHelper::camelize($name, true);
if (method_exists($this, $setterName)) {
call_user_func([$this, $setterName], $value);
return;
}
if (isset($this->$name)) {
$this->$name = $value;
}
}
}