CMS 3D CMS Logo

IgNTupleAppMain Class Reference

#include <Iguana/Studio/interface/IgNTupleAppMain.h>

Inheritance diagram for IgNTupleAppMain:

IgNTupleAppExtension IgExtension IgStateElement

List of all members.

Public Member Functions

 IgNTupleAppMain (IgState *state)
virtual bool setup (IgNTupleAppSetup *setup)
 ~IgNTupleAppMain (void)

Private Member Functions

 IG_DECLARE_STATE_ELEMENT (IgNTupleAppMain)

Private Attributes

IgDocumentm_document
IgStatem_state
IgStudioDriverm_studio


Detailed Description

Definition at line 23 of file IgNTupleAppMain.h.


Constructor & Destructor Documentation

IgNTupleAppMain::IgNTupleAppMain ( IgState state  ) 

Definition at line 37 of file IgNTupleAppMain.cc.

References ASSERT, m_state, and IgState::put().

00038     : m_state (state),
00039       m_studio (0),
00040       m_document (0)
00041 { ASSERT (m_state); m_state->put (s_key, this);}

IgNTupleAppMain::~IgNTupleAppMain ( void   ) 

Definition at line 43 of file IgNTupleAppMain.cc.

References ASSERT, IgState::detach(), and m_state.

00044 { ASSERT (m_state); m_state->detach (s_key);}


Member Function Documentation

IgNTupleAppMain::IG_DECLARE_STATE_ELEMENT ( IgNTupleAppMain   )  [private]

bool IgNTupleAppMain::setup ( IgNTupleAppSetup setup  )  [virtual]

Reimplemented from IgNTupleAppExtension.

Definition at line 47 of file IgNTupleAppMain.cc.

References IgDocument::addContentProxy(), ASSERT, IgBrowser::browse(), IgDocumentDataRoot::currentRoot(), IgDocument::data(), IgBrowserDB::get(), DBSPlugin::get(), IgQToolBoxSite::hostWithName(), IgRepSet::invalidate(), IgDocument::load(), m_document, m_studio, pydbsAccessor::root, IgDocumentData::root(), IgTwig::SELF_MASK, IgPage::stackArea(), IgPage::state(), IgDocument::state(), IgTwig::STRUCTURE_MASK, and IgNTupleAppSetup::studio().

00048 {
00049     m_studio = from->studio ();
00050     
00051     // Create document
00052     ASSERT (! m_document);
00053     m_document = new IgDocument (m_studio);
00054     IgPage *page = new IgPage (m_document);
00055     
00056     //Create a toolbox area where the stack is.
00057     IgQToolBoxSite *toolbox = new IgQToolBoxSite (page->state (), 
00058                                                   page->stackArea ());
00059     
00060     // Change window caption.
00061     const char* mName = "DQM/Sources";
00062     IgDocumentDataRoot::currentRoot (mName);
00063     
00064     IgBrowser *fullTreeBrowser 
00065         = IgBrowserDB::get()->create ("Tree", 
00066                                       page->state (),
00067                                       toolbox->hostWithName ("Available monitorables"));
00068 
00069     ASSERT (fullTreeBrowser);
00070         
00071     IgState *groupBrowserState = new IgState (page->state ());    
00072     new IgSelectionService (groupBrowserState);
00073     
00074     IgBrowser *groupsTreeBrowser 
00075         = IgBrowserDB::get()->create ("Twig", 
00076                                       groupBrowserState,
00077                                       toolbox->hostWithName ("Subscribed monitorables"));
00078     
00079     ASSERT (groupsTreeBrowser);
00080 
00081     IgTwig *root = IgDocumentData::get (m_document->state ())->root ("", true);
00082     ASSERT (root);
00083     IgSimpleTwig *availableTwigsBranch = new IgSimpleTwig (root, "Available");
00084     IgSimpleTwig *subscribedTwigsBranch = new IgSimpleTwig (root, "Subscribed");
00085 
00086     m_document->addContentProxy (mName);
00087     m_document->load ("Services/NTuple/GUI/", true);
00088     
00089     fullTreeBrowser->browse (availableTwigsBranch);
00090     groupsTreeBrowser->browse (subscribedTwigsBranch);
00091     
00092 
00093     IgRepSet::invalidate (m_document->data ()->root (mName),
00094                           IgTwig::SELF_MASK | IgTwig::STRUCTURE_MASK);
00095     
00096     return true;    
00097 }


Member Data Documentation

IgDocument* IgNTupleAppMain::m_document [private]

Definition at line 39 of file IgNTupleAppMain.h.

Referenced by setup().

IgState* IgNTupleAppMain::m_state [private]

Definition at line 37 of file IgNTupleAppMain.h.

Referenced by IgNTupleAppMain(), and ~IgNTupleAppMain().

IgStudioDriver* IgNTupleAppMain::m_studio [private]

Definition at line 38 of file IgNTupleAppMain.h.

Referenced by setup().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:25:17 2009 for CMSSW by  doxygen 1.5.4