/** * Returns a list of registered methods * * Returns an array of dispatchables (Zend_Server_Reflection_Function, * _Method, and _Class items). * * @return array */ public function getFunctions() { return $this->_table->toArray(); }
public function testPassingOptionsToConstructorShouldSetObjectState() { $method = array('name' => 'foo.bar', 'callback' => array('type' => 'function', 'function' => 'bar'), 'prototypes' => array(array('returnType' => 'string', 'parameters' => array('string'))), 'methodHelp' => 'Foo Bar!', 'invokeArguments' => array('foo')); $options = array($method); $definition = new Zend_Server_Definition($options); $test = $definition->toArray(); $this->assertEquals(1, count($test)); $test = array_shift($test); $this->assertEquals($method['name'], $test['name']); $this->assertEquals($method['methodHelp'], $test['methodHelp']); $this->assertEquals($method['invokeArguments'], $test['invokeArguments']); $this->assertEquals($method['prototypes'][0]['returnType'], $test['prototypes'][0]['returnType']); }