CMS 3D CMS Logo

Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | Friends

edm::OutputModule Class Reference

#include <OutputModule.h>

Inheritance diagram for edm::OutputModule:
DQMRootOutputModule edm::AsciiOutputModule edm::GetProductCheckerOutputModule edm::PoolOutputModule edm::ProvenanceCheckerOutputModule edm::StreamerOutputModuleBase edm::SubProcess edm::XMLOutputModule FRDEventOutputModule< Consumer >

List of all members.

Public Types

typedef OutputModule ModuleType
typedef OutputWorker WorkerType

Public Member Functions

BranchChildren const & branchChildren () const
boost::array< bool,
NumBranchTypes > const & 
hasNewlyDroppedBranch () const
SelectionsArray const & keptProducts () const
int maxEvents () const
 OutputModule (ParameterSet const &pset)
std::string const & processName () const
int remainingEvents () const
bool selected (BranchDescription const &desc) const
void selectProducts ()
bool wantAllEvents () const
virtual ~OutputModule ()

Static Public Member Functions

static const std::string & baseType ()
static void fillDescription (ParameterSetDescription &desc)
static void fillDescriptions (ConfigurationDescriptions &descriptions)

Protected Member Functions

CurrentProcessingContext const * currentContext () const
ModuleDescription const & description () const
void doBeginJob ()
bool doBeginLuminosityBlock (LuminosityBlockPrincipal const &lbp, EventSetup const &c, CurrentProcessingContext const *cpc)
bool doBeginRun (RunPrincipal const &rp, EventSetup const &c, CurrentProcessingContext const *cpc)
void doEndJob ()
bool doEndLuminosityBlock (LuminosityBlockPrincipal const &lbp, EventSetup const &c, CurrentProcessingContext const *cpc)
bool doEndRun (RunPrincipal const &rp, EventSetup const &c, CurrentProcessingContext const *cpc)
bool doEvent (EventPrincipal const &ep, EventSetup const &c, CurrentProcessingContext const *cpc)
Trig getTriggerResults (EventPrincipal const &ep) const
Trig getTriggerResults (Event const &ep) const
ParameterSetID selectorConfig () const

Private Types

typedef std::map< BranchID,
std::set< ParentageID > > 
BranchParents

Private Member Functions

virtual void beginJob ()
virtual void beginLuminosityBlock (LuminosityBlockPrincipal const &)
virtual void beginRun (RunPrincipal const &)
void configure (OutputModuleDescription const &desc)
void doCloseFile ()
 Tell the OutputModule that is must end the current file.
void doOpenFile (FileBlock const &fb)
virtual void doOpenFile ()
void doPostForkReacquireResources (unsigned int iChildIndex, unsigned int iNumberOfChildren)
void doPreForkReleaseResources ()
void doRespondToCloseInputFile (FileBlock const &fb)
void doRespondToCloseOutputFiles (FileBlock const &fb)
void doRespondToOpenInputFile (FileBlock const &fb)
void doRespondToOpenOutputFiles (FileBlock const &fb)
void doWriteLuminosityBlock (LuminosityBlockPrincipal const &lbp)
void doWriteRun (RunPrincipal const &rp)
virtual void endJob ()
virtual void endLuminosityBlock (LuminosityBlockPrincipal const &)
virtual void endRun (RunPrincipal const &)
void fillDependencyGraph ()
virtual void finishEndFile ()
virtual bool isFileOpen () const
bool limitReached () const
void maybeOpenFile ()
virtual void openFile (FileBlock const &)
virtual void postForkReacquireResources (unsigned int, unsigned int)
virtual void preForkReleaseResources ()
void reallyCloseFile ()
void registerAnyProducts (OutputModule const *, ProductRegistry const *)
virtual void respondToCloseInputFile (FileBlock const &)
virtual void respondToCloseOutputFiles (FileBlock const &)
virtual void respondToOpenInputFile (FileBlock const &)
virtual void respondToOpenOutputFiles (FileBlock const &)
void setModuleDescription (ModuleDescription const &md)
virtual bool shouldWeCloseFile () const
 Ask the OutputModule if we should end the current file.
virtual void startEndFile ()
void updateBranchParents (EventPrincipal const &ep)
std::string workerType () const
virtual void write (EventPrincipal const &e)=0
virtual void writeBranchIDListRegistry ()
virtual void writeBranchMapper ()
virtual void writeFileFormatVersion ()
virtual void writeFileIdentifier ()
virtual void writeIndexIntoFile ()
virtual void writeLuminosityBlock (LuminosityBlockPrincipal const &)=0
virtual void writeParameterSetRegistry ()
virtual void writeParentageRegistry ()
virtual void writeProcessConfigurationRegistry ()
virtual void writeProcessHistoryRegistry ()
virtual void writeProductDependencies ()
virtual void writeProductDescriptionRegistry ()
virtual void writeRun (RunPrincipal const &)=0

Private Attributes

BranchChildren branchChildren_
BranchParents branchParents_
CurrentProcessingContext const * current_context_
GroupSelector groupSelector_
GroupSelectorRules groupSelectorRules_
boost::array< bool,
NumBranchTypes > 
hasNewlyDroppedBranch_
SelectionsArray keptProducts_
int maxEvents_
ModuleDescription moduleDescription_
std::string process_name_
bool prodsValid_
int remainingEvents_
ParameterSetID selector_config_id_
detail::CachedProducts selectors_
bool wantAllEvents_

Friends

class OutputWorker
class WorkerT

Detailed Description

Definition at line 34 of file OutputModule.h.


Member Typedef Documentation

typedef std::map<BranchID, std::set<ParentageID> > edm::OutputModule::BranchParents [private]

Definition at line 138 of file OutputModule.h.

Definition at line 38 of file OutputModule.h.

Definition at line 39 of file OutputModule.h.


Constructor & Destructor Documentation

edm::OutputModule::OutputModule ( ParameterSet const &  pset) [explicit]

Definition at line 111 of file OutputModule.cc.

References edm::ParameterSet::empty(), edm::getAllTriggerNames(), edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameterSet(), hasNewlyDroppedBranch_, i, edm::ParameterSet::id(), process_name_, edm::ParameterSet::registerIt(), selector_config_id_, selectors_, edm::detail::CachedProducts::setup(), edm::detail::CachedProducts::setupDefault(), and wantAllEvents_.

                                                     :
    maxEvents_(-1),
    remainingEvents_(maxEvents_),
    keptProducts_(),
    hasNewlyDroppedBranch_(),
    process_name_(),
    groupSelectorRules_(pset, "outputCommands", "OutputModule"),
    groupSelector_(),
    moduleDescription_(),
    current_context_(0),
    prodsValid_(false),
    wantAllEvents_(false),
    selectors_(),
    selector_config_id_(),
    branchParents_(),
    branchChildren_() {

    hasNewlyDroppedBranch_.assign(false);

    Service<service::TriggerNamesService> tns;
    process_name_ = tns->getProcessName();

    ParameterSet selectevents =
      pset.getUntrackedParameterSet("SelectEvents", ParameterSet());

    selectevents.registerIt(); // Just in case this PSet is not registered

    selector_config_id_ = selectevents.id();
    // If selectevents is an emtpy ParameterSet, then we are to write
    // all events, or one which contains a vstrig 'SelectEvents' that
    // is empty, we are to write all events. We have no need for any
    // EventSelectors.
    if(selectevents.empty()) {
        wantAllEvents_ = true;
        selectors_.setupDefault(getAllTriggerNames());
        return;
    }

    std::vector<std::string> path_specs =
      selectevents.getParameter<std::vector<std::string> >("SelectEvents");

    if(path_specs.empty()) {
        wantAllEvents_ = true;
        selectors_.setupDefault(getAllTriggerNames());
        return;
    }

    // If we get here, we have the possibility of having to deal with
    // path_specs that look at more than one process.
    std::vector<parsed_path_spec_t> parsed_paths(path_specs.size());
    for(size_t i = 0; i < path_specs.size(); ++i) {
      parse_path_spec(path_specs[i], parsed_paths[i]);
    }
    selectors_.setup(parsed_paths, getAllTriggerNames(), process_name_);
  }
edm::OutputModule::~OutputModule ( ) [virtual]

Definition at line 203 of file OutputModule.cc.

{ }

Member Function Documentation

const std::string & edm::OutputModule::baseType ( ) [static]

Definition at line 425 of file OutputModule.cc.

References edm::kBaseType().

                         {
    return kBaseType;
  }
virtual void edm::OutputModule::beginJob ( void  ) [inline, private, virtual]

Reimplemented in edm::SubProcess, edm::PoolOutputModule, and edm::StreamerOutputModuleBase.

Definition at line 177 of file OutputModule.h.

Referenced by doBeginJob().

{}
virtual void edm::OutputModule::beginLuminosityBlock ( LuminosityBlockPrincipal const &  ) [inline, private, virtual]

Reimplemented in edm::SubProcess.

Definition at line 182 of file OutputModule.h.

Referenced by doBeginLuminosityBlock().

{}
virtual void edm::OutputModule::beginRun ( RunPrincipal const &  ) [inline, private, virtual]
BranchChildren const& edm::OutputModule::branchChildren ( ) const [inline]

Definition at line 62 of file OutputModule.h.

References branchChildren_.

Referenced by edm::RootOutputFile::writeProductDependencies().

{return branchChildren_;}
void edm::OutputModule::configure ( OutputModuleDescription const &  desc) [private]

Definition at line 167 of file OutputModule.cc.

References maxEvents_, edm::OutputModuleDescription::maxEvents_, and remainingEvents_.

Referenced by edm::OutputWorker::configure().

                                                                  {
    remainingEvents_ = maxEvents_ = desc.maxEvents_;
  }
CurrentProcessingContext const * edm::OutputModule::currentContext ( ) const [protected]

Definition at line 396 of file OutputModule.cc.

References current_context_.

                                     {
    return current_context_;
  }
ModuleDescription const & edm::OutputModule::description ( ) const [protected]

Definition at line 401 of file OutputModule.cc.

References moduleDescription_.

Referenced by edm::StreamerOutputModuleBase::serializeRegistry().

                                  {
    return moduleDescription_;
  }
void edm::OutputModule::doBeginJob ( ) [protected]

Definition at line 205 of file OutputModule.cc.

References beginJob(), and selectProducts().

                                {
    selectProducts();
    this->beginJob();
  }
bool edm::OutputModule::doBeginLuminosityBlock ( LuminosityBlockPrincipal const &  lbp,
EventSetup const &  c,
CurrentProcessingContext const *  cpc 
) [protected]

Definition at line 314 of file OutputModule.cc.

References beginLuminosityBlock(), current_context_, and FDEBUG.

                                                                                 {
    detail::CPCSentry sentry(current_context_, cpc);
    FDEBUG(2) << "beginLuminosityBlock called\n";
    beginLuminosityBlock(lbp);
    return true;
  }
bool edm::OutputModule::doBeginRun ( RunPrincipal const &  rp,
EventSetup const &  c,
CurrentProcessingContext const *  cpc 
) [protected]

Definition at line 288 of file OutputModule.cc.

References beginRun(), current_context_, and FDEBUG.

                                                                     {
    detail::CPCSentry sentry(current_context_, cpc);
    FDEBUG(2) << "beginRun called\n";
    beginRun(rp);
    return true;
  }
void edm::OutputModule::doCloseFile ( ) [private]

Tell the OutputModule that is must end the current file.

Definition at line 372 of file OutputModule.cc.

References isFileOpen(), and reallyCloseFile().

Referenced by edm::OutputWorker::closeFile().

void edm::OutputModule::doEndJob ( ) [protected]

Definition at line 210 of file OutputModule.cc.

References endJob().

Referenced by edm::EventProcessor::endJob().

                              {
    endJob();
  }
bool edm::OutputModule::doEndLuminosityBlock ( LuminosityBlockPrincipal const &  lbp,
EventSetup const &  c,
CurrentProcessingContext const *  cpc 
) [protected]

Definition at line 324 of file OutputModule.cc.

References current_context_, endLuminosityBlock(), and FDEBUG.

                                                                               {
    detail::CPCSentry sentry(current_context_, cpc);
    FDEBUG(2) << "endLuminosityBlock called\n";
    endLuminosityBlock(lbp);
    return true;
  }
bool edm::OutputModule::doEndRun ( RunPrincipal const &  rp,
EventSetup const &  c,
CurrentProcessingContext const *  cpc 
) [protected]

Definition at line 298 of file OutputModule.cc.

References current_context_, endRun(), and FDEBUG.

                                                                   {
    detail::CPCSentry sentry(current_context_, cpc);
    FDEBUG(2) << "endRun called\n";
    endRun(rp);
    return true;
  }
bool edm::OutputModule::doEvent ( EventPrincipal const &  ep,
EventSetup const &  c,
CurrentProcessingContext const *  cpc 
) [protected]

Definition at line 247 of file OutputModule.cc.

References current_context_, FDEBUG, moduleDescription_, prodsValid_, remainingEvents_, selectors_, updateBranchParents(), wantAllEvents_, edm::detail::CachedProducts::wantEvent(), and write().

                                                             {
    detail::CPCSentry sentry(current_context_, cpc);
    PVSentry          products_sentry(selectors_, prodsValid_);

    FDEBUG(2) << "writeEvent called\n";

    if(!wantAllEvents_) {
      // use module description and const_cast unless interface to
      // event is changed to just take a const EventPrincipal
      Event e(const_cast<EventPrincipal&>(ep), moduleDescription_);
      if(!selectors_.wantEvent(e)) {
        return true;
      }
    }
    write(ep);
    updateBranchParents(ep);
    if(remainingEvents_ > 0) {
      --remainingEvents_;
    }
    return true;
  }
void edm::OutputModule::doOpenFile ( FileBlock const &  fb) [private]

Definition at line 338 of file OutputModule.cc.

References openFile().

Referenced by edm::OutputWorker::openFile().

                                                   {
    openFile(fb);
  }
virtual void edm::OutputModule::doOpenFile ( ) [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 195 of file OutputModule.h.

Referenced by maybeOpenFile().

{ }
void edm::OutputModule::doPostForkReacquireResources ( unsigned int  iChildIndex,
unsigned int  iNumberOfChildren 
) [private]

Definition at line 364 of file OutputModule.cc.

References postForkReacquireResources().

                                                                                                     {
    postForkReacquireResources(iChildIndex, iNumberOfChildren);
  }
void edm::OutputModule::doPreForkReleaseResources ( ) [private]

Definition at line 359 of file OutputModule.cc.

References preForkReleaseResources().

void edm::OutputModule::doRespondToCloseInputFile ( FileBlock const &  fb) [private]

Definition at line 346 of file OutputModule.cc.

References respondToCloseInputFile().

void edm::OutputModule::doRespondToCloseOutputFiles ( FileBlock const &  fb) [private]

Definition at line 354 of file OutputModule.cc.

References respondToCloseOutputFiles().

void edm::OutputModule::doRespondToOpenInputFile ( FileBlock const &  fb) [private]

Definition at line 342 of file OutputModule.cc.

References respondToOpenInputFile().

void edm::OutputModule::doRespondToOpenOutputFiles ( FileBlock const &  fb) [private]

Definition at line 350 of file OutputModule.cc.

References respondToOpenOutputFiles().

void edm::OutputModule::doWriteLuminosityBlock ( LuminosityBlockPrincipal const &  lbp) [private]

Definition at line 333 of file OutputModule.cc.

References FDEBUG, and writeLuminosityBlock().

Referenced by edm::OutputWorker::writeLumi().

                                                                               {
    FDEBUG(2) << "writeLuminosityBlock called\n";
    writeLuminosityBlock(lbp);
  }
void edm::OutputModule::doWriteRun ( RunPrincipal const &  rp) [private]

Definition at line 308 of file OutputModule.cc.

References FDEBUG, and writeRun().

Referenced by edm::OutputWorker::writeRun().

                                                 {
    FDEBUG(2) << "writeRun called\n";
    writeRun(rp);
  }
virtual void edm::OutputModule::endJob ( void  ) [inline, private, virtual]

Reimplemented in edm::SubProcess, and edm::StreamerOutputModuleBase.

Definition at line 178 of file OutputModule.h.

Referenced by doEndJob().

{}
virtual void edm::OutputModule::endLuminosityBlock ( LuminosityBlockPrincipal const &  ) [inline, private, virtual]

Reimplemented in edm::SubProcess.

Definition at line 183 of file OutputModule.h.

Referenced by doEndLuminosityBlock().

{}
virtual void edm::OutputModule::endRun ( RunPrincipal const &  ) [inline, private, virtual]

Reimplemented in edm::SubProcess, FRDEventOutputModule< Consumer >, and edm::StreamerOutputModuleBase.

Definition at line 180 of file OutputModule.h.

Referenced by doEndRun().

{}
void edm::OutputModule::fillDependencyGraph ( ) [private]

Definition at line 445 of file OutputModule.cc.

References branchChildren_, branchParents_, i, edm::BranchChildren::insertChild(), edm::detail::ThreadSafeRegistry< KEY, T, E >::instance(), j, parents, and edm::Parentage::parents().

Referenced by reallyCloseFile().

                                    {
    for(BranchParents::const_iterator i = branchParents_.begin(), iEnd = branchParents_.end();
        i != iEnd; ++i) {
      BranchID const& child = i->first;
      std::set<ParentageID> const& eIds = i->second;
      for(std::set<ParentageID>::const_iterator it = eIds.begin(), itEnd = eIds.end();
          it != itEnd; ++it) {
        Parentage entryDesc;
        ParentageRegistry::instance()->getMapped(*it, entryDesc);
        std::vector<BranchID> const& parents = entryDesc.parents();
        for(std::vector<BranchID>::const_iterator j = parents.begin(), jEnd = parents.end();
          j != jEnd; ++j) {
          branchChildren_.insertChild(*j, child);
        }
      }
    }
  }
void edm::OutputModule::fillDescription ( ParameterSetDescription desc) [static]
void edm::OutputModule::fillDescriptions ( ConfigurationDescriptions descriptions) [static]
virtual void edm::OutputModule::finishEndFile ( ) [inline, private, virtual]

Reimplemented in DQMRootOutputModule, and edm::PoolOutputModule.

Definition at line 221 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
Trig edm::OutputModule::getTriggerResults ( EventPrincipal const &  ep) const [protected]

Definition at line 219 of file OutputModule.cc.

References current_context_, getTriggerResults(), and edm::CurrentProcessingContext::moduleDescription().

                                                                     {
    // This is bad, because we're returning handles into an Event that
    // is destructed before the return. It might not fail, because the
    // actual EventPrincipal is not destroyed, but it still needs to
    // be cleaned up.
    Event ev(const_cast<EventPrincipal&>(ep),
             *current_context_->moduleDescription());
    return getTriggerResults(ev);
  }
Trig edm::OutputModule::getTriggerResults ( Event const &  ep) const [protected]

Definition at line 215 of file OutputModule.cc.

References edm::detail::CachedProducts::getOneTriggerResults(), and selectors_.

Referenced by getTriggerResults(), and edm::StreamerOutputModuleBase::setHltMask().

                                                            {
    return selectors_.getOneTriggerResults(ev);
  }
boost::array<bool, NumBranchTypes> const& edm::OutputModule::hasNewlyDroppedBranch ( ) const [inline]

Definition at line 56 of file OutputModule.h.

References hasNewlyDroppedBranch_.

Referenced by edm::RootOutputFile::beginInputFile().

virtual bool edm::OutputModule::isFileOpen ( ) const [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 193 of file OutputModule.h.

Referenced by doCloseFile(), and maybeOpenFile().

{ return true; }
SelectionsArray const& edm::OutputModule::keptProducts ( ) const [inline]
bool edm::OutputModule::limitReached ( ) const [inline, private]

Definition at line 204 of file OutputModule.h.

References remainingEvents_.

Referenced by edm::OutputWorker::limitReached().

{return remainingEvents_ == 0;}
int edm::OutputModule::maxEvents ( ) const [inline]

Accessor for maximum number of events to be written. -1 is used for unlimited.

Definition at line 45 of file OutputModule.h.

References maxEvents_.

Referenced by edm::SubProcess::SubProcess().

{return maxEvents_;}
void edm::OutputModule::maybeOpenFile ( ) [private]

Tell the OutputModule to open an output file, if one is not already open.

Definition at line 368 of file OutputModule.cc.

References doOpenFile(), and isFileOpen().

Referenced by edm::OutputWorker::openNewFileIfNeeded().

                                   {
    if(!isFileOpen()) doOpenFile();
  }
virtual void edm::OutputModule::openFile ( FileBlock const &  ) [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 185 of file OutputModule.h.

Referenced by doOpenFile().

{}
virtual void edm::OutputModule::postForkReacquireResources ( unsigned int  ,
unsigned int   
) [inline, private, virtual]

Reimplemented in edm::SubProcess, and edm::PoolOutputModule.

Definition at line 191 of file OutputModule.h.

Referenced by doPostForkReacquireResources().

{}
virtual void edm::OutputModule::preForkReleaseResources ( ) [inline, private, virtual]

Reimplemented in edm::SubProcess.

Definition at line 190 of file OutputModule.h.

Referenced by doPreForkReleaseResources().

{}
std::string const& edm::OutputModule::processName ( ) const [inline]
void edm::OutputModule::reallyCloseFile ( ) [private]
void edm::OutputModule::registerAnyProducts ( OutputModule const *  ,
ProductRegistry const *   
) [inline, private]

Definition at line 171 of file OutputModule.h.

{}
int edm::OutputModule::remainingEvents ( ) const [inline]

Accessor for remaining number of events to be written. -1 is used for unlimited.

Definition at line 49 of file OutputModule.h.

References remainingEvents_.

Referenced by edm::PoolOutputModule::beginInputFile().

{return remainingEvents_;}
virtual void edm::OutputModule::respondToCloseInputFile ( FileBlock const &  ) [inline, private, virtual]

Reimplemented in edm::SubProcess, and edm::PoolOutputModule.

Definition at line 187 of file OutputModule.h.

Referenced by doRespondToCloseInputFile().

{}
virtual void edm::OutputModule::respondToCloseOutputFiles ( FileBlock const &  ) [inline, private, virtual]

Reimplemented in edm::SubProcess.

Definition at line 189 of file OutputModule.h.

Referenced by doRespondToCloseOutputFiles().

{}
virtual void edm::OutputModule::respondToOpenInputFile ( FileBlock const &  ) [inline, private, virtual]

Reimplemented in edm::SubProcess, and edm::PoolOutputModule.

Definition at line 186 of file OutputModule.h.

Referenced by doRespondToOpenInputFile().

{}
virtual void edm::OutputModule::respondToOpenOutputFiles ( FileBlock const &  ) [inline, private, virtual]

Reimplemented in edm::SubProcess.

Definition at line 188 of file OutputModule.h.

Referenced by doRespondToOpenOutputFiles().

{}
bool edm::OutputModule::selected ( BranchDescription const &  desc) const

Definition at line 406 of file OutputModule.cc.

References groupSelector_, and edm::GroupSelector::selected().

Referenced by selectProducts(), and edm::AsciiOutputModule::write().

                                                            {
    return groupSelector_.selected(desc);
  }
ParameterSetID edm::OutputModule::selectorConfig ( ) const [inline, protected]
void edm::OutputModule::selectProducts ( )

Definition at line 171 of file OutputModule.cc.

References edm::BranchDescription::branchType(), end, edm::getAllBranchDescriptions(), groupSelector_, groupSelectorRules_, hasNewlyDroppedBranch_, edm::GroupSelector::initialize(), edm::GroupSelector::initialized(), keptProducts_, edm::BranchDescription::present(), edm::BranchDescription::produced(), selected(), and edm::BranchDescription::transient().

Referenced by doBeginJob().

                                    {
    if(groupSelector_.initialized()) return;
    groupSelector_.initialize(groupSelectorRules_, getAllBranchDescriptions());
    Service<ConstProductRegistry> reg;

    // TODO: See if we can collapse keptProducts_ and groupSelector_ into a
    // single object. See the notes in the header for GroupSelector
    // for more information.

    ProductRegistry::ProductList::const_iterator it  =
      reg->productList().begin();
    ProductRegistry::ProductList::const_iterator end =
      reg->productList().end();

    for(; it != end; ++it) {
      BranchDescription const& desc = it->second;
      if(desc.transient()) {
        // if the class of the branch is marked transient, output nothing
      } else if(!desc.present() && !desc.produced()) {
        // else if the branch containing the product has been previously dropped,
        // output nothing
      } else if(selected(desc)) {
        // else if the branch has been selected, put it in the list of selected branches
        keptProducts_[desc.branchType()].push_back(&desc);
      } else {
        // otherwise, output nothing,
        // and mark the fact that there is a newly dropped branch of this type.
        hasNewlyDroppedBranch_[desc.branchType()] = true;
      }
    }
  }
void edm::OutputModule::setModuleDescription ( ModuleDescription const &  md) [inline, private]

Definition at line 197 of file OutputModule.h.

References moduleDescription_.

                                                           {
      moduleDescription_ = md;
    }
virtual bool edm::OutputModule::shouldWeCloseFile ( ) const [inline, private, virtual]

Ask the OutputModule if we should end the current file.

Reimplemented in edm::PoolOutputModule, and edm::TimeoutPoolOutputModule.

Definition at line 174 of file OutputModule.h.

Referenced by edm::OutputWorker::shouldWeCloseFile().

{return false;}
virtual void edm::OutputModule::startEndFile ( ) [inline, private, virtual]

Reimplemented in DQMRootOutputModule, and edm::PoolOutputModule.

Definition at line 209 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
void edm::OutputModule::updateBranchParents ( EventPrincipal const &  ep) [private]

Definition at line 430 of file OutputModule.cc.

References edm::Principal::begin(), branchChildren_, branchParents_, edm::Principal::end(), i, and edm::BranchChildren::insertEmpty().

Referenced by doEvent().

                                                            {
    for(EventPrincipal::const_iterator i = ep.begin(), iEnd = ep.end(); i != iEnd; ++i) {
      if((*i) && (*i)->productProvenancePtr() != 0) {
        BranchID const& bid = (*i)->branchDescription().branchID();
        BranchParents::iterator it = branchParents_.find(bid);
        if(it == branchParents_.end()) {
          it = branchParents_.insert(std::make_pair(bid, std::set<ParentageID>())).first;
        }
        it->second.insert((*i)->productProvenancePtr()->parentageID());
        branchChildren_.insertEmpty(bid);
      }
    }
  }
bool edm::OutputModule::wantAllEvents ( ) const [inline]
std::string edm::OutputModule::workerType ( ) const [inline, private]

Definition at line 157 of file OutputModule.h.

{return "OutputWorker";}
virtual void edm::OutputModule::write ( EventPrincipal const &  e) [private, pure virtual]
virtual void edm::OutputModule::writeBranchIDListRegistry ( ) [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 216 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
virtual void edm::OutputModule::writeBranchMapper ( ) [inline, private, virtual]

Definition at line 220 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
virtual void edm::OutputModule::writeFileFormatVersion ( ) [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 210 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
virtual void edm::OutputModule::writeFileIdentifier ( ) [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 211 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
virtual void edm::OutputModule::writeIndexIntoFile ( ) [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 212 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
virtual void edm::OutputModule::writeLuminosityBlock ( LuminosityBlockPrincipal const &  ) [private, pure virtual]
virtual void edm::OutputModule::writeParameterSetRegistry ( ) [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 215 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
virtual void edm::OutputModule::writeParentageRegistry ( ) [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 217 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
virtual void edm::OutputModule::writeProcessConfigurationRegistry ( ) [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 213 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
virtual void edm::OutputModule::writeProcessHistoryRegistry ( ) [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 214 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
virtual void edm::OutputModule::writeProductDependencies ( ) [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 219 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
virtual void edm::OutputModule::writeProductDescriptionRegistry ( ) [inline, private, virtual]

Reimplemented in edm::PoolOutputModule.

Definition at line 218 of file OutputModule.h.

Referenced by reallyCloseFile().

{}
virtual void edm::OutputModule::writeRun ( RunPrincipal const &  ) [private, pure virtual]

Friends And Related Function Documentation

friend class OutputWorker [friend]

Definition at line 37 of file OutputModule.h.

friend class WorkerT [friend]

Definition at line 36 of file OutputModule.h.


Member Data Documentation

Definition at line 139 of file OutputModule.h.

Referenced by fillDependencyGraph(), reallyCloseFile(), and updateBranchParents().

Definition at line 122 of file OutputModule.h.

Referenced by selected(), and selectProducts().

Definition at line 121 of file OutputModule.h.

Referenced by selectProducts().

boost::array<bool, NumBranchTypes> edm::OutputModule::hasNewlyDroppedBranch_ [private]

Definition at line 118 of file OutputModule.h.

Referenced by hasNewlyDroppedBranch(), OutputModule(), and selectProducts().

Definition at line 117 of file OutputModule.h.

Referenced by keptProducts(), and selectProducts().

Definition at line 99 of file OutputModule.h.

Referenced by configure(), and maxEvents().

Definition at line 123 of file OutputModule.h.

Referenced by description(), doEvent(), and setModuleDescription().

std::string edm::OutputModule::process_name_ [private]

Definition at line 120 of file OutputModule.h.

Referenced by OutputModule(), and processName().

bool edm::OutputModule::prodsValid_ [mutable, private]

Definition at line 130 of file OutputModule.h.

Referenced by doEvent().

Definition at line 100 of file OutputModule.h.

Referenced by configure(), doEvent(), limitReached(), and remainingEvents().

Definition at line 136 of file OutputModule.h.

Referenced by OutputModule(), and selectorConfig().

Definition at line 133 of file OutputModule.h.

Referenced by doEvent(), getTriggerResults(), and OutputModule().

Definition at line 132 of file OutputModule.h.

Referenced by doEvent(), OutputModule(), and wantAllEvents().