using System; using System.Collections.Generic; namespace UnityEngine { // Token: 0x02000008 RID: 8 internal class IntervalTree { // Token: 0x0600003C RID: 60 RVA: 0x00003EC0 File Offset: 0x000020C0 public List AllocateCache(int maximumNumberOfIntersections) { return new List(maximumNumberOfIntersections); } // Token: 0x17000007 RID: 7 // (get) Token: 0x0600003D RID: 61 RVA: 0x00003EDC File Offset: 0x000020DC // (set) Token: 0x0600003E RID: 62 RVA: 0x00003EF7 File Offset: 0x000020F7 public bool dirty { get { return this.m_Dirty; } set { this.m_Dirty = true; } } // Token: 0x0600003F RID: 63 RVA: 0x00003F01 File Offset: 0x00002101 public void Add(IInterval item) { this.m_Nodes.Add(item); this.m_Dirty = true; } // Token: 0x06000040 RID: 64 RVA: 0x00003F17 File Offset: 0x00002117 public void Add(IEnumerable items) { this.m_Nodes.AddRange(items); this.m_Dirty = true; } // Token: 0x06000041 RID: 65 RVA: 0x00003F2D File Offset: 0x0000212D public void Clear() { this.m_Nodes.Clear(); this.m_Dirty = true; } // Token: 0x06000042 RID: 66 RVA: 0x00003F44 File Offset: 0x00002144 public bool Contains(IInterval interval) { return this.m_Nodes.Contains(interval); } // Token: 0x06000043 RID: 67 RVA: 0x00003F65 File Offset: 0x00002165 public void IntersectsWith(long value, int bitFlag, ref List results) where U : class, IInterval { if (this.m_Dirty) { this.Rebuild(); } this.m_Root.Query(value, bitFlag, ref results); } // Token: 0x06000044 RID: 68 RVA: 0x00003F89 File Offset: 0x00002189 public void IntersectsWith(long value, long end, int bitFlag, ref List results) where U : class, IInterval { if (this.m_Dirty) { this.Rebuild(); } this.m_Root.Query(value, end, bitFlag, ref results); } // Token: 0x06000045 RID: 69 RVA: 0x00003FAF File Offset: 0x000021AF private void Rebuild() { this.m_Root = new IntervalNode(this.m_Nodes); this.m_Dirty = false; } // Token: 0x06000046 RID: 70 RVA: 0x00003FCC File Offset: 0x000021CC public override int GetHashCode() { int num = this.m_Dirty.GetHashCode(); for (int i = 0; i < this.m_Nodes.Count; i++) { num ^= this.m_Nodes[i].intervalStart.GetHashCode() ^ this.m_Nodes[i].intervalEnd.GetHashCode(); } return num; } // Token: 0x04000011 RID: 17 private List m_Nodes = new List(); // Token: 0x04000012 RID: 18 private bool m_Dirty = true; // Token: 0x04000013 RID: 19 private IntervalNode m_Root; } }