php - How to find out if class properties are private or public? -
this question has answer here:
- php's function list objects's attributes 4 answers
after creating class private, protected, , public variables, how can find out private, protected, , public (from outside class)?
by way want know because want extract public model attributes set in /phalcon/mvc/model.
to clarify: not looking list of attributes, scope of every attribute.
get_class_vars()
fit needs
it returns array of properties visible in current scope. in case should return public
properties.
Comments
Post a Comment