本文整理汇总了PHP中check::classmethods方法的典型用法代码示例。如果您正苦于以下问题:PHP check::classmethods方法的具体用法?PHP check::classmethods怎么用?PHP check::classmethods使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类check
的用法示例。
在下文中一共展示了check::classmethods方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: array
<?php
require "tests.php";
require "rename_scope.php";
check::classes(array("rename_scope", "Interface_UP", "Interface_BP", "Natural_UP", "Natural_BP", "Bucket"));
check::classmethods("Interface_UP", array("__construct", "__set", "__isset", "__get"));
check::classmethods("Interface_BP", array("__construct", "__set", "__isset", "__get"));
check::classmethods("Natural_UP", array("__construct", "__set", "__isset", "__get", "rtest"));
check::classmethods("Natural_BP", array("__construct", "__set", "__isset", "__get", "rtest"));
check::classparent("Natural_UP", "Interface_UP");
check::classparent("Natural_BP", "Interface_BP");
check::done();
示例2: array
<?php
require "tests.php";
require "smart_pointer_rename.php";
check::classes(array("Foo", "Bar"));
check::classmethods("foo", array("ftest1", "ftest2", "__set", "__isset", "__get", "__construct"));
check::classmethods("bar", array("__deref__", "test", "ftest1", "ftest2", "__set", "__isset", "__get", "__construct"));
$foo = new foo();
check::classname("foo", $foo);
$bar = new bar($foo);
check::classname("bar", $bar);
# check foo's ftest1, ftest2
check::equal(1, $foo->ftest1(1), "foo->ftest1");
check::equal(2, $foo->ftest2(1, 2), "foo->ftest2");
# check bar's ftest1, ftest2, ftest
check::equal(1, $bar->ftest1(1), "bar->ftest1");
check::equal(2, $bar->ftest2(1, 2), "bar->ftest2");
check::equal(3, $bar->test(), "bar->test");
# check deref returns foo
check::classname("foo", $bar->__deref__());
check::done();