app\helpers\Enforcer::__add PHP 메소드

__add() 공개 정적인 메소드

public static __add ( $class, $c )
    public static function __add($class, $c)
    {
        $reflection = new \ReflectionClass($class);
        $constantsForced = $reflection->getConstants();
        foreach ($constantsForced as $constant => $value) {
            if (constant("{$c}::{$constant}") == "abstract") {
                throw new \Exception("Undefined {$constant} in " . (string) $c);
            }
        }
    }
Enforcer