Return the package name.
public getDependencies ( ) : string | ||
리턴 | string | The package name. |
/** * Retrieve the dependencies for the specified package release. * * @param string $package The package name. * @param string $version The package version. * * @return array The package dependencies. */ public function getDependencies($package, $version) { $deps = new Horde_Pear_Rest_Dependencies($this->_rest->fetchPackageDependencies($package, $version)); return $deps->getDependencies(); }
public function testDependencyList() { $deps = new Horde_Pear_Rest_Dependencies('a:1:{s:8:"optional";a:1:{s:7:"package";a:2:{i:0;a:1:{s:4:"name";s:5:"test2";}i:1;a:1:{s:4:"name";s:5:"test1";}}}}'); $this->assertEquals(array(array('name' => 'test2', 'type' => 'pkg', 'optional' => 'yes'), array('name' => 'test1', 'type' => 'pkg', 'optional' => 'yes')), $deps->getDependencies()); }