X-Git-Url: https://git.mxchange.org/?p=core.git;a=blobdiff_plain;f=inc%2Fclasses%2Fmain%2Fclass_BaseFrameworkSystem.php;h=7d5ac4a8578bd043d1b3ccc55c79b264b1657b8d;hp=c890cc23c0529f3c0109a00ed19e3c19f68da5f4;hb=a6ec0211ffb9b65e7c8efd81abdbb925774264ff;hpb=50861b4a1cc38134c915eb989ad249bbe6c8e601 diff --git a/inc/classes/main/class_BaseFrameworkSystem.php b/inc/classes/main/class_BaseFrameworkSystem.php index c890cc23..7d5ac4a8 100644 --- a/inc/classes/main/class_BaseFrameworkSystem.php +++ b/inc/classes/main/class_BaseFrameworkSystem.php @@ -310,6 +310,33 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface { return $this->realClass; } + /** + * Magic function to catch setting of missing but set class fields/attributes + * + * @param $name Name of the field/attribute + * @param $value Value to store + * @return void + */ + public final function __set ($name, $value) { + $this->debugOutput(sprintf("Tried to set a missing field. name=%s, value[%s]=%s", + $name, + gettype($value), + $value + )); + } + + /** + * Magic function to catch getting of missing fields/attributes + * + * @param $name Name of the field/attribute + * @return void + */ + public final function __get ($name) { + $this->debugOutput(sprintf("Tried to get a missing field. name=%s", + $name + )); + } + /** * Setter for database result instance *