/**
  * exception thrown when a given property does not exist on an object
  *
  * @param object $obj
  *        the object which does not have the property
  * @param string $propertyName
  *        the name of the property which does not exist
  */
 public function __construct($obj, $propertyName)
 {
     $className = get_class($obj);
     $msg = "no such property '{$propertyName}' on class '{$className}'";
     parent::__construct(400, $msg);
 }
 /**
  * exception thrown when a requested index cannot be found in an array
  *
  * @param string $arrName
  *        the 'name' of the array
  * @param mixed $key
  *        the index that cannot be found in the array
  */
 public function __construct($arrName, $key)
 {
     $msg = "no such index '{$key}' on array '{$arrName}'";
     parent::__construct(400, $msg);
 }