code: def delete_object(self, obj):
          
          if _debug: Application._debug("delete_object %r", obj)
  
          # extract the object name and identifier
          object_name = obj.objectName
          object_identifier = obj.objectIdentifier
  
          # delete it from the application
          del self.objectName[object_name]
          del self.objectIdentifier[object_identifier]
  
          # remove the object's identifier from the device's object list
          # if there is one and it has an object list property
          if self.localDevice and self.localDevice.objectList:
              indx = self.localDevice.objectList.index(object_identifier)
              del self.localDevice.objectList[indx]
  
          # make sure the object knows it's detached from an application
          obj._app = None
docs: Add an object to the local collection.