![]() |
Class-Object visibility through Properties-Methods Access Modifiers
::Class-Object visibility through Properties-Methods Access Modifiers
In PHP, is it correct to say that we control Class-Object visibility by setting the correct Access Modifier to its properties and methods? eg. In PHP, classes are public, we can't declare a private nor protect class (we can use final and abstract, for other purposes) Thanx in advance :-) |
I don't really understand what you are saying ... but
A class has optional definitions that are final or abstract that specify specific functionality Read more about this at http://us3.php.net/manual/en/language.oop5.basic.php Properties and methods defined in a class wither it is public, private or protected have no influence on visibility of the class itself you can read more about this at http://us3.php.net/manual/en/languag...visibility.php |
Yes this is correct, we can not scope an object in PHP as we don't have Namespaces till PHP6. ( Correct me if I'm wrong )
|
Quote:
I'm new to PHP, but not to OO so I'm checking to see if my post regarding Encapsulation and Data Hiding in PHP was right ... I think so ... according to 'Enfernikus' last post |
Quote:
|
Really!? I'm going to go have some fun now...
|
Quote:
use TalkPHP\Members\Efernikus as Slave; 8-) |
Quote:
( Movie - Russel Crowe ) |
| All times are GMT. The time now is 07:48 PM. |
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0