Code Coverage
 
Classes and Traits
Functions and Methods
Lines
Total
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
2 / 2
CRAP
100.00% covered (success)
100.00%
3 / 3
MagicProperties
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
2 / 2
4
100.00% covered (success)
100.00%
3 / 3
 __get
n/a
0 / 0
1
n/a
0 / 0
 __set
100.00% covered (success)
100.00%
1 / 1
2
100.00% covered (success)
100.00%
2 / 2
 __isset
100.00% covered (success)
100.00%
1 / 1
1
100.00% covered (success)
100.00%
1 / 1
<?php declare(strict_types=1);
namespace Aviat\Kilo\Traits;
trait MagicProperties {
    abstract public function __get(string $name);
    public function __set(string $name, $value)
    {
        if (property_exists($this, $name))
        {
            $this->$name = $value;
        }
    }
    public function __isset(string $name): bool
    {
        return isset($this->$name);
    }
}