Example #1
0
 /**
  * Tests if a data is visible from current scope.
  *
  * @param string $key
  *
  * @return bool
  */
 public function has($key)
 {
     if (array_key_exists($key, $this->data)) {
         return true;
     }
     if (null === $this->parent) {
         return false;
     }
     return $this->parent->has($key);
 }