* Property. variables, getters, setters, etc.
* Searches specified namespaces
*/
public Property getProperty(String[] namespaces, String name)
{
AbcClass cls = classInfo, superClass = null;
// walk the superclass chain for the specified property...
while (cls != null)
{
Variable var = cls.getVariable(namespaces, name, false);
if (var != null)
{
if (!var.isStatic())
{
// found the property as a variable...
return new PropertyHelper(var);
}
else
{
superClass = symbolTable.getClass(cls.getSuperTypeName());
}
}
else
{
Method setter = cls.getSetter(namespaces, name, false);
Method getter = cls.getGetter(namespaces, name, false);
if (setter != null && getter != null)
{
// found the property as a pair of getter and setter...
return new PropertyHelper(setter, getter);
}
superClass = symbolTable.getClass(cls.getSuperTypeName());
if (setter != null && superClass != null)
{
// search for a superclass getter before creating PropertyHelper.
getter = findGetter(superClass, name);