Nette\Utils\ObjectMixin::remove PHP Method

remove() public static method

__unset() implementation.
public static remove ( $_this, $name ) : void
return void
    public static function remove($_this, $name)
    {
        $class = get_class($_this);
        if (!self::hasProperty($class, $name)) {
            throw new MemberAccessException("Cannot unset the property {$class}::\${$name}.");
        }
    }

Usage Example

Example #1
0
 /**
  * Removes property.
  * @param  string  property name
  * @return void
  * @throws Nette\MemberAccessException
  */
 public function __unset($name)
 {
     Nette\Utils\ObjectMixin::remove($this, $name);
 }
All Usage Examples Of Nette\Utils\ObjectMixin::remove