def __getattr__ ( self , name ) : try : return self . __dict__ [ name ] except KeyError : if hasattr ( self . _properties , name ) : return getattr ( self . _properties , name )
python resolve dynamic attribute at runtime
For attributes not found in self redirect to the properties dictionary
def __getattr__(self, name):
        """ For attributes not found in self, redirect
        to the properties dictionary """

        try:
            return self.__dict__[name]
        except KeyError:
            if hasattr(self._properties,name):
                return getattr(self._properties, name)