当前位置: 首页>>代码示例>>PHP>>正文


PHP ReflectionExtension::getDependencies方法代码示例

本文整理汇总了PHP中ReflectionExtension::getDependencies方法的典型用法代码示例。如果您正苦于以下问题:PHP ReflectionExtension::getDependencies方法的具体用法?PHP ReflectionExtension::getDependencies怎么用?PHP ReflectionExtension::getDependencies使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ReflectionExtension的用法示例。


在下文中一共展示了ReflectionExtension::getDependencies方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: getDependencies

 /**
  * Returns an array containing all names of all extensions this extension
  * depends on
  * @return string[]
  */
 public function getDependencies()
 {
     if ($this->reflectionSource) {
         return $this->reflectionSource->getDependencies();
     } else {
         return parent::getDependencies();
     }
 }
开发者ID:naderman,项目名称:pflow,代码行数:13,代码来源:extension.php

示例2: _getExtension

 /**
  * Get all info about function
  * @param string|function $extensionName Function or function name
  * @return array|bool
  */
 protected static function _getExtension($extensionName)
 {
     if (!extension_loaded($extensionName)) {
         return false;
     }
     $ext = new ReflectionExtension($extensionName);
     $result = array();
     $result['name'] = $ext->name;
     $result['version'] = $ext->getVersion();
     if ($constants = $ext->getConstants()) {
         $result['constants'] = $constants;
     }
     if ($classesName = $ext->getClassNames()) {
         $result['classesName'] = $classesName;
     }
     if ($functions = $ext->getFunctions()) {
         $result['functions'] = $functions;
     }
     if ($dependencies = $ext->getDependencies()) {
         $result['dependencies'] = $dependencies;
     }
     if ($INIEntries = $ext->getINIEntries()) {
         $result['INIEntries'] = $INIEntries;
     }
     $functions = $ext->getFunctions();
     if (is_array($functions) && count($functions) > 0) {
         $result['functions'] = array();
         foreach ($functions as $function) {
             $funcName = $function->getName();
             $result['functions'][$funcName] = self::_getFunction($funcName);
         }
     }
     return $result;
 }
开发者ID:CB9TOIIIA,项目名称:JBDump,代码行数:39,代码来源:class.jbdump.php

示例3: ReflectionExtension

<?php

$standard = new ReflectionExtension('standard');
var_dump($standard->getDependencies());
?>
==DONE==
开发者ID:badlamer,项目名称:hhvm,代码行数:6,代码来源:ReflectionExtension_getDependencies_variation2.php

示例4: testGetDependencies

 public function testGetDependencies()
 {
     self::assertEquals($this->phpExtRef->getDependencies(), $this->extRef->getDependencies());
     self::assertEquals($this->phpExtSpl->getDependencies(), $this->extSpl->getDependencies());
 }
开发者ID:naderman,项目名称:ezc-reflection,代码行数:5,代码来源:extension_test.php

示例5: dirname

<?php

/**
 * php-mecab/examples
 * show module dependencies, ini entries, constants, functions
 * and methods provided by mecab extension (use ReflectionExtension)
 * charset=utf-8
 */
require_once dirname(__FILE__) . '/common.inc.php';
$linebreak = PHP_EOL . PHP_EOL;
$reflector = new ReflectionExtension('mecab');
$mapper = create_function('$m', 'return $m->getName();');
border();
echo 'Module dependencies:', $linebreak;
print_r($reflector->getDependencies());
border();
echo 'INI entries:', $linebreak;
print_r($reflector->getINIEntries());
border();
echo 'Constants:', $linebreak;
print_r($reflector->getConstants());
border();
echo 'Functions:', $linebreak;
print_r(array_keys($reflector->getFunctions()));
border();
echo 'Classes:', $linebreak;
$classes = array();
foreach ($reflector->getClasses() as $className => $class) {
    $classes[$className] = array('interfaces' => null, 'constants' => $class->getConstants(), 'properties' => $class->getProperties(), 'methods' => array_map($mapper, $class->getMethods()));
    if (method_exists($class, 'getInterfaceNames')) {
        $classes[$className]['interfaces'] = $class->getInterfaceNames();
开发者ID:knmasuda,项目名称:php-mecab,代码行数:31,代码来源:provides-r.php

示例6: ReflectionExtension

<?php

$ext = new ReflectionExtension("xml");
$deps = $ext->getDependencies();
var_dump($deps);
开发者ID:badlamer,项目名称:hhvm,代码行数:5,代码来源:016.php

示例7: ReflectionExtension

<?php

$dom = new ReflectionExtension('dom');
var_dump($dom->getDependencies());
?>
==DONE==
开发者ID:badlamer,项目名称:hhvm,代码行数:6,代码来源:ReflectionExtension_getDependencies_basic.php


注:本文中的ReflectionExtension::getDependencies方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。