59 "ROOT files",
"*.root",
65 "C files",
"*.[C|c]*",
66 "ROOT files",
"*.root",
84 if (!p || !
main)
return;
99 this,
"OnElementClicked(TGLVEntry* ,Int_t)");
115 AddFrame(
new TGLabel(
this,
"Double-click on the macro to be executed to create a new Chain:"),
124 gClient->GetColorByName(
"white",white);
141 0, 0, ax, ay, wdummy);
142 Move(ax + 200, ay + 35);
181 if (obj && (obj->IsA() == TChain::Class() ||
182 obj->IsA() == TDSet::Class())) {
183 Emit(
"OnElementSelected(TObject *)", (
Long_t)obj);
194 if (
fChain->IsA() == TChain::Class()) {
199 else if (
fChain->IsA() == TDSet::Class()) {
220 while ((obj = (
TObject *)next())) {
222 if (obj->IsA() == TChain::Class()) {
225 ((
TChain *)obj)->SetTitle(
"TChain");
229 else if (obj->IsA() == TDSet::Class()) {
266 if (
name.Contains(
".C")) {
359 if (editmode && query)
361 else if (!editmode) {
381 0, 0, ax, ay, wdummy);
429 btnTmp->
Connect(
"Clicked()",
"TNewQueryDlg",
this,
"OnBrowseChain()");
440 btnTmp->
Connect(
"Clicked()",
"TNewQueryDlg",
this,
"OnBrowseSelector()");
445 fBtnMore->
Connect(
"Clicked()",
"TNewQueryDlg",
this,
"OnNewQueryMore()");
489 btnTmp->
Connect(
"Clicked()",
"TNewQueryDlg",
this,
"OnBrowseEventList()");
500 "SettingsChanged()");
502 "SettingsChanged()");
504 "SettingsChanged()");
506 "SettingsChanged()");
508 "SettingsChanged()");
510 "SettingsChanged()");
512 "SettingsChanged()");
532 fBtnSave->
Connect(
"Clicked()",
"TNewQueryDlg",
this,
"OnBtnSaveClicked()");
536 fBtnClose->
Connect(
"Clicked()",
"TNewQueryDlg",
this,
"OnBtnCloseClicked()");
570 dlg->
Connect(
"OnElementSelected(TObject *)",
"TNewQueryDlg",
571 this,
"OnElementSelected(TObject *)");
581 if (obj->IsA() == TChain::Class())
583 else if (obj->IsA() == TDSet::Class())
638 if (newquery->
fChain->IsA() == TChain::Class())
640 else if (newquery->
fChain->IsA() == TDSet::Class())
652 int e = 1, j = 0, idx = 0;
654 for (
int i=strlen(
name)-1;i>0;i--) {
655 if (isdigit(
name[i])) {
656 idx += (
name[i]-
'0') *
e;
717 "Do you wish to SAVE changes ?", 0,
723 if (result ==
kMBNo) {
936 "OnOverwriteDataset(Bool_t)");
938 "OnOverwriteFiles(Bool_t)");
940 "OnAppendFiles(Bool_t)");
992 0, 0, ax, ay, wdummy);
993 Move(ax + 250, ay + 200);
1076 if (strlen(fileName) < 5)
1078 if (strstr(fileName,
"*.")) {
1095 gClient->GetPicture(
"rootdb_t.xpm"));
1106 gClient->GetPicture(
"rootdb_t.xpm"));
1122 TIter next(fileList);
1131 gClient->GetPicture(
"rootdb_t.xpm"));
1244 flags &=
~TProof::kNoOverwriteDataSet;
1261 if (strlen(destination) < 2) destination = 0;
1268 datasetFiles, destination, flags, skippedFiles);
1270 if (ret == TProof::kDataSetExists) {
1274 TString::Format(
"The dataset \"%s\" already exists on the cluster ! Overwrite ?",
1279 datasetFiles, destination,
1286 datasetFiles, destination,
1296 "Failed uploading dataset/files to the cluster",
1304 if (skippedFiles->
GetSize()) {
1305 TIter nexts(skippedFiles);
1310 TString::Format(
"The file \"%s\" already exists on the cluster ! Overwrite ?",
1315 skippedFiles, destination,
1327 "Files have been successfully uploaded to the cluster",
1341 obj->GetFirstUrl()->GetUrl(), destination,
1352 "Files have been successfully uploaded to the cluster",
1357 skippedFiles->
Clear();
1361 "Files have been successfully uploaded to the cluster",
ULong_t Pixel_t
Pixel value.
Handle_t Window_t
Window handle.
static const char * gFileTypes[]
R__EXTERN TApplication * gApplication
static const char * gFileTypes[]
static const char * gDatasetTypes[]
char * Form(const char *fmt,...)
R__EXTERN TSystem * gSystem
virtual Long_t ProcessLine(const char *line, Bool_t sync=kFALSE, Int_t *error=0)
Process a single command line, either a C++ statement or an interpreter command starting with a "....
A chain is a collection of files containing TTree objects.
virtual Int_t GetSize() const
Return the capacity of the collection, i.e.
This class implements a data set to be used for PROOF processing.
Class describing a generic file including meta information.
const TGWindow * GetDefaultRoot() const
Returns the root (i.e.
const TGWindow * GetRoot() const
Returns current root (i.e.
Bool_t GetColorByName(const char *name, Pixel_t &pixel) const
Get a color by name.
void NeedRedraw(TGWindow *w, Bool_t force=kFALSE)
Set redraw flags.
virtual void SetLayoutManager(TGLayoutManager *l)
Set the layout manager for the composite frame.
virtual TList * GetList() const
virtual void AddFrame(TGFrame *f, TGLayoutHints *l=0)
Add frame to the composite frame using the specified layout hints.
virtual void Cleanup()
Cleanup and delete all objects contained in this composite frame.
virtual void Layout()
Layout the elements of the composite frame.
virtual void ChangeOptions(UInt_t options)
Change composite frame options. Options is an OR of the EFrameTypes.
virtual void SetCleanup(Int_t mode=kLocalCleanup)
Turn on automatic cleanup of child frames in dtor.
virtual TGDimension GetDefaultSize() const
std::cout << fWidth << "x" << fHeight << std::endl;
virtual void MapSubwindows()
Map all sub windows that are part of the composite frame.
virtual void ShowFrame(TGFrame *f)
Show sub frame.
virtual void HideFrame(TGFrame *f)
Hide sub frame.
Bool_t IsVisible(TGFrame *f) const
Get state of sub frame.
virtual void Associate(const TGWindow *w)
virtual void RemoveItem(TGFrame *item)
Remove item from container.
virtual TGFrame * GetLastActive() const
virtual void RemoveAll()
Remove all items from the container.
virtual void * FindItem(const TString &name, Bool_t direction=kTRUE, Bool_t caseSensitive=kTRUE, Bool_t subString=kFALSE)
void StopRefreshTimer()
stop refresh timer
virtual void ChangeDirectory(const char *path)
Change current directory.
virtual void DisplayDirectory()
Display the contents of the current directory in the container.
virtual TGFileItem * AddFile(const char *name, const TGPicture *pic=nullptr, const TGPicture *lpic=nullptr)
Add file in container.
virtual void SetFilter(const char *filter)
Set file selection filter.
const char * GetDirectory() const
void SetFilename(const char *fname)
Set file name.
Bool_t fMultipleSelection
static Pixel_t GetWhitePixel()
Get white pixel value.
virtual void SetMinWidth(UInt_t w)
virtual UInt_t GetDefaultHeight() const
virtual void DeleteWindow()
Delete window.
virtual UInt_t GetOptions() const
virtual void ChangeBackground(Pixel_t back)
Change frame background color.
virtual void Move(Int_t x, Int_t y)
Move frame.
virtual void Resize(UInt_t w=0, UInt_t h=0)
Resize the frame.
virtual void MapWindow()
map window
void SetHeader(const char *s, Int_t hmode, Int_t cmode, Int_t idx)
void SetHeaders(Int_t ncolumns)
virtual void AddItem(TGLVEntry *item)
virtual void SetViewMode(EListViewMode viewMode)
Set list view mode for container.
virtual void SetPictures(const TGPicture *bigpic=0, const TGPicture *smallpic=0)
change pictures
void * GetUserData() const
virtual const char * GetTitle() const
Returns title of object.
void SetUserData(void *userData)
virtual void SetUserData(void *, Bool_t=kFALSE)
void ClearHighlighted()
Un highlight items.
void RenameItem(TGListTreeItem *item, const char *string)
Rename item in list tree.
void AddItem(TGListTreeItem *parent, TGListTreeItem *item)
Add given item to list tree.
void OpenItem(TGListTreeItem *item)
Open item in list tree (i.e. show child items).
TGListTreeItem * GetSelected() const
void SetSelected(TGListTreeItem *item)
void HighlightItem(TGListTreeItem *item)
Highlight item.
TGListTreeItem * FindChildByData(TGListTreeItem *item, void *userData)
Find child of item by userData.
virtual void AdjustHeaders()
virtual void Layout()
Layout list view components (container and contents of container).
void SetWMSizeHints(UInt_t wmin, UInt_t hmin, UInt_t wmax, UInt_t hmax, UInt_t winc, UInt_t hinc)
Give the window manager minimum and maximum size hints.
void SetWindowName(const char *name=0)
Set window name. This is typically done via the window manager.
virtual void SetIntNumber(Long_t val)
virtual void Associate(const TGWindow *w)
Make w the window that will receive the generated messages.
virtual Long_t GetIntNumber() const
virtual void SetText(TGHotString *new_label)
Set new button text.
virtual void SetFocus()
Set focus to this text entry.
const char * GetText() const
void SetEnabled(Bool_t flag=kTRUE)
virtual void SelectAll()
Selects all text (i.e.
virtual void SetToolTipText(const char *text, Long_t delayms=500)
Set tool tip text associated with this text entry.
virtual void SetText(const char *text, Bool_t emit=kTRUE)
Sets text entry to text, clears the selection and moves the cursor to the end of the line.
virtual const char * GetName() const
Return unique name, used in SavePrimitive methods.
virtual void Add(TObject *obj)
virtual TObject * FindObject(const char *name) const
Find an object in this list using its name.
virtual TObject * Last() const
Return the last object in the list. Returns 0 when list is empty.
virtual void Clear(Option_t *option="")
Remove all objects from the list.
virtual void OnDoubleClick(TGLVEntry *, Int_t)
Handle double click in the File container.
TGTextButton * fCancelButton
virtual ~TNewChainDlg()
Delete chain dialog.
void OnElementSelected(TObject *obj)
Emits OnElementSelected signal if dset is not zero.
TGLVContainer * fLVContainer
void UpdateList()
Update Memory list view.
TGFileContainer * fContents
virtual void DisplayDirectory(const TString &fname)
Display content of directory.
TNewChainDlg(const TGWindow *p=0, const TGWindow *main=0)
Create a new chain dialog box.
virtual Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2)
Process messages for new chain dialog.
void OnElementClicked(TGLVEntry *entry, Int_t btn)
Handle click in the Memory list view and put the type and name of selected object in the text entry.
virtual void CloseWindow()
Close file dialog.
void UpdateFields(TQueryDescription *desc)
Update entry fields with query description values.
void OnElementSelected(TObject *obj)
Handle OnElementSelected signal coming from new chain dialog.
void OnBtnSubmitClicked()
Save and submit query description.
TGTextEntry * fTxtEventList
TGCompositeFrame * fFrmNewQuery
TGTextEntry * fTxtOptions
void OnBtnSaveClicked()
Save current settings in main session viewer.
TQueryDescription * fQuery
virtual ~TNewQueryDlg()
Delete query dialog.
void OnBtnCloseClicked()
Close dialog.
void SettingsChanged()
Settings have changed, update GUI accordingly.
virtual Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2)
Process messages for new query dialog.
TGTextButton * fBtnSubmit
void Popup()
Display dialog and set focus to query name text entry.
void OnBrowseSelector()
Open file browser to choose selector macro.
TGNumberEntry * fNumFirstEntry
TGCompositeFrame * fFrmMore
TNewQueryDlg(TSessionViewer *gui, Int_t Width, Int_t Height, TQueryDescription *query=0, Bool_t editmode=kFALSE)
Create a new Query dialog, used by the Session Viewer, to Edit a Query if the editmode flag is set,...
TGTextEntry * fTxtQueryName
void OnBrowseChain()
Call new chain dialog.
TGNumberEntry * fNumEntries
void Build(TSessionViewer *gui)
Build the "new query" dialog.
void OnNewQueryMore()
Show/hide options frame and update button text accordingly.
void CloseWindow()
Called when window is closed via the window manager.
TGTextEntry * fTxtSelector
void OnBrowseEventList()
Browse event list.
Collectable string class.
const TString & GetString() const
Mother of all ROOT objects.
virtual const char * GetName() const
Returns name of object.
R__ALWAYS_INLINE Bool_t IsZombie() const
virtual const char * GetTitle() const
Returns title of object.
This class controls a Parallel ROOT Facility, PROOF, cluster.
Int_t UploadDataSet(const char *, TList *, const char *=0, Int_t=0, TList *=0)
*** This function is deprecated and will disappear in future versions *** *** It is just a wrapper ar...
void Emit(const char *signal, const T &arg)
Activate signal with single parameter.
Bool_t Connect(const char *signal, const char *receiver_class, void *receiver, const char *slot)
Non-static method is used to connect from the signal of this object to the receiver slot.
ESessionQueryStatus fStatus
Regular expression class.
void UpdateListOfDataSets()
Update list of dataset present on the cluster.
void OnBtnSubmit()
Submit query.
TSessionQueryFrame * GetQueryFrame() const
TGListTree * GetSessionHierarchy() const
void WriteConfiguration(const char *filename=0)
Save actual configuration in config file "filename".
void OnListTreeClicked(TGListTreeItem *entry, Int_t btn, Int_t x, Int_t y)
Handle mouse clicks in list tree.
TSessionFrame * GetSessionFrame() const
TGListTreeItem * GetSessionItem() const
const TGPicture * GetQueryConPict() const
TSessionDescription * GetActDesc() const
const char * Data() const
TString & ReplaceAll(const TString &s1, const TString &s2)
TString & Remove(Ssiz_t pos)
TString & Append(const char *cs)
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
void Form(const char *fmt,...)
Formats a string using a printf style format descriptor.
Ssiz_t Index(const char *pat, Ssiz_t i=0, ECaseCompare cmp=kExact) const
virtual void * OpenDirectory(const char *name)
Open a directory. Returns 0 if directory does not exist.
virtual Bool_t AccessPathName(const char *path, EAccessMode mode=kFileExists)
Returns FALSE if one can access a file using the specified access mode.
virtual const char * GetDirEntry(void *dirp)
Get a directory entry. Returns 0 if no more entries.
virtual Bool_t ChangeDirectory(const char *path)
Change directory.
virtual const char * UnixPathName(const char *unixpathname)
Convert from a local pathname to a Unix pathname.
virtual const char * BaseName(const char *pathname)
Base name of a file name. Base name of /user/root is root.
virtual TString GetDirName(const char *pathname)
Return the directory name in pathname.
void ClearFiles()
Clear content of the list view.
TUploadDataSetDlg(TSessionViewer *gui, Int_t w, Int_t h)
Create a Upload DataSet dialog box. Used to create and upload a dataset.
void OnAppendFiles(Bool_t on)
Notification of Append Files check button.
void RemoveFile()
Remove the selected entry from the list view.
void BrowseFiles()
Opens the TGFileDialog to allow user to select local file(s) to be added in the list view of dataset ...
void UploadDataSet()
Upload the dataset to the server.
virtual ~TUploadDataSetDlg()
Delete chain dialog.
void OnOverwriteDataset(Bool_t on)
Notification of Overwrite Dataset check button.
TGLVContainer * fLVContainer
virtual Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2)
Process messages for upload dataset dialog.
TGTextButton * fRemoveButton
TGTextButton * fUploadButton
TGTextEntry * fLocationURL
TGCheckButton * fOverwriteDSet
TGTextEntry * fDestinationURL
TGTextButton * fAddButton
virtual void CloseWindow()
Close upload dataset dialog.
TGTextButton * fCloseDlgButton
TGTextButton * fBrowseButton
TGCheckButton * fOverwriteFiles
void OnOverwriteFiles(Bool_t on)
Notification of Overwrite Files check button.
TGTextButton * fClearButton
void AddFiles(const char *fileName)
Add File name(s) from the file location URL to the list view.
TGCheckButton * fAppendFiles