how would I go about getting around the \"protected\" so I can output the data.
tabs\\api\\property\\Property Object (
[id:protected] => 90_4_HH
[pr
Answer to the question posed by the title is that all classes are public.
What you are asking is how to access protected member variables.
Taken from here (http://ajmm.org/2011/06/using-php-reflection-to-read-a-protected-property/), this is an example of how to do this:
public static function getReflectedPropertyValue($class, $propertyName)
{
$reflectedClass = new ReflectionClass($class);
$property = $reflectedClass->getProperty($propertyName);
$property->setAccessible(true);
return $property->getValue($class);
}
...
getReflectedPropertyValue($yourObject, 'protectedProperty');
That said, the question is why you want to do this. Members are marked protected specifically to prevent you from doing this. If you have access to the source code that defines this other class, then it might make more sense to either change these members to "public" or (better) to provide a getXYZ() method for whichever properties you want to access.