CMS 3D CMS Logo

Public Member Functions | Private Member Functions | Private Attributes

edm::InputGroup Class Reference

#include <Group.h>

Inheritance diagram for edm::InputGroup:
edm::Group

List of all members.

Public Member Functions

 InputGroup (boost::shared_ptr< ConstBranchDescription > bd)
bool productIsUnavailable () const
void setProduct (std::auto_ptr< EDProduct > prod) const
void setProductUnavailable () const
virtual ~InputGroup ()

Private Member Functions

virtual void checkType_ (EDProduct const &prod) const
virtual GroupData const & groupData () const
virtual GroupDatagroupData ()
virtual void mergeProduct_ (std::auto_ptr< EDProduct > edp) const
virtual void mergeProduct_ (std::auto_ptr< EDProduct > edp, boost::shared_ptr< ProductProvenance > productProvenance)
virtual bool onDemand_ () const
virtual bool productUnavailable_ () const
virtual bool putOrMergeProduct_ () const
virtual void putProduct_ (std::auto_ptr< EDProduct > edp, boost::shared_ptr< ProductProvenance > productProvenance)
virtual void putProduct_ (std::auto_ptr< EDProduct > edp) const
virtual void resetStatus ()
virtual void swap_ (Group &rhs)

Private Attributes

GroupData groupData_
bool productIsUnavailable_

Detailed Description

Definition at line 194 of file Group.h.


Constructor & Destructor Documentation

edm::InputGroup::InputGroup ( boost::shared_ptr< ConstBranchDescription bd) [inline, explicit]

Definition at line 196 of file Group.h.

                                                                      :
        Group(), groupData_(bd), productIsUnavailable_(false) {}
edm::InputGroup::~InputGroup ( ) [virtual]

Definition at line 17 of file Group.cc.

{}

Member Function Documentation

virtual void edm::InputGroup::checkType_ ( EDProduct const &  prod) const [inline, private, virtual]

Implements edm::Group.

Definition at line 218 of file Group.h.

{}
virtual GroupData const& edm::InputGroup::groupData ( ) const [inline, private, virtual]

Implements edm::Group.

Definition at line 222 of file Group.h.

References groupData_.

Referenced by setProduct().

{return groupData_;}
virtual GroupData& edm::InputGroup::groupData ( ) [inline, private, virtual]

Implements edm::Group.

Definition at line 223 of file Group.h.

References groupData_.

{return groupData_;}
void edm::InputGroup::mergeProduct_ ( std::auto_ptr< EDProduct edp,
boost::shared_ptr< ProductProvenance productProvenance 
) [private, virtual]

Implements edm::Group.

Definition at line 80 of file Group.cc.

                                                              {
    assert(0);
  }
void edm::InputGroup::mergeProduct_ ( std::auto_ptr< EDProduct edp) const [private, virtual]

Implements edm::Group.

Definition at line 87 of file Group.cc.

References edm::Group::mergeTheProduct().

                                                            {
    mergeTheProduct(edp);
  }
virtual bool edm::InputGroup::onDemand_ ( ) const [inline, private, virtual]

Implements edm::Group.

Definition at line 220 of file Group.h.

{return false;}
bool edm::InputGroup::productIsUnavailable ( ) const [inline]

Definition at line 204 of file Group.h.

References productIsUnavailable_.

Referenced by productUnavailable_().

bool edm::InputGroup::productUnavailable_ ( ) const [private, virtual]

Implements edm::Group.

Definition at line 160 of file Group.cc.

References edm::Group::product(), productIsUnavailable(), and setProductUnavailable().

                                        {
    if (productIsUnavailable()) {
      return true;
    }
    // If there is a product, we know if it is real or a dummy.
    if (product()) {
      bool unavailable = !(product()->isPresent());
      if (unavailable) {
        setProductUnavailable();
      }
      return unavailable;
    }
    return false;
  }
bool edm::InputGroup::putOrMergeProduct_ ( ) const [private, virtual]

Implements edm::Group.

Definition at line 92 of file Group.cc.

References edm::Group::product().

                                       {
    return (!product());
  }
void edm::InputGroup::putProduct_ ( std::auto_ptr< EDProduct edp,
boost::shared_ptr< ProductProvenance productProvenance 
) [private, virtual]

Implements edm::Group.

Definition at line 69 of file Group.cc.

References edm::Group::product(), edm::Group::provenance(), setProduct(), and edm::Group::setProductProvenance().

                                                              {
    assert(!product());
    assert(!provenance()->productProvenanceResolved());
    setProductProvenance(productProvenance);
    assert(provenance()->productProvenanceResolved());
    setProduct(edp);
  }
void edm::InputGroup::putProduct_ ( std::auto_ptr< EDProduct edp) const [private, virtual]

Implements edm::Group.

Definition at line 97 of file Group.cc.

References edm::Group::product(), and setProduct().

                                                          {
    assert(!product());
    setProduct(edp);
  }
virtual void edm::InputGroup::resetStatus ( ) [inline, private, virtual]

Implements edm::Group.

Definition at line 219 of file Group.h.

References productIsUnavailable_.

void edm::InputGroup::setProduct ( std::auto_ptr< EDProduct prod) const

Definition at line 143 of file Group.cc.

References groupData(), edm::Group::product(), edm::GroupData::product_, and setProductUnavailable().

Referenced by putProduct_().

                                                          {
    assert (!product());
    if (prod.get() == 0 || !prod->isPresent()) {
      setProductUnavailable();
    }
    groupData().product_.reset(prod.release());  // Group takes ownership
  }
void edm::InputGroup::setProductUnavailable ( ) const [inline]

Definition at line 205 of file Group.h.

References productIsUnavailable_.

Referenced by productUnavailable_(), and setProduct().

virtual void edm::InputGroup::swap_ ( Group rhs) [inline, private, virtual]

Implements edm::Group.

Definition at line 208 of file Group.h.

References groupData_, productIsUnavailable_, and edm::Group::swap().

                                     {
        InputGroup& other = dynamic_cast<InputGroup&>(rhs);
        edm::swap(groupData_, other.groupData_);
        std::swap(productIsUnavailable_, other.productIsUnavailable_);
      }

Member Data Documentation

Definition at line 224 of file Group.h.

Referenced by groupData(), and swap_().

bool edm::InputGroup::productIsUnavailable_ [mutable, private]

Definition at line 225 of file Group.h.

Referenced by productIsUnavailable(), resetStatus(), setProductUnavailable(), and swap_().