1 //_________________________________________________________________________
2 // Macro to merge the tag files from an ESD collection.
3 // The tag files are stored according to the value set in the SetStorage method
5 // SetStorage(0) --> store the tgs locally
6 // SetStorage(1) --> store the tgs in the grid
7 // else the program will abort!!!
9 // As a final step the user can create a single merged tag file.
10 //_________________________________________________________________________
11 void MergeTags(const char* fCollectionName) {
12 //connect to AliEn's API services
13 TGrid::Connect("alien://pcapiserv01.cern.ch:10000","pchrist");
14 //TGrid::Connect("alien://");
16 //___________________________________//
17 //__Create an AliTagCreator object___//
18 //___________________________________//
19 AliTagCreator *t = new AliTagCreator();
21 //___________________________________//
22 //_____ Storage of the tag files:____//
23 //________0-->local, 1-->alien_______//
24 //___________________________________//
27 //___________________________________//
28 //__________Merge tag files__________//
29 //___________________________________//
31 TAlienCollection *collection = TAlienCollection::Open(fCollectionName);
32 TGridResult* result = collection->GetGridResult("");
33 //Read the TGridResult and merge the tags