Browse Source

fixed getDoIds (pass in getDo)

Darren Ranalli 19 years ago
parent
commit
be255e6bbd

+ 2 - 1
direct/src/distributed/DoCollectionManager.py

@@ -97,7 +97,8 @@ class DoCollectionManager:
             for i in self.getDoIdList(parentId, zoneId, classType)]
             for i in self.getDoIdList(parentId, zoneId, classType)]
 
 
     def getDoIdList(self, parentId, zoneId=None, classType=None):
     def getDoIdList(self, parentId, zoneId=None, classType=None):
-        return self._doHierarchy.getDoIds(parentId, zoneId, classType)
+        return self._doHierarchy.getDoIds(self.getDo,
+                                          parentId, zoneId, classType)
 
 
     def getOwnerViewDoList(self, classType):
     def getOwnerViewDoList(self, classType):
         assert self.hasOwnerView()
         assert self.hasOwnerView()

+ 2 - 2
direct/src/distributed/DoHierarchy.py

@@ -24,7 +24,7 @@ class DoHierarchy:
         self._table = {}
         self._table = {}
         self._allDoIds = set()
         self._allDoIds = set()
 
 
-    def getDoIds(self, parentId, zoneId=None, classType=None):
+    def getDoIds(self, getDo, parentId, zoneId=None, classType=None):
         """
         """
         Moved from DoCollectionManager
         Moved from DoCollectionManager
         ==============================
         ==============================
@@ -52,7 +52,7 @@ class DoHierarchy:
         if classType is not None:
         if classType is not None:
             a = []
             a = []
             for doId in r:
             for doId in r:
-                obj = self.getDo(doId)
+                obj = getDo(doId)
                 if isinstance(obj, classType):
                 if isinstance(obj, classType):
                     a.append(doId)
                     a.append(doId)
             r = a
             r = a