Exemplo n.º 1
0
    {
        echo "in SE: accessing SC\n";
        var_dump(get_class_vars('SC'));
        echo "in SE: accessing SD\n";
        var_dump(get_class_vars('SD'));
        echo "in SE: accessing SE\n";
        var_dump(get_class_vars('SE'));
    }
}
echo ">>> testing instance variables from global scope\n";
echo "accessing C\n";
var_dump(get_class_vars('C'));
echo "accessing D\n";
var_dump(get_class_vars('D'));
echo "accessing E\n";
var_dump(get_class_vars('E'));
echo ">>> testing instance variables from class scope\n";
C::show();
D::show();
E::show();
echo ">>> testing static variables from global scope\n";
echo "accessing SC\n";
var_dump(get_class_vars('SC'));
echo "accessing SD\n";
var_dump(get_class_vars('SD'));
echo "accessing SE\n";
var_dump(get_class_vars('SE'));
echo ">>> testing static variables from class scope\n";
SC::show();
SD::show();
SE::show();