ROOT  6.07/01
Reference Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
TAlienMasterJobStatus.h
Go to the documentation of this file.
1 // @(#)root/alien:$Id$
2 // Author: Jan Fiete Grosse-Oetringhaus 28/10/2004
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2004, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 #ifndef ROOT_TAlienMasterJobStatus
13 #define ROOT_TAlienMasterJobStatus
14 
15 //////////////////////////////////////////////////////////////////////////
16 // //
17 // TAlienMasterJobStatus //
18 // //
19 // Status of a MasterJob. //
20 // //
21 //////////////////////////////////////////////////////////////////////////
22 
23 #ifndef ROOT_TGridJobStatus
24 #include "TGridJobStatus.h"
25 #endif
26 #ifndef ROOT_TMap
27 #include "TMap.h"
28 #endif
29 
30 class TAlienJobStatus;
31 class TAlienMasterJob;
32 
33 
35 
36 friend class TAlienMasterJob;
37 
38 private:
39  TAlienJobStatus *fMasterJob; // Status of the master job
40  TMap fJobs; // Map which contains the sub jobs,
41  // key is the job ID, values are
42  // TAlienJobStatus objects
43 
44 public:
45  TAlienMasterJobStatus(const char* jobid) : fMasterJob(0)
46  { TString name; name = jobid; SetName(name); SetTitle(name); }
47  virtual ~TAlienMasterJobStatus();
48 
49  EGridJobStatus GetStatus() const;
50  void Print(Option_t *) const;
51 
53 
54  Bool_t IsFolder() const { return kTRUE; }
55  void Browse(TBrowser *b);
56  TMap *GetJobs() { return &fJobs; }
57  Int_t GetNSubJobs() const { return fJobs.GetSize(); }
58 
59  ClassDef(TAlienMasterJobStatus,1) // Status of Alien master job
60 };
61 
62 #endif
virtual ~TAlienMasterJobStatus()
EGridJobStatus GetStatus() const
Returns the status of the master job reduced to the subset defined in TGridJobStatus.
float Float_t
Definition: RtypesCore.h:53
const char Option_t
Definition: RtypesCore.h:62
virtual void SetName(const char *name)
Change (i.e.
Definition: TNamed.cxx:128
Float_t PercentFinished()
Returns the percentage of finished subjobs, only DONE is considered as finished.
Basic string class.
Definition: TString.h:137
int Int_t
Definition: RtypesCore.h:41
bool Bool_t
Definition: RtypesCore.h:59
#define ClassDef(name, id)
Definition: Rtypes.h:254
TAlienJobStatus * fMasterJob
Using a TBrowser one can browse all ROOT objects.
Definition: TBrowser.h:41
TAlienMasterJobStatus(const char *jobid)
void Browse(TBrowser *b)
Browser interface.
virtual Int_t GetSize() const
Definition: TCollection.h:95
TMap implements an associative array of (key,value) pairs using a THashTable for efficient retrieval ...
Definition: TMap.h:44
#define name(a, b)
Definition: linkTestLib0.cpp:5
void Print(Option_t *) const
Prints information of the master job and the sub job. Only the status is printed. ...
const Bool_t kTRUE
Definition: Rtypes.h:91
virtual void SetTitle(const char *title="")
Change (i.e. set) the title of the TNamed.
Definition: TNamed.cxx:152
Bool_t IsFolder() const
Returns kTRUE in case object contains browsable objects (like containers or lists of other objects)...