ZF-7361: hasMethod() and hasProperty() of Zend_CodeGenerator_Php_Class is not working
Methods and Properties are added via inherited append() of ArrayObject. All accesses to $this->_methods[$methodName] and $this->_properties[$propertyName] are not working because append() does not set any associative key.
My suggestion would be to not use append() or overriding it.
If indexed access is possible then getMethod() and getProperty() can be improved by dropping the loops and accessing the ArrayObject directly.