W3Cschool
恭喜您成為首批注冊用戶
獲得88經(jīng)驗值獎勵
(PECL runkit7 >= Unknown)
runkit7_method_remove — 動態(tài)刪除給定的方法
runkit7_method_remove(string $class_name, string $method_name): bool
注意: 此函數(shù)不能用來操作當前正常運行(或運行鏈上)的方法。
class_name
要刪除方法的類。
method_name
要刪除的方法的名稱。
成功時返回 true, 或者在失敗時返回 false。/
示例 #1 runkit7_method_remove() example
<?php
class Example {
function foo() {
return "foo!\n";
}
function bar() {
return "bar!\n";
}
}
// Remove the 'foo' method
runkit7_method_remove(
'Example',
'foo'
);
echo implode(' ', get_class_methods('Example'));
?>
以上示例會輸出:
bar
Copyright©2021 w3cschool編程獅|閩ICP備15016281號-3|閩公網(wǎng)安備35020302033924號
違法和不良信息舉報電話:173-0602-2364|舉報郵箱:jubao@eeedong.com
掃描二維碼
下載編程獅App
編程獅公眾號
聯(lián)系方式:
更多建議: