def _init_dynamic_property(self, new_attr_name, method, index=None):
        """Create new object's property at runtime. If index argument is
        supplied it is assumed that method returns tuple() and only element
        on ${index} position is returned.
        """
        if (new_attr_name in dir(self) or
                new_attr_name is not self._dynamic_properties):
            raise AttributeError("%s class has already attribute %s."
                                 "The new property could not be "
                                 "created." % (self.__class__.__name__,
                                               new_attr_name))
        new_method = self.__class__._DynamicProperty(method, index)
        inst_method = types.MethodType(new_method, self)
        self._dynamic_properties[new_attr_name] = inst_method
dataset/ETHPy150Open CiscoSystems/avos/openstack_dashboard/test/integration_tests/regions/baseregion.py/BaseRegion._init_dynamic_property/operator `in` -> `is not`