CMS 3D CMS Logo

CMSSW_4_4_3_patch1/src/PhysicsTools/FWLite/examples/blank.cc

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 
00003 // CMS includes
00004 #include "FWCore/Utilities/interface/InputTag.h"
00005 #include "DataFormats/Common/interface/Handle.h"
00006 #include "DataFormats/PatCandidates/interface/Jet.h"
00007 
00008 #include "PhysicsTools/FWLite/interface/EventContainer.h"
00009 #include "PhysicsTools/FWLite/interface/CommandLineParser.h" 
00010 
00011 // Root includes
00012 #include "TROOT.h"
00013 
00014 using namespace std;
00015 
00017 // ///////////////////// //
00018 // // Main Subroutine // //
00019 // ///////////////////// //
00021 
00022 int main (int argc, char* argv[]) 
00023 {
00025    // ////////////////////////// //
00026    // // Command Line Options // //
00027    // ////////////////////////// //
00029 
00030 
00031    // Tell people what this analysis code does and setup default options.
00032    optutl::CommandLineParser parser ("");
00033 
00035    // Change any defaults or add any new command //
00036    //      line options you would like here.     //
00038 
00039    // Parse the command line arguments
00040    parser.parseArguments (argc, argv);
00041 
00043    // //////////////////////////// //
00044    // // Create Event Container // //
00045    // //////////////////////////// //
00047 
00048    // This object 'event' is used both to get all information from the
00049    // event as well as to store histograms, etc.
00050    fwlite::EventContainer eventCont (parser);
00051 
00053    // ////////////////////////////////// //
00054    // //         Begin Run            // //
00055    // // (e.g., book histograms, etc) // //
00056    // ////////////////////////////////// //
00058 
00059    // Setup a style
00060    gROOT->SetStyle ("Plain");
00061 
00062    // Book those histograms!
00063 
00065    // //////////////// //
00066    // // Event Loop // //
00067    // //////////////// //
00069 
00070    for (eventCont.toBegin(); ! eventCont.atEnd(); ++eventCont) 
00071    {
00073       // Take What We Need From Event //
00075    } // for eventCont
00076 
00077       
00079    // ////////////////// //
00080    // // Clean Up Job // //
00081    // ////////////////// //
00083 
00084    // Histograms will be automatically written to the root file
00085    // specificed by command line options.
00086 
00087    // All done!  Bye bye.
00088    return 0;
00089 }