Exemplo n.º 1
0
        ProcessObject(AcDb.Transaction trHelp, AcDb.ObjectId lookForObjId, AcDb.ObjectId curObjId)
        {
            AcDb.DBObject tmpObj = trHelp.GetObject(curObjId, AcDb.OpenMode.ForRead);
            if (tmpObj != null)
            {
                m_count++;
                ReferenceFiler filer = new ReferenceFiler();
                tmpObj.DwgOut(filer);                          // find out who this object owns

                RecordReferences(lookForObjId, tmpObj, filer); // record references for this object

                // now recursively visit all the objects this one owns
                for (int i = 0; i < filer.m_hardOwnershipIds.Count; i++)
                {
                    ProcessObject(trHelp, lookForObjId, filer.m_hardOwnershipIds[i]);
                }

                for (int i = 0; i < filer.m_softOwnershipIds.Count; i++)
                {
                    ProcessObject(trHelp, lookForObjId, filer.m_softOwnershipIds[i]);
                }
            }
            else
            {
                m_skipped++;
            }
        }
Exemplo n.º 2
0
 RecordReferences(AcDb.ObjectId lookForObjId, AcDb.DBObject objToCheck, ReferenceFiler filer)
 {
     // now see if we showed up in any of the lists
     if (filer.m_hardPointerIds.Contains(lookForObjId))
     {
         m_hardPointerIds.Add(objToCheck.ObjectId);
     }
 }