Home>
<?php
/*
 * created on 2016-7-20
 * /
class window //First define a class
{
 var $state;//state of the window
 function close_window () //close window method
 {
 $this->state="close";//The state of the window is closed
 }
 function open_window () //Open window method
 {
 $this->state="open";//The state of the window is open
 }
}
$temp=get_class_methods ("window");
echo "There are several methods in the class window:";
echo "<p>";
for ($i=0;$i<count ($temp);$i ++)
{
 echo $temp [$i]. ",";
}
?>

The results are as follows:

The methods in the class window are as follows:

close_window, open_window,

php