def addDefinition(self, definition): ''' Add a new definition and notify observers about this @param definition: a new function definition @type definition: L{GlobalVarDefinition} ''' RestrictedManager.addDefinition(self, definition) # after i added the definition, i need to fire the event self.fire(self.__class__.EVENT_NEW_DEFINITION, definition)
def addDefinition(self, definition): ''' Add a new definition and notify observers about this @param definition: a new function definition @type definition: L{GlobalVarDefinition} ''' RestrictedManager.addDefinition(self, definition) # after i added the definition, i need to fire the event self.fire(self.__class__.EVENT_NEW_DEFINITION, definition)
def addDefinition(self, definition): ''' Add a new definition and notify observers about this @param definition: a new function definition @type definition: L{FunctionDefinition} ''' # need to check definition: # if definition scope different from this one # i need to mark the function as not forward # and lock redefinition if definition.moduleName != self.scope.moduleName and definition.isForward: definition.isForward = False myclips.logger.debug("DefFunction %s::%s imported. Can't be redefined", definition.moduleName, definition.name) RestrictedManager.addDefinition(self, definition) # after i added the definition, i need to fire the event self.fire(self.__class__.EVENT_NEW_DEFINITION, definition)
def addDefinition(self, definition): ''' Add a new definition and notify observers about this @param definition: a new function definition @type definition: L{FunctionDefinition} ''' # need to check definition: # if definition scope different from this one # i need to mark the function as not forward # and lock redefinition if definition.moduleName != self.scope.moduleName and definition.isForward: definition.isForward = False myclips.logger.debug( "DefFunction %s::%s imported. Can't be redefined", definition.moduleName, definition.name) RestrictedManager.addDefinition(self, definition) # after i added the definition, i need to fire the event self.fire(self.__class__.EVENT_NEW_DEFINITION, definition)