public ObjectTable(Database.Schema schema, ObjectMetaType metaType)
     : base(schema)
 {
     m_MetaType = metaType;
     m_Meta     = s_Meta[(int)metaType];
 }
        public ObjectListTable(Database.Schema schema, SnapshotDataRenderer renderer, CachedSnapshot snapshot, ManagedData crawledData, ObjectMetaType metaType)
            : base(schema, metaType)
        {
            Renderer    = renderer;
            Snapshot    = snapshot;
            CrawledData = crawledData;

            var col = new List <Database.Column>();

            switch (metaType)
            {
            case ObjectMetaType.All:
            case ObjectMetaType.Managed:
                col.Add(new ObjectListUnifiedIndexColumn(this));
                col.Add(new ObjectListNameColumn(this));
                col.Add(new ObjectListValueColumn(this));
                col.Add(new ObjectListTypeColumn(this));
                col.Add(new ObjectListObjectTypeColumn(this));
                col.Add(new ObjectListNativeObjectNameLinkColumn(this));
                col.Add(new ObjectListLengthColumn(this));
                col.Add(new ObjectListStaticColumn(this));
                col.Add(new ObjectListRefCountColumn(this));
                col.Add(new ObjectListOwnedSizeColumn(this));
                col.Add(new ObjectListTargetSizeColumn(this));
                col.Add(new ObjectListNativeObjectSizeColumn(this));
                col.Add(new ObjectListNativeInstanceIdLinkColumn(this));
                col.Add(new ObjectListAddressColumn(this));
                col.Add(new ObjectListUniqueStringColumn(this));
                break;

            case ObjectMetaType.Native:
                col.Add(new ObjectListUnifiedIndexColumn(this));
                col.Add(new ObjectListNameColumn(this));
                col.Add(new ObjectListValueColumn(this));
                col.Add(new ObjectListTypeColumn(this));
                col.Add(new ObjectListNativeObjectNameColumn(this));
                col.Add(new ObjectListObjectTypeColumn(this));
                col.Add(new ObjectListRefCountColumn(this));
                col.Add(new ObjectListOwnedSizeColumn(this));
                col.Add(new ObjectListTargetSizeColumn(this));
                col.Add(new ObjectListNativeInstanceIdColumn(this));
                col.Add(new ObjectListAddressColumn(this));
                col.Add(new ObjectListUniqueStringColumn(this));
                break;
            }

            InitExpandColumn(col);
        }
Beispiel #3
0
        public ObjectArrayTable(Database.Schema schema, SnapshotObjectDataFormatter formatter, CachedSnapshot snapshot, ManagedData crawledData, ObjectData arrayData, ObjectMetaType metaType)
            : base(schema, formatter, snapshot, crawledData, metaType)
        {
            this.arrayData = arrayData;

            if (arrayData.isManaged)
            {
                arrayInfo = ArrayTools.GetArrayInfo(snapshot, arrayData.managedObjectData, arrayData.managedTypeIndex);
            }

            InitObjectList();
        }
        public ObjectFieldTable(Schema schema, SnapshotDataRenderer renderer, CachedSnapshot snapshot, ManagedData crawledData, ObjectData obj, ObjectMetaType metaType)
            : base(schema, renderer, snapshot, crawledData, metaType)
        {
            this.obj = obj;
            objBase  = obj.GetBase(snapshot);

            SetFieldsList(BuildFieldList());
            InitObjectList();
        }
 public ObjectAllManagedTable(Database.Schema schema, SnapshotObjectDataFormatter formatter, CachedSnapshot snapshot, ManagedData crawledData, ObjectMetaType metaType)
     : base(schema, formatter, snapshot, crawledData, metaType)
 {
     InitObjectList();
 }
 public ObjectAllManagedTable(Database.Schema schema, SnapshotDataRenderer renderer, CachedSnapshot snapshot, ManagedData crawledData, ObjectMetaType metaType)
     : base(schema, renderer, snapshot, crawledData, metaType)
 {
     InitObjectList();
 }
 public ObjectReferenceTable(Database.Schema schema, SnapshotObjectDataFormatter formatter, CachedSnapshot snapshot, ManagedData crawledData, ObjectData obj, ObjectMetaType metaType)
     : base(schema, formatter, snapshot, crawledData, metaType)
 {
     m_Object     = obj;
     m_References = ObjectConnection.GetAllObjectConnectingTo(snapshot, obj);
     InitObjectList();
 }
Beispiel #8
0
 public ObjectSingleTable(Schema schema, SnapshotDataRenderer renderer, CachedSnapshot snapshot, ManagedData crawledData, ObjectData obj, ObjectMetaType metaType)
     : base(schema, renderer, snapshot, crawledData, metaType)
 {
     this.obj = obj;
     if (!obj.dataIncludeObjectHeader)
     {
         var od = ObjectData.FromManagedPointer(snapshot, obj.hostManagedObjectPtr);
         objOffset = obj.managedObjectData.offset - od.managedObjectData.offset;
     }
     else
     {
         objOffset = 0;
     }
     InitObjectList();
     ExpandCell(0, 0, true);
 }
Beispiel #9
0
        public ObjectReferenceTable(Database.Schema schema, SnapshotObjectDataFormatter formatter, CachedSnapshot snapshot, ManagedData crawledData, ObjectData obj, ObjectMetaType metaType)
            : base(schema, formatter, snapshot, crawledData, metaType)
        {
            m_Object     = obj;
            m_References = ObjectConnection.GetAllObjectConnectingTo(snapshot, obj);
#if DEBUG_VALIDATION
            int toUnifiedIndex = m_Object.GetUnifiedObjectIndex(snapshot);
            var toManagedIndex = snapshot.UnifiedObjectIndexToManagedObjectIndex(toUnifiedIndex);

            for (int k = 0; k != m_References.Length; ++k)
            {
                var oFrom = m_References[k];

                switch (oFrom.dataType)
                {
                case ObjectDataType.ReferenceArray:
                case ObjectDataType.ReferenceObject:
                case ObjectDataType.Value:
                    if (oFrom.m_Parent != null)
                    {
                        oFrom = oFrom.m_Parent.obj;
                    }
                    break;
                }

                bool connectionFound = false;
                switch (oFrom.dataType)
                {
                case ObjectDataType.Global:
                {
                    if (snapshot.HasGlobalConnection(toManagedIndex))
                    {
                        connectionFound = true;
                    }
                }
                break;

                case ObjectDataType.Type:
                {
                    if (snapshot.HasManagedTypeConnection(oFrom.managedTypeIndex, toManagedIndex))
                    {
                        connectionFound = true;
                    }
                }
                break;

                case ObjectDataType.Array:
                case ObjectDataType.BoxedValue:
                case ObjectDataType.Object:
                {
                    if (snapshot.HasObjectConnection(oFrom.GetUnifiedObjectIndex(snapshot), toUnifiedIndex))
                    {
                        connectionFound = true;
                        break;
                    }
                }
                break;

                case ObjectDataType.NativeObject:
                {
                    if (snapshot.HasObjectConnection(oFrom.GetUnifiedObjectIndex(snapshot), toUnifiedIndex))
                    {
                        connectionFound = true;
                        break;
                    }
                }
                break;
                }
                if (!connectionFound)
                {
                    UnityEngine.Debug.LogError("Connection not found, index =" + k);
                }
            }
#endif
            InitObjectList();
        }