// @(#)root/cont:$Id$
// Author: Fons Rademakers   13/09/95

/*************************************************************************
 * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers.               *
 * All rights reserved.                                                  *
 *                                                                       *
 * For the licensing terms see $ROOTSYS/LICENSE.                         *
 * For the list of contributors see $ROOTSYS/README/CREDITS.             *
 *************************************************************************/

//////////////////////////////////////////////////////////////////////////
//                                                                      //
// TOrdCollection                                                       //
//                                                                      //
// Ordered collection. An ordered collection has TList insertion        //
// semantics but is implemented using an array of TObject*'s. It uses   //
// less space than a TList (since there is no need for the prev and     //
// next pointers), but it is more costly to insert objects (since it    //
// has to create a gap by copying object pointers). TOrdCollection      //
// is better than TList when objects are only added at the end of the   //
// collection since no copying needs to be done.                        //
//Begin_Html
/*
<img src=gif/tordcollection.gif>
*/
//End_Html
//                                                                      //
//////////////////////////////////////////////////////////////////////////

#include "TOrdCollection.h"
#include "TError.h"


ClassImp(TOrdCollection)

//______________________________________________________________________________
TOrdCollection::TOrdCollection(Int_t capacity)
{
   // Create an ordered collection.

   if (capacity < 0) {
      Warning("TOrdCollection", "capacity (%d) < 0", capacity);
      capacity = kDefaultCapacity;
   } else if (capacity == 0)
      capacity = kDefaultCapacity;
   Init(capacity);
}

//______________________________________________________________________________
TOrdCollection::~TOrdCollection()
{
   // Delete the collection. Objects are not deleted unless the TOrdCollection
   // is the owner (set via SetOwner()).

   if (IsOwner())
      Delete();

   TStorage::Dealloc(fCont);
   fCont = 0;
   fSize = 0;
}

//______________________________________________________________________________
void TOrdCollection::AddAt(TObject *obj, Int_t idx)
{
   // Insert object at position idx in the collection.

   Int_t physIdx;

   if (idx > fSize) idx = fSize;

   if (fGapSize <= 0)
      SetCapacity(GrowBy(TMath::Max(fCapacity, (int)kMinExpand)));

   if (idx == fGapStart) {
      physIdx = fGapStart;
      fGapStart++;
   } else {
      physIdx = PhysIndex(idx);
      if (physIdx < fGapStart) {
         MoveGapTo(physIdx);
         physIdx = fGapStart;
         fGapStart++;
      } else {
         MoveGapTo(physIdx - fGapSize);
         physIdx = fGapStart + fGapSize - 1;
      }
   }
   R__ASSERT(physIdx >= 0 && physIdx < fCapacity);
   fCont[physIdx] = obj;
   fGapSize--;
   fSize++;
   Changed();
}

//______________________________________________________________________________
void TOrdCollection::AddFirst(TObject *obj)
{
   // Insert object at beginning of collection.

   AddAt(obj, 0);
}

//______________________________________________________________________________
void TOrdCollection::AddLast(TObject *obj)
{
   // Add object at the end of the collection.

   AddAt(obj, fSize);
}

//______________________________________________________________________________
void TOrdCollection::AddBefore(const TObject *before, TObject *obj)
{
   // Insert object before object before in the collection.

   if (!before)
      AddFirst(obj);
   else {
      Int_t idx = IndexOf(before);
      if (idx == -1) {
         Error("AddBefore", "before not found, object not added");
         return;
      }
      if (idx == 0) {
         AddFirst(obj);
         return;
      }
      AddAt(obj, idx);
   }
}

//______________________________________________________________________________
void TOrdCollection::AddAfter(const TObject *after, TObject *obj)
{
   // Insert object after object after in the collection.

   if (!after)
      AddLast(obj);
   else {
      Int_t idx = IndexOf(after);
      if (idx == -1) {
         Error("AddAfter", "after not found, object not added");
         return;
      }
      AddAt(obj, idx+1);
   }
}

//______________________________________________________________________________
TObject *TOrdCollection::After(const TObject *obj) const
{
   // Return the object after object obj. Returns 0 if obj is last
   // in collection.

   if (!obj) return 0;

   Int_t idx = IndexOf(obj);
   if (idx == -1 || idx == fSize-1) return 0;

   return At(idx+1);
}

//______________________________________________________________________________
TObject *TOrdCollection::At(Int_t idx) const
{
   // Returns the object at position idx. Returns 0 if idx is out of range.

   if (IllegalIndex("At", idx)) return 0;
   return fCont[PhysIndex(idx)];
}

//______________________________________________________________________________
TObject *TOrdCollection::Before(const TObject *obj) const
{
   // Returns the object before object obj. Returns 0 if obj is first
   // in collection.

   if (!obj) return 0;

   Int_t idx = IndexOf(obj);
   if (idx == -1 || idx == 0) return 0;

   return At(idx-1);
}

//______________________________________________________________________________
void TOrdCollection::Clear(Option_t *)
{
   // Remove all objects from the collection. Does not delete the objects
   // unless the TOrdCollection is the owner (set via SetOwner()).

   if (IsOwner())
      Delete();
   else {
      TStorage::Dealloc(fCont);
      fCont = 0;
      Init(fCapacity);
      fSize = 0;
   }
}

//______________________________________________________________________________
void TOrdCollection::Delete(Option_t *)
{
   // Remove all objects from the collection AND delete all heap based objects.

   for (Int_t i = 0; i < fSize; i++) {
      TObject *obj = At(i);
      if (obj && obj->IsOnHeap())
         TCollection::GarbageCollect(obj);
   }
   TStorage::Dealloc(fCont);
   fCont = 0;
   Init(fCapacity);
   fSize = 0;
}

//______________________________________________________________________________
TObject *TOrdCollection::First() const
{
   // Return the first object in the collection. Returns 0 when collection
   // is empty.

   return At(0);
}

//______________________________________________________________________________
TObject **TOrdCollection::GetObjectRef(const TObject *obj) const
{
   // return address of pointer obj
   Int_t index = IndexOf(obj);
   return &fCont[index];
}

//______________________________________________________________________________
TObject *TOrdCollection::Last() const
{
   // Return the last object in the collection. Returns 0 when collection
   // is empty.

   return At(fSize-1);
}

//______________________________________________________________________________
Bool_t TOrdCollection::IllegalIndex(const char *method, Int_t idx) const
{
   // Return true when index out of bounds and print error.

   if (idx < 0 || idx >= fSize) {
      Error(method, "index error (= %d) < 0 or > Size() (= %d)", idx, fSize);
      return kTRUE;
   }
   return kFALSE;
}

//______________________________________________________________________________
Int_t TOrdCollection::IndexOf(const TObject *obj) const
{
   // Return index of object in collection. Returns -1 when object not found.
   // Uses member IsEqual() to find object.

   for (Int_t i = 0; i < GetSize(); i++)
      if (fCont[PhysIndex(i)]->IsEqual(obj))
         return i;

   return -1;
}

//______________________________________________________________________________
void TOrdCollection::Init(Int_t capacity)
{
   // Initialize ordered collection.

   fCapacity = capacity;
   fCont = (TObject**) TStorage::Alloc(fCapacity*sizeof(TObject*)); //new TObject* [fCapacity];
   memset(fCont, 0, fCapacity*sizeof(TObject*));
   fGapStart = 0;
   fGapSize  = capacity;
   Changed();
}

//______________________________________________________________________________
TIterator *TOrdCollection::MakeIterator(Bool_t dir) const
{
   // Return an ordered collection iterator.

   return new TOrdCollectionIter(this, dir);
}

//______________________________________________________________________________
void TOrdCollection::MoveGapTo(Int_t start)
{
   // Move gap to new position. Gap needs to be moved when objects are
   // inserted not at the end.

   Int_t i;

   R__ASSERT(start + fGapSize - 1 < fCapacity);

   if (fGapSize <= 0) {
      fGapStart = start;
      return;
   }
   if (start < fGapStart) {
      for (i = fGapStart - 1; i >= start; i--)
         fCont[i + fGapSize] = fCont[i];
   } else if (start > fGapStart) {
      Int_t stop = start + fGapSize;
      for (i = fGapStart + fGapSize; i < stop; i++)
         fCont[i - fGapSize] = fCont[i];
   }
   fGapStart = start;
   for (i = fGapStart; i < fGapStart + fGapSize; i++)
      fCont[i] = 0;
}

//______________________________________________________________________________
void TOrdCollection::PutAt(TObject *obj, Int_t idx)
{
   // Put object at index idx. Overwrites what was at idx before.

   if (IllegalIndex("PutAt", idx)) return;

   Int_t phx = PhysIndex(idx);
   R__ASSERT(phx >= 0 && phx < fCapacity);
   fCont[phx] = obj;
   Changed();
}

//______________________________________________________________________________
TObject *TOrdCollection::RemoveAt(Int_t idx)
{
   // Remove object at index idx.

   Int_t physIdx;

   if (idx == fGapStart - 1 || idx == fGapStart) {
      if (idx == fGapStart)
         physIdx = fGapStart + fGapSize;        // at right boundary
      else
         physIdx = --fGapStart;                 // at left boundary
   } else {
      physIdx = PhysIndex(idx);
      if (physIdx < fGapStart) {
         MoveGapTo(physIdx + 1);
         physIdx = --fGapStart;
      } else {
         MoveGapTo(physIdx - fGapSize);
         physIdx = fGapStart + fGapSize;
      }
   }
   R__ASSERT(physIdx >= 0 && physIdx < fCapacity);
   TObject *obj = fCont[physIdx];
   fCont[physIdx] = 0;
   fGapSize++;
   fSize--;
   Changed();

   if (LowWaterMark()) {
      Int_t newCapacity = TMath::Max(int(fCapacity / kShrinkFactor), 1);
      if (fCapacity > newCapacity)
         SetCapacity(newCapacity);
   }
   return obj;
}

//______________________________________________________________________________
TObject *TOrdCollection::Remove(TObject *obj)
{
   // Remove object from collection.

   if (!obj) return 0;

   Int_t idx = IndexOf(obj);
   if (idx == -1) return 0;

   return RemoveAt(idx);
}

//______________________________________________________________________________
void TOrdCollection::SetCapacity(Int_t newCapacity)
{
   // Set/change ordered collection capacity.

   R__ASSERT(newCapacity > 0);
   R__ASSERT(fSize <= newCapacity);

   if (fCapacity == newCapacity) return;

   Int_t newGapSize = newCapacity - fSize;
   MoveGapTo(fCapacity - fGapSize);
   fCont = (TObject**) TStorage::ReAlloc(fCont, newCapacity*sizeof(TObject*),
                                         fCapacity*sizeof(TObject*));
   fGapSize  = newGapSize;
   fCapacity = newCapacity;
}

//______________________________________________________________________________
void TOrdCollection::Sort()
{
   // If objects in collection are sortable (i.e. IsSortable() returns true
   // for all objects) then sort collection.

   if (fSize <= 0 || fSorted) return;
   if (!At(0)->IsSortable()) {
      Error("Sort", "objects in collection are not sortable");
      return;
   }

   MoveGapTo(fCapacity - fGapSize);
   QSort(fCont, 0, fSize);

   fSorted = kTRUE;
}

//______________________________________________________________________________
Int_t TOrdCollection::BinarySearch(TObject *obj)
{
   // Find object using a binary search. Collection must first have been
   // sorted.

   Int_t result;

   if (!obj) return -1;

   if (!fSorted) {
      Error("BinarySearch", "collection must first be sorted");
      return -1;
   }

   MoveGapTo(fCapacity - fGapSize);

   Int_t base = 0;
   Int_t last = base + GetSize() - 1;
   while (last >= base) {
      Int_t position = (base + last) / 2;
      TObject *obj2 = fCont[position];
      if ((obj2 == 0) || (result = obj->Compare(obj2)) == 0)
         return LogIndex(position);
      if (result < 0)
         last = position - 1;
      else
         base = position + 1;
   }
   return -1;
}


//////////////////////////////////////////////////////////////////////////
//                                                                      //
// TOrdCollectionIter                                                   //
//                                                                      //
// Iterator of ordered collection.                                      //
//                                                                      //
//////////////////////////////////////////////////////////////////////////

ClassImp(TOrdCollectionIter)

//______________________________________________________________________________
TOrdCollectionIter::TOrdCollectionIter(const TOrdCollection *col, Bool_t dir): fCol(col), fDirection(dir)
{
   // Create collection iterator. By default the iteration direction
   // is kIterForward. To go backward use kIterBackward.

   Reset();
}

//______________________________________________________________________________
TOrdCollectionIter::TOrdCollectionIter(const TOrdCollectionIter &iter) : TIterator(iter)
{
   // Copy ctor.

   fCol       = iter.fCol;
   fDirection = iter.fDirection;
   fCursor    = iter.fCursor;
   fCurCursor = iter.fCurCursor;
}

//______________________________________________________________________________
TIterator &TOrdCollectionIter::operator=(const TIterator &rhs)
{
   // Overridden assignment operator.

   if (this != &rhs && rhs.IsA() == TOrdCollectionIter::Class()) {
      const TOrdCollectionIter &rhs1 = (const TOrdCollectionIter &)rhs;
      fCol       = rhs1.fCol;
      fDirection = rhs1.fDirection;
      fCursor    = rhs1.fCursor;
      fCurCursor = rhs1.fCurCursor;
   }
   return *this;
}

//______________________________________________________________________________
TOrdCollectionIter &TOrdCollectionIter::operator=(const TOrdCollectionIter &rhs)
{
   // Overloaded assignment operator.

   if (this != &rhs) {
      fCol       = rhs.fCol;
      fDirection = rhs.fDirection;
      fCursor    = rhs.fCursor;
      fCurCursor = rhs.fCurCursor;
   }
   return *this;
}

//______________________________________________________________________________
TObject *TOrdCollectionIter::Next()
{
   // Return next object in collection. Returns 0 when no more objects in
   // collection.

   fCurCursor = fCursor;
   if (fDirection == kIterForward) {
      if (fCursor < fCol->GetSize())
         return fCol->At(fCursor++);
   } else {
      if (fCursor >= 0)
         return fCol->At(fCursor--);
   }
   return 0;
}

//______________________________________________________________________________
void TOrdCollectionIter::Reset()
{
   // Reset collection iterator.

   if (fDirection == kIterForward)
      fCursor = 0;
   else
      fCursor = fCol->GetSize() - 1;

   fCurCursor = fCursor;
}

//______________________________________________________________________________
Bool_t TOrdCollectionIter::operator!=(const TIterator &aIter) const
{
   // This operator compares two TIterator objects.

   if (aIter.IsA() == TOrdCollectionIter::Class()) {
      const TOrdCollectionIter &iter(dynamic_cast<const TOrdCollectionIter &>(aIter));
      return (fCurCursor != iter.fCurCursor);
   }
   return false; // for base class we don't implement a comparison
}

//______________________________________________________________________________
Bool_t TOrdCollectionIter::operator!=(const TOrdCollectionIter &aIter) const
{
   // This operator compares two TOrdCollectionIter objects.

   return (fCurCursor != aIter.fCurCursor);
}

//______________________________________________________________________________
TObject *TOrdCollectionIter::operator*() const
{
   // Return current object or nullptr.

   return (((fCurCursor >= 0) && (fCurCursor < fCol->GetSize())) ?
           fCol->At(fCurCursor) : nullptr);
}
 TOrdCollection.cxx:1
 TOrdCollection.cxx:2
 TOrdCollection.cxx:3
 TOrdCollection.cxx:4
 TOrdCollection.cxx:5
 TOrdCollection.cxx:6
 TOrdCollection.cxx:7
 TOrdCollection.cxx:8
 TOrdCollection.cxx:9
 TOrdCollection.cxx:10
 TOrdCollection.cxx:11
 TOrdCollection.cxx:12
 TOrdCollection.cxx:13
 TOrdCollection.cxx:14
 TOrdCollection.cxx:15
 TOrdCollection.cxx:16
 TOrdCollection.cxx:17
 TOrdCollection.cxx:18
 TOrdCollection.cxx:19
 TOrdCollection.cxx:20
 TOrdCollection.cxx:21
 TOrdCollection.cxx:22
 TOrdCollection.cxx:23
 TOrdCollection.cxx:24
 TOrdCollection.cxx:25
 TOrdCollection.cxx:26
 TOrdCollection.cxx:27
 TOrdCollection.cxx:28
 TOrdCollection.cxx:29
 TOrdCollection.cxx:30
 TOrdCollection.cxx:31
 TOrdCollection.cxx:32
 TOrdCollection.cxx:33
 TOrdCollection.cxx:34
 TOrdCollection.cxx:35
 TOrdCollection.cxx:36
 TOrdCollection.cxx:37
 TOrdCollection.cxx:38
 TOrdCollection.cxx:39
 TOrdCollection.cxx:40
 TOrdCollection.cxx:41
 TOrdCollection.cxx:42
 TOrdCollection.cxx:43
 TOrdCollection.cxx:44
 TOrdCollection.cxx:45
 TOrdCollection.cxx:46
 TOrdCollection.cxx:47
 TOrdCollection.cxx:48
 TOrdCollection.cxx:49
 TOrdCollection.cxx:50
 TOrdCollection.cxx:51
 TOrdCollection.cxx:52
 TOrdCollection.cxx:53
 TOrdCollection.cxx:54
 TOrdCollection.cxx:55
 TOrdCollection.cxx:56
 TOrdCollection.cxx:57
 TOrdCollection.cxx:58
 TOrdCollection.cxx:59
 TOrdCollection.cxx:60
 TOrdCollection.cxx:61
 TOrdCollection.cxx:62
 TOrdCollection.cxx:63
 TOrdCollection.cxx:64
 TOrdCollection.cxx:65
 TOrdCollection.cxx:66
 TOrdCollection.cxx:67
 TOrdCollection.cxx:68
 TOrdCollection.cxx:69
 TOrdCollection.cxx:70
 TOrdCollection.cxx:71
 TOrdCollection.cxx:72
 TOrdCollection.cxx:73
 TOrdCollection.cxx:74
 TOrdCollection.cxx:75
 TOrdCollection.cxx:76
 TOrdCollection.cxx:77
 TOrdCollection.cxx:78
 TOrdCollection.cxx:79
 TOrdCollection.cxx:80
 TOrdCollection.cxx:81
 TOrdCollection.cxx:82
 TOrdCollection.cxx:83
 TOrdCollection.cxx:84
 TOrdCollection.cxx:85
 TOrdCollection.cxx:86
 TOrdCollection.cxx:87
 TOrdCollection.cxx:88
 TOrdCollection.cxx:89
 TOrdCollection.cxx:90
 TOrdCollection.cxx:91
 TOrdCollection.cxx:92
 TOrdCollection.cxx:93
 TOrdCollection.cxx:94
 TOrdCollection.cxx:95
 TOrdCollection.cxx:96
 TOrdCollection.cxx:97
 TOrdCollection.cxx:98
 TOrdCollection.cxx:99
 TOrdCollection.cxx:100
 TOrdCollection.cxx:101
 TOrdCollection.cxx:102
 TOrdCollection.cxx:103
 TOrdCollection.cxx:104
 TOrdCollection.cxx:105
 TOrdCollection.cxx:106
 TOrdCollection.cxx:107
 TOrdCollection.cxx:108
 TOrdCollection.cxx:109
 TOrdCollection.cxx:110
 TOrdCollection.cxx:111
 TOrdCollection.cxx:112
 TOrdCollection.cxx:113
 TOrdCollection.cxx:114
 TOrdCollection.cxx:115
 TOrdCollection.cxx:116
 TOrdCollection.cxx:117
 TOrdCollection.cxx:118
 TOrdCollection.cxx:119
 TOrdCollection.cxx:120
 TOrdCollection.cxx:121
 TOrdCollection.cxx:122
 TOrdCollection.cxx:123
 TOrdCollection.cxx:124
 TOrdCollection.cxx:125
 TOrdCollection.cxx:126
 TOrdCollection.cxx:127
 TOrdCollection.cxx:128
 TOrdCollection.cxx:129
 TOrdCollection.cxx:130
 TOrdCollection.cxx:131
 TOrdCollection.cxx:132
 TOrdCollection.cxx:133
 TOrdCollection.cxx:134
 TOrdCollection.cxx:135
 TOrdCollection.cxx:136
 TOrdCollection.cxx:137
 TOrdCollection.cxx:138
 TOrdCollection.cxx:139
 TOrdCollection.cxx:140
 TOrdCollection.cxx:141
 TOrdCollection.cxx:142
 TOrdCollection.cxx:143
 TOrdCollection.cxx:144
 TOrdCollection.cxx:145
 TOrdCollection.cxx:146
 TOrdCollection.cxx:147
 TOrdCollection.cxx:148
 TOrdCollection.cxx:149
 TOrdCollection.cxx:150
 TOrdCollection.cxx:151
 TOrdCollection.cxx:152
 TOrdCollection.cxx:153
 TOrdCollection.cxx:154
 TOrdCollection.cxx:155
 TOrdCollection.cxx:156
 TOrdCollection.cxx:157
 TOrdCollection.cxx:158
 TOrdCollection.cxx:159
 TOrdCollection.cxx:160
 TOrdCollection.cxx:161
 TOrdCollection.cxx:162
 TOrdCollection.cxx:163
 TOrdCollection.cxx:164
 TOrdCollection.cxx:165
 TOrdCollection.cxx:166
 TOrdCollection.cxx:167
 TOrdCollection.cxx:168
 TOrdCollection.cxx:169
 TOrdCollection.cxx:170
 TOrdCollection.cxx:171
 TOrdCollection.cxx:172
 TOrdCollection.cxx:173
 TOrdCollection.cxx:174
 TOrdCollection.cxx:175
 TOrdCollection.cxx:176
 TOrdCollection.cxx:177
 TOrdCollection.cxx:178
 TOrdCollection.cxx:179
 TOrdCollection.cxx:180
 TOrdCollection.cxx:181
 TOrdCollection.cxx:182
 TOrdCollection.cxx:183
 TOrdCollection.cxx:184
 TOrdCollection.cxx:185
 TOrdCollection.cxx:186
 TOrdCollection.cxx:187
 TOrdCollection.cxx:188
 TOrdCollection.cxx:189
 TOrdCollection.cxx:190
 TOrdCollection.cxx:191
 TOrdCollection.cxx:192
 TOrdCollection.cxx:193
 TOrdCollection.cxx:194
 TOrdCollection.cxx:195
 TOrdCollection.cxx:196
 TOrdCollection.cxx:197
 TOrdCollection.cxx:198
 TOrdCollection.cxx:199
 TOrdCollection.cxx:200
 TOrdCollection.cxx:201
 TOrdCollection.cxx:202
 TOrdCollection.cxx:203
 TOrdCollection.cxx:204
 TOrdCollection.cxx:205
 TOrdCollection.cxx:206
 TOrdCollection.cxx:207
 TOrdCollection.cxx:208
 TOrdCollection.cxx:209
 TOrdCollection.cxx:210
 TOrdCollection.cxx:211
 TOrdCollection.cxx:212
 TOrdCollection.cxx:213
 TOrdCollection.cxx:214
 TOrdCollection.cxx:215
 TOrdCollection.cxx:216
 TOrdCollection.cxx:217
 TOrdCollection.cxx:218
 TOrdCollection.cxx:219
 TOrdCollection.cxx:220
 TOrdCollection.cxx:221
 TOrdCollection.cxx:222
 TOrdCollection.cxx:223
 TOrdCollection.cxx:224
 TOrdCollection.cxx:225
 TOrdCollection.cxx:226
 TOrdCollection.cxx:227
 TOrdCollection.cxx:228
 TOrdCollection.cxx:229
 TOrdCollection.cxx:230
 TOrdCollection.cxx:231
 TOrdCollection.cxx:232
 TOrdCollection.cxx:233
 TOrdCollection.cxx:234
 TOrdCollection.cxx:235
 TOrdCollection.cxx:236
 TOrdCollection.cxx:237
 TOrdCollection.cxx:238
 TOrdCollection.cxx:239
 TOrdCollection.cxx:240
 TOrdCollection.cxx:241
 TOrdCollection.cxx:242
 TOrdCollection.cxx:243
 TOrdCollection.cxx:244
 TOrdCollection.cxx:245
 TOrdCollection.cxx:246
 TOrdCollection.cxx:247
 TOrdCollection.cxx:248
 TOrdCollection.cxx:249
 TOrdCollection.cxx:250
 TOrdCollection.cxx:251
 TOrdCollection.cxx:252
 TOrdCollection.cxx:253
 TOrdCollection.cxx:254
 TOrdCollection.cxx:255
 TOrdCollection.cxx:256
 TOrdCollection.cxx:257
 TOrdCollection.cxx:258
 TOrdCollection.cxx:259
 TOrdCollection.cxx:260
 TOrdCollection.cxx:261
 TOrdCollection.cxx:262
 TOrdCollection.cxx:263
 TOrdCollection.cxx:264
 TOrdCollection.cxx:265
 TOrdCollection.cxx:266
 TOrdCollection.cxx:267
 TOrdCollection.cxx:268
 TOrdCollection.cxx:269
 TOrdCollection.cxx:270
 TOrdCollection.cxx:271
 TOrdCollection.cxx:272
 TOrdCollection.cxx:273
 TOrdCollection.cxx:274
 TOrdCollection.cxx:275
 TOrdCollection.cxx:276
 TOrdCollection.cxx:277
 TOrdCollection.cxx:278
 TOrdCollection.cxx:279
 TOrdCollection.cxx:280
 TOrdCollection.cxx:281
 TOrdCollection.cxx:282
 TOrdCollection.cxx:283
 TOrdCollection.cxx:284
 TOrdCollection.cxx:285
 TOrdCollection.cxx:286
 TOrdCollection.cxx:287
 TOrdCollection.cxx:288
 TOrdCollection.cxx:289
 TOrdCollection.cxx:290
 TOrdCollection.cxx:291
 TOrdCollection.cxx:292
 TOrdCollection.cxx:293
 TOrdCollection.cxx:294
 TOrdCollection.cxx:295
 TOrdCollection.cxx:296
 TOrdCollection.cxx:297
 TOrdCollection.cxx:298
 TOrdCollection.cxx:299
 TOrdCollection.cxx:300
 TOrdCollection.cxx:301
 TOrdCollection.cxx:302
 TOrdCollection.cxx:303
 TOrdCollection.cxx:304
 TOrdCollection.cxx:305
 TOrdCollection.cxx:306
 TOrdCollection.cxx:307
 TOrdCollection.cxx:308
 TOrdCollection.cxx:309
 TOrdCollection.cxx:310
 TOrdCollection.cxx:311
 TOrdCollection.cxx:312
 TOrdCollection.cxx:313
 TOrdCollection.cxx:314
 TOrdCollection.cxx:315
 TOrdCollection.cxx:316
 TOrdCollection.cxx:317
 TOrdCollection.cxx:318
 TOrdCollection.cxx:319
 TOrdCollection.cxx:320
 TOrdCollection.cxx:321
 TOrdCollection.cxx:322
 TOrdCollection.cxx:323
 TOrdCollection.cxx:324
 TOrdCollection.cxx:325
 TOrdCollection.cxx:326
 TOrdCollection.cxx:327
 TOrdCollection.cxx:328
 TOrdCollection.cxx:329
 TOrdCollection.cxx:330
 TOrdCollection.cxx:331
 TOrdCollection.cxx:332
 TOrdCollection.cxx:333
 TOrdCollection.cxx:334
 TOrdCollection.cxx:335
 TOrdCollection.cxx:336
 TOrdCollection.cxx:337
 TOrdCollection.cxx:338
 TOrdCollection.cxx:339
 TOrdCollection.cxx:340
 TOrdCollection.cxx:341
 TOrdCollection.cxx:342
 TOrdCollection.cxx:343
 TOrdCollection.cxx:344
 TOrdCollection.cxx:345
 TOrdCollection.cxx:346
 TOrdCollection.cxx:347
 TOrdCollection.cxx:348
 TOrdCollection.cxx:349
 TOrdCollection.cxx:350
 TOrdCollection.cxx:351
 TOrdCollection.cxx:352
 TOrdCollection.cxx:353
 TOrdCollection.cxx:354
 TOrdCollection.cxx:355
 TOrdCollection.cxx:356
 TOrdCollection.cxx:357
 TOrdCollection.cxx:358
 TOrdCollection.cxx:359
 TOrdCollection.cxx:360
 TOrdCollection.cxx:361
 TOrdCollection.cxx:362
 TOrdCollection.cxx:363
 TOrdCollection.cxx:364
 TOrdCollection.cxx:365
 TOrdCollection.cxx:366
 TOrdCollection.cxx:367
 TOrdCollection.cxx:368
 TOrdCollection.cxx:369
 TOrdCollection.cxx:370
 TOrdCollection.cxx:371
 TOrdCollection.cxx:372
 TOrdCollection.cxx:373
 TOrdCollection.cxx:374
 TOrdCollection.cxx:375
 TOrdCollection.cxx:376
 TOrdCollection.cxx:377
 TOrdCollection.cxx:378
 TOrdCollection.cxx:379
 TOrdCollection.cxx:380
 TOrdCollection.cxx:381
 TOrdCollection.cxx:382
 TOrdCollection.cxx:383
 TOrdCollection.cxx:384
 TOrdCollection.cxx:385
 TOrdCollection.cxx:386
 TOrdCollection.cxx:387
 TOrdCollection.cxx:388
 TOrdCollection.cxx:389
 TOrdCollection.cxx:390
 TOrdCollection.cxx:391
 TOrdCollection.cxx:392
 TOrdCollection.cxx:393
 TOrdCollection.cxx:394
 TOrdCollection.cxx:395
 TOrdCollection.cxx:396
 TOrdCollection.cxx:397
 TOrdCollection.cxx:398
 TOrdCollection.cxx:399
 TOrdCollection.cxx:400
 TOrdCollection.cxx:401
 TOrdCollection.cxx:402
 TOrdCollection.cxx:403
 TOrdCollection.cxx:404
 TOrdCollection.cxx:405
 TOrdCollection.cxx:406
 TOrdCollection.cxx:407
 TOrdCollection.cxx:408
 TOrdCollection.cxx:409
 TOrdCollection.cxx:410
 TOrdCollection.cxx:411
 TOrdCollection.cxx:412
 TOrdCollection.cxx:413
 TOrdCollection.cxx:414
 TOrdCollection.cxx:415
 TOrdCollection.cxx:416
 TOrdCollection.cxx:417
 TOrdCollection.cxx:418
 TOrdCollection.cxx:419
 TOrdCollection.cxx:420
 TOrdCollection.cxx:421
 TOrdCollection.cxx:422
 TOrdCollection.cxx:423
 TOrdCollection.cxx:424
 TOrdCollection.cxx:425
 TOrdCollection.cxx:426
 TOrdCollection.cxx:427
 TOrdCollection.cxx:428
 TOrdCollection.cxx:429
 TOrdCollection.cxx:430
 TOrdCollection.cxx:431
 TOrdCollection.cxx:432
 TOrdCollection.cxx:433
 TOrdCollection.cxx:434
 TOrdCollection.cxx:435
 TOrdCollection.cxx:436
 TOrdCollection.cxx:437
 TOrdCollection.cxx:438
 TOrdCollection.cxx:439
 TOrdCollection.cxx:440
 TOrdCollection.cxx:441
 TOrdCollection.cxx:442
 TOrdCollection.cxx:443
 TOrdCollection.cxx:444
 TOrdCollection.cxx:445
 TOrdCollection.cxx:446
 TOrdCollection.cxx:447
 TOrdCollection.cxx:448
 TOrdCollection.cxx:449
 TOrdCollection.cxx:450
 TOrdCollection.cxx:451
 TOrdCollection.cxx:452
 TOrdCollection.cxx:453
 TOrdCollection.cxx:454
 TOrdCollection.cxx:455
 TOrdCollection.cxx:456
 TOrdCollection.cxx:457
 TOrdCollection.cxx:458
 TOrdCollection.cxx:459
 TOrdCollection.cxx:460
 TOrdCollection.cxx:461
 TOrdCollection.cxx:462
 TOrdCollection.cxx:463
 TOrdCollection.cxx:464
 TOrdCollection.cxx:465
 TOrdCollection.cxx:466
 TOrdCollection.cxx:467
 TOrdCollection.cxx:468
 TOrdCollection.cxx:469
 TOrdCollection.cxx:470
 TOrdCollection.cxx:471
 TOrdCollection.cxx:472
 TOrdCollection.cxx:473
 TOrdCollection.cxx:474
 TOrdCollection.cxx:475
 TOrdCollection.cxx:476
 TOrdCollection.cxx:477
 TOrdCollection.cxx:478
 TOrdCollection.cxx:479
 TOrdCollection.cxx:480
 TOrdCollection.cxx:481
 TOrdCollection.cxx:482
 TOrdCollection.cxx:483
 TOrdCollection.cxx:484
 TOrdCollection.cxx:485
 TOrdCollection.cxx:486
 TOrdCollection.cxx:487
 TOrdCollection.cxx:488
 TOrdCollection.cxx:489
 TOrdCollection.cxx:490
 TOrdCollection.cxx:491
 TOrdCollection.cxx:492
 TOrdCollection.cxx:493
 TOrdCollection.cxx:494
 TOrdCollection.cxx:495
 TOrdCollection.cxx:496
 TOrdCollection.cxx:497
 TOrdCollection.cxx:498
 TOrdCollection.cxx:499
 TOrdCollection.cxx:500
 TOrdCollection.cxx:501
 TOrdCollection.cxx:502
 TOrdCollection.cxx:503
 TOrdCollection.cxx:504
 TOrdCollection.cxx:505
 TOrdCollection.cxx:506
 TOrdCollection.cxx:507
 TOrdCollection.cxx:508
 TOrdCollection.cxx:509
 TOrdCollection.cxx:510
 TOrdCollection.cxx:511
 TOrdCollection.cxx:512
 TOrdCollection.cxx:513
 TOrdCollection.cxx:514
 TOrdCollection.cxx:515
 TOrdCollection.cxx:516
 TOrdCollection.cxx:517
 TOrdCollection.cxx:518
 TOrdCollection.cxx:519
 TOrdCollection.cxx:520
 TOrdCollection.cxx:521
 TOrdCollection.cxx:522
 TOrdCollection.cxx:523
 TOrdCollection.cxx:524
 TOrdCollection.cxx:525
 TOrdCollection.cxx:526
 TOrdCollection.cxx:527
 TOrdCollection.cxx:528
 TOrdCollection.cxx:529
 TOrdCollection.cxx:530
 TOrdCollection.cxx:531
 TOrdCollection.cxx:532
 TOrdCollection.cxx:533
 TOrdCollection.cxx:534
 TOrdCollection.cxx:535
 TOrdCollection.cxx:536
 TOrdCollection.cxx:537
 TOrdCollection.cxx:538
 TOrdCollection.cxx:539
 TOrdCollection.cxx:540
 TOrdCollection.cxx:541
 TOrdCollection.cxx:542
 TOrdCollection.cxx:543
 TOrdCollection.cxx:544
 TOrdCollection.cxx:545
 TOrdCollection.cxx:546
 TOrdCollection.cxx:547
 TOrdCollection.cxx:548
 TOrdCollection.cxx:549
 TOrdCollection.cxx:550
 TOrdCollection.cxx:551
 TOrdCollection.cxx:552
 TOrdCollection.cxx:553
 TOrdCollection.cxx:554
 TOrdCollection.cxx:555
 TOrdCollection.cxx:556
 TOrdCollection.cxx:557
 TOrdCollection.cxx:558
 TOrdCollection.cxx:559
 TOrdCollection.cxx:560
 TOrdCollection.cxx:561
 TOrdCollection.cxx:562
 TOrdCollection.cxx:563
 TOrdCollection.cxx:564
 TOrdCollection.cxx:565
 TOrdCollection.cxx:566
 TOrdCollection.cxx:567