#include <Iguana/Studio/interface/IgNTupleAppSetup.h>
Public Member Functions | |
IgNTupleAppSetup (IgState *state) | |
bool | setup (IgStudioDriver *into) |
IgState * | state (void) const |
IgStudioDriver * | studio (void) const |
~IgNTupleAppSetup (void) | |
Private Member Functions | |
IG_DECLARE_STATE_ELEMENT (IgNTupleAppSetup) | |
Private Attributes | |
IgState * | m_state |
IgStudioDriver * | m_studio |
Definition at line 20 of file IgNTupleAppSetup.h.
IgNTupleAppSetup::IgNTupleAppSetup | ( | IgState * | state | ) |
IgNTupleAppSetup::~IgNTupleAppSetup | ( | void | ) |
Definition at line 30 of file IgNTupleAppSetup.cc.
References ASSERT, IgState::detach(), and m_state.
IgNTupleAppSetup::IG_DECLARE_STATE_ELEMENT | ( | IgNTupleAppSetup | ) | [private] |
bool IgNTupleAppSetup::setup | ( | IgStudioDriver * | into | ) | [virtual] |
Reimplemented from IgStudioSetupExtension.
Definition at line 34 of file IgNTupleAppSetup.cc.
References ASSERT, IgExtensionDB::get(), DBSPlugin::get(), m_state, m_studio, name, and IgNTupleAppExtension::setup().
00035 { 00036 ASSERT (m_state); 00037 ASSERT (into); 00038 ASSERT (!m_studio); 00039 00040 m_studio = into; 00041 00042 static const char name [] = "Services/Generic/NTuple"; 00043 IgNTupleAppExtension * app = 0; 00044 IgExtension * newext = 0; 00045 00046 try 00047 { 00048 // Try to instantiate it 00049 QApplication::setOverrideCursor (Qt::waitCursor); 00050 IgQtAppStatusBarService::get (m_state) 00051 ->setMessage ("Building NTuple browser app..."); 00052 00053 newext = IgExtensionDB::get ()->create (name, m_state); 00054 00055 // Make sure we got what we expect 00056 ASSERT (newext); 00057 ASSERT (dynamic_cast<IgNTupleAppExtension *> (newext)); 00058 app = static_cast<IgNTupleAppExtension *> (newext); 00059 00060 // Try to set it up 00061 app->setup (this); 00062 00063 IgQtAppStatusBarService::get (m_state) 00064 ->setMessage ("NTuple browser is loaded."); 00065 00066 QApplication::restoreOverrideCursor (); 00067 } 00068 // FIXME: too broad... 00069 catch (...) 00070 { 00071 QApplication::restoreOverrideCursor (); 00072 return EXIT_FAILURE; 00073 } 00074 00075 return true; 00076 }
IgStudioDriver * IgNTupleAppSetup::studio | ( | void | ) | const |
Definition at line 83 of file IgNTupleAppSetup.cc.
References m_studio.
Referenced by IgNTupleAppMain::setup().
00084 { return m_studio; }
IgState* IgNTupleAppSetup::m_state [private] |
Definition at line 35 of file IgNTupleAppSetup.h.
Referenced by IgNTupleAppSetup(), setup(), state(), and ~IgNTupleAppSetup().
IgStudioDriver* IgNTupleAppSetup::m_studio [private] |