ROOT logo
// $Id: ZList.cxx 2759 2012-06-07 01:15:27Z matevz $

// Copyright (C) 1999-2008, Matevz Tadel. All rights reserved.
// This file is part of GLED, released under GNU General Public License version 2.
// For the licensing terms see $GLEDSYS/LICENSE or http://www.gnu.org/.


//______________________________________________________________________
// ZList
//
//

#include "ZList.h"
#include "ZList.c7"

#include <Glasses/ZQueen.h>
#include <Glasses/ZKing.h>
#include <Eye/Ray.h>
#include <Stones/ZComet.h>
#include <Gled/GledNS.h>

#include <algorithm>
#include <iterator>

ClassImp(ZList);

/**************************************************************************/

void ZList::_init()
{
  mNextId = 0;
}

/**************************************************************************/

Int_t ZList::remove_references_to(ZGlass* lens)
{
  Int_t n  = ZGlass::remove_references_to(lens);
  GMutexHolder llck(mListMutex);
  for(iterator i=begin(); i!=end(); ++i) {
    if(i() == lens) {
      iterator j = i; --i;
      Int_t id = j->fId;
      on_remove(j);
      mElements.erase(j);
      StampListRemove(lens, id);
      ++n;
    }
  }
  return n;
}

void ZList::clear_list()
{
  mSize = 0;
  mElements.clear();
  mNextId = 0;
}

/**************************************************************************/
// ZGlass reference management, extensions for lists, public part.
/**************************************************************************/

Int_t ZList::RebuildListRefs(An_ID_Demangler* idd)
{
  Int_t ret = 0;
  container in;        // !!! Probaly could do without copy, see ZStringMap
  mElements.swap(in);
  mSize   = 0;
  mNextId = 0;
  for (iterator i = in.begin(); i != in.end(); ++i)
  {
    ZGlass* lens = idd->DemangleID(GledNS::CastLens2ID(i->fLens));
    if (lens)
    {
      try
      {
	lens->IncRefCount(this);
	mElements.push_back(element(lens, mNextId++)); ++mSize;
      }
      catch(...)
      {
	++ret;
      }
    }
    else
    {
      ++ret;
    }
  }
  on_rebuild();
  return ret;
}

void ZList::ClearList()
{
  static const Exc_t _eh("ZList::ClearList ");

  if(mSize == 0) return;

  container foo;
  ISdebug(1, _eh + GForm("locking list '%s'.", GetName()));
  mListMutex.Lock();
  foo.swap(mElements);
  clear_list();
  StampListClear();
  mListMutex.Unlock();
  ISdebug(1, _eh + GForm("unlocked list '%s'.", GetName()));
  for(iterator i=foo.begin(); i!=foo.end(); ++i) {
    i()->DecRefCount(this);
  }
  ISdebug(1, _eh + GForm("finished for '%s'.", GetName()));
}

/**************************************************************************/
// AList methods, public part.
/**************************************************************************/

AList::stepper_base* ZList::make_stepper_imp()
{
  return new stepper_imp<ZList>(begin(), end());
}

/**************************************************************************/
// Generick
/**************************************************************************/

void ZList::Add(ZGlass* lens)
{
  PushBack(lens);
}

Int_t ZList::RemoveAll(ZGlass* lens)
{
  Int_t n  = 0;
  GMutexHolder llck(mListMutex);
  for(iterator i=begin(); i!=end(); ++i) {
    if(i() == lens) {
      iterator j = i; --i;
      on_remove(j);
      StampListRemove(j->fLens, j->fId);
      mElements.erase(j); --mSize;
      ++n;
    }
  }
  if(n) lens->DecRefCount(this, n);
  return n;
}

/**************************************************************************/
// Deque
/**************************************************************************/

ZGlass* ZList::FrontElement()
{
  ZGlass* l;
  { GMutexHolder llck(mListMutex);
    l = mSize ? mElements.front().fLens : 0;
  }
  ZMIR* mir = get_MIR();
  if(mir && mir->HasResultReq()) {
    TBufferFile b(TBuffer::kWrite);
    GledNS::WriteLensID(b, l);
    mSaturn->ShootMIRResult(b);
  }
  return l;
}

ZGlass* ZList::BackElement()
{
  ZGlass* l;
  { GMutexHolder llck(mListMutex);
    l = mSize ? mElements.back().fLens : 0;
  }
  ZMIR* mir = get_MIR();
  if(mir && mir->HasResultReq()) {
    TBufferFile b(TBuffer::kWrite);
    GledNS::WriteLensID(b, l);
    mSaturn->ShootMIRResult(b);
  }
  return l;
}

void ZList::PushBack(ZGlass* lens)
{
  GMutexHolder llck(mListMutex);
  new_element_check(lens);
  lens->IncRefCount(this);
  mElements.push_back(element(lens, mNextId++)); ++mSize;
  on_insert(--end());
  StampListPushBack(lens, mNextId - 1);
}

ZGlass* ZList::PopBack()
{
  static const Exc_t _eh("ZList::PopBack ");

  if(mSize == 0)
    throw(_eh + "list empty.");

  ZGlass* l;
  { GMutexHolder llck(mListMutex);
    l = mElements.back().fLens;
    on_remove(--end());
    mElements.pop_back(); --mSize;
    l->DecRefCount(this);
    StampListPopBack();
  }
  ZMIR* mir = get_MIR();
  if(mir && mir->HasResultReq()) {
    TBufferFile b(TBuffer::kWrite);
    GledNS::WriteLensID(b, l);
    mSaturn->ShootMIRResult(b);
  }
  return l;
}

void ZList::PushFront(ZGlass* lens)
{
  GMutexHolder llck(mListMutex);
  new_element_check(lens);
  lens->IncRefCount(this);
  mElements.push_front(element(lens, mNextId++)); ++mSize;
  on_insert(begin());
  StampListPushFront(lens, mNextId - 1);
}

ZGlass* ZList::PopFront()
{
  static const Exc_t _eh("ZList::PopFront ");

  if(mSize == 0)
    throw(_eh + "list empty.");

  ZGlass* l;
  { GMutexHolder llck(mListMutex);
    l = mElements.front().fLens;
    on_remove(begin());
    mElements.pop_front(); --mSize;
    l->DecRefCount(this);
    StampListPopFront();
  }
  ZMIR* mir = get_MIR();
  if(mir && mir->HasResultReq()) {
    TBufferFile b(TBuffer::kWrite);
    GledNS::WriteLensID(b, l);
    mSaturn->ShootMIRResult(b);
  }
  return l;
}

/**************************************************************************/
// Insert by Id
/**************************************************************************/

namespace
{
  struct element_eq_id : public unary_function<ZList::element&, bool>
  {
    Int_t id;
    element_eq_id(Int_t i) : id(i) {}
    bool operator()(const ZList::element& el) { return el.fId == id; }
  };
}

void ZList::InsertById(ZGlass* lens, Int_t before_id)
{
  static const Exc_t _eh("ZList::InsertById ");

  GMutexHolder llck(mListMutex);
  new_element_check(lens);
  iterator i = find_if(begin(), end(), element_eq_id(before_id));
  if(i == end())
    throw(_eh + "element with given id not found.");
  lens->IncRefCount(this);
  mElements.insert(i, element(lens, mNextId++)); ++mSize;
  on_insert(--i);
  StampListInsert(lens, mNextId-1, before_id);
}

void ZList::RemoveById(Int_t id_to_remove)
{
  static const Exc_t _eh("ZList::RemoveById ");

  if(mSize == 0)
    throw(_eh + "list empty.");

  GMutexHolder llck(mListMutex);
  iterator i = find_if(begin(), end(), element_eq_id(id_to_remove));
  if(i == end())
    throw(_eh + "element with given id not found.");
  ZGlass* l = i->fLens;
  on_remove(i);
  mElements.erase(i); --mSize;
  l->DecRefCount(this);
  StampListRemove(l, id_to_remove);
}

Int_t ZList::FindFirst(ZGlass* lens)
{
  static const Exc_t _eh("ZList::FindFirst ");

  GMutexHolder llck(mListMutex);
  for(iterator i=begin(); i!=end(); ++i) {
    if(i->fLens == lens)
      return i->fId;
  }
  throw(_eh + "lens not found.");
}

/**************************************************************************/
// ZList specific
/**************************************************************************/

void ZList::SortByName()
{
  GMutexHolder llck(mListMutex);
  if(mSize < 2) return;
  multimap<TString, ZGlass*> nmap;
  for(iterator i=begin(); i!=end(); ++i) {
    nmap.insert(pair<TString, ZGlass*>(i()->GetName(), i()));
  }
  mElements.clear();
  mNextId = 0;
  for(multimap<TString, ZGlass*>::iterator i=nmap.begin(); i!=nmap.end(); ++i) {
    mElements.push_back(element(i->second, mNextId++));
  }
  on_rebuild();
  StampListRebuild();
}

/**************************************************************************/
// Configuration helpers.
/**************************************************************************/

ZList* ZList::AssertPath(const Text_t* path, const Text_t* new_el_type)
{
  // Makes sure that 'path' exists. From the missing element onwards
  // creates new sub-lists of type 'new_el_type'.
  // Throws an exception if:
  // a) link dereferencing is found in path;
  // b) would have to create a missing element under some other queen;
  // c) element in path is not a list;
  // d) instantiation fails.

  static const Exc_t _eh("ZList::AssertPath ");

  namespace GNS = GledNS;

  FID_t new_el_fid = GNS::FindClassID(new_el_type);
  if(new_el_fid.is_null())
    throw(_eh + "unknown list element type '" + new_el_type + "'.");


  list<GNS::url_token> ts;
  GNS::tokenize_url(path, ts);

  ZList* l = this;
  for(list<GNS::url_token>::iterator i=ts.begin(); i!=ts.end(); ++i) {
    switch (i->type()) {

    case GNS::url_token::link_sel: {
      throw(_eh + "link found but only list elements expected.");
      break;
    }

    case GNS::url_token::list_sel: {
      ZGlass* e = l->GetElementByName(*i);
      if(e != 0) {
	l = dynamic_cast<ZList*>(e);
	if(l == 0)
	  throw(_eh + "path element is not a list.");
      } else {
	if(l->GetQueen() != mQueen)
	  throw(_eh + "path leading to another queen.");

	if(mQueen->GetKing()->GetLightType() == ZKing::LT_Fire) {
	  ZGlass* g = GledNS::ConstructLens(new_el_fid);
	  if(g == 0) throw(_eh + "direct lens construction failed.");
	  g->SetName(i->Data());
	  mQueen->CheckIn(g); l->Add(g);
	  l = dynamic_cast<ZList*>(g);
	} else {
	  auto_ptr<ZMIR> att_mir( l->S_Add(0) );
	  auto_ptr<ZMIR> inst_mir
	    ( mQueen->S_InstantiateWAttach
	      (new_el_fid.fLid, new_el_fid.fCid, i->Data()) );
	  inst_mir->ChainMIR(att_mir.get());

	  auto_ptr<ZMIR_RR> res( mSaturn->ShootMIRWaitResult(inst_mir) );
	  if(res->HasException())
	    throw(_eh + "got exception: " + res->fException.Data());
	  if(res->HasResult()) {
	    ID_t id; *res >> id;
	    l = dynamic_cast<ZList*>(mSaturn->DemangleID(id));
	  } else
	    throw(_eh + "bad MIR result.");
	}
	if(l == 0)
	  throw(_eh + "instantiation of missing element failed.");
      }
      break;
    }

    default:
      throw(_eh + "unknown token type.");
      break;

    } // end switch
  } // end for

  return l;
}

void ZList::Swallow(ZGlass* entry, Bool_t replace_p,
		    const Text_t* path, const Text_t* new_el_type)
{
  // A helper function for adding configuration DB entries.
  // Mostly intended for use from scripts.
  // Should NOT be called on exposed object-spaces!

  ZList *l = AssertPath(path, new_el_type);
  if(entry->GetSaturnID() == 0) mQueen->CheckIn(entry);
  ZGlass* ex_entry = l->GetElementByName(entry->GetName());
  if(ex_entry)
  {
    if(replace_p)
      l->RemoveAll(ex_entry);
    else
      return;
  }
  l->Add(entry);
}

void ZList::Swallow(const Text_t* path, ZGlass* entry)
{
  Swallow(entry, true, path, "ZList");
}


/**************************************************************************/
/**************************************************************************/
// Streamer
/**************************************************************************/

void ZList::Streamer(TBuffer &b)
{
  UInt_t R__s, R__c;

  if (b.IsReading())
  {
    Version_t R__v = b.ReadVersion(&R__s, &R__c); if(R__v) { }
    AList::Streamer(b);
    b >> mNextId;
    Int_t el_id;
    ID_t  id;
    mElements.clear();
    for (Int_t i = 0; i < mSize; ++i)
    {
      b >> id >> el_id;
      mElements.push_back(element(GledNS::CastID2Lens(id), el_id));
    }
    b.CheckByteCount(R__s, R__c, ZList::IsA());
  }
  else
  {
    R__c = b.WriteVersion(ZList::IsA(), kTRUE);
    AList::Streamer(b);
    b << mNextId;
    for (iterator i = begin(); i != end(); ++i)
    {
      b << i()->GetSaturnID() << i->fId;
    }
    b.SetByteCount(R__c, kTRUE);
  }
}

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