/// <summary> /// Compares Evnt Objects /// </summary> /// <param name="obj"></param> /// <returns></returns> public int CompareTo(object obj) { if (!(obj is Evnt)) { throw new NotImplementedException( ); } Evnt e = (Evnt)obj; return(DateTime.Compare(this.eventTime, e.eventTime)); }
/// <summary> /// Inserts the specified value. /// </summary> /// <param name="value">The value.</param> /// <exception cref="System.Exception">Heap's underlying storage is overflow</exception> public void Insert(Evnt value) { if (HeapSize == regEvnts.Length) { throw new Exception("Heap's underlying storage is overflow"); } else { HeapSize++; regEvnts[HeapSize - 1] = value; siftUp(HeapSize - 1); } }
}//end Event(Registrant) /// <summary> /// Copy Constructor /// </summary> /// <param name="e"></param> public Evnt(Evnt e) { this.ID = e.ID; this.eventTime = e.eventTime; this.type = e.type; }//end Evnt(Evnt)