示例#1
0
 public function testGetReturnsDefaultSpecifiedWhenValueAtOffsetIsNull()
 {
     $o = new Mad_Support_ArrayObject(array('foo' => null));
     $this->assertEquals('bar', $o->get('foo', 'bar'));
 }
示例#2
0
 /**
  * Each variable set through routing {@link Mad_Controller_Route_Path} is
  * availabie in controllers using the $params array.
  *
  * The controller also has access to GET/POST arrays using $params
  *
  * The action method to be performed is stored in $this->params[':action'] key
  */
 private function _initParams()
 {
     $hash = $this->_request->getParameters();
     $this->params = new Mad_Support_ArrayObject($hash);
     $this->_action = $this->params->get(':action');
 }