CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Classes | Typedefs | Functions
edm::detail Namespace Reference

Classes

class  CachedProducts
 
class  CPCSentry
 
struct  empty
 
struct  FillViewRefTypeTrait
 
struct  FillViewRefTypeTrait< RefVector< C, T, F >, T1, F1 >
 
struct  GetProduct
 
struct  GetProduct< RefVector< C, T, F > >
 
struct  has_donotrecordparents
 
struct  has_isProductEqual_function
 
struct  has_mergeProduct_function
 
struct  has_postinsert
 
struct  has_swap_function
 
struct  isProductEqual_function
 
struct  mergeProduct_function
 
class  NamedEventSelector
 
struct  postinsert_function
 
struct  swap_function
 
class  ThreadSafeRegistry
 

Typedefs

typedef edm::Handle
< edm::TriggerResults
handle_t
 
typedef detail::NamedEventSelector NES
 
typedef char(& no_tag )[1]
 
typedef char(& yes_tag )[2]
 

Functions

void _throw_range (det_id_type i)
 
template<typename T >
no_tag has_isProductEqual_helper (...)
 
template<typename T >
yes_tag has_isProductEqual_helper (isProductEqual_function< T,&T::isProductEqual > *dummy)
 
template<typename T >
no_tag has_mergeProduct_helper (...)
 
template<typename T >
yes_tag has_mergeProduct_helper (mergeProduct_function< T,&T::mergeProduct > *dummy)
 
template<typename T >
no_tag has_postinsert_helper (...)
 
template<typename T >
yes_tag has_postinsert_helper (postinsert_function< T,&T::post_insert > *p)
 
template<typename T >
no_tag has_swap_helper (...)
 
template<typename T >
yes_tag has_swap_helper (swap_function< T,&T::swap > *dummy)
 
std::string const & InvalidHash ()
 
bool isnan (float x)
 
bool isnan (double x)
 
bool isnan (long double x)
 
template<typename KEY , typename T , typename E >
std::ostream & operator<< (std::ostream &os, ThreadSafeRegistry< KEY, T, E > const &reg)
 
template<typename COLLECTION >
void reallyfillPtrVector (COLLECTION const &coll, std::type_info const &iToType, std::vector< unsigned long > const &iIndicies, std::vector< void const * > &oPtr)
 
template<class COLLECTION >
void reallyFillView (COLLECTION const &coll, ProductID const &id, std::vector< void const * > &ptrs, helper_vector &helpers)
 
template<typename COLLECTION >
void reallySetPtr (COLLECTION const &coll, std::type_info const &iToType, unsigned long iIndex, void const *&oPtr)
 

Typedef Documentation

Definition at line 24 of file CachedProducts.h.

Definition at line 12 of file CachedProducts.cc.

typedef char(& edm::detail::no_tag

Definition at line 248 of file Wrapper.h.

typedef char(& edm::detail::yes_tag

Definition at line 249 of file Wrapper.h.

Function Documentation

void edm::detail::_throw_range ( det_id_type  i)
inline

Definition at line 71 of file DetSetVector.h.

References edm::errors::InvalidReference, and edm::Exception::throwThis().

Referenced by edm::DetSetVector< T >::operator[]().

71  {
72  Exception::throwThis(errors::InvalidReference,
73  "DetSetVector::operator[] called with index not in collection;\nindex value: ", i);
74  }
int i
Definition: DBlmapReader.cc:9
template<typename T >
no_tag edm::detail::has_isProductEqual_helper (   ...)
template<typename T >
yes_tag edm::detail::has_isProductEqual_helper ( isProductEqual_function< T,&T::isProductEqual > *  dummy)
template<typename T >
no_tag edm::detail::has_mergeProduct_helper (   ...)
template<typename T >
yes_tag edm::detail::has_mergeProduct_helper ( mergeProduct_function< T,&T::mergeProduct > *  dummy)
template<typename T >
no_tag edm::detail::has_postinsert_helper (   ...)
template<typename T >
yes_tag edm::detail::has_postinsert_helper ( postinsert_function< T,&T::post_insert > *  p)
template<typename T >
no_tag edm::detail::has_swap_helper (   ...)
template<typename T >
yes_tag edm::detail::has_swap_helper ( swap_function< T,&T::swap > *  dummy)
std::string const & edm::detail::InvalidHash ( )
bool edm::detail::isnan ( float  x)
inline

Definition at line 13 of file math.h.

References GET_FLOAT_WORD.

Referenced by PrimaryVertexAnalyzer4PU::analyzeVertexCollection(), plotscripts::corrections2D(), SiPixelGainCalibrationAnalysis::doFits(), edm::isnan(), and SeedGeneratorForCosmics::seeds().

14  {
15  u_int32_t wx;
16 
17  GET_FLOAT_WORD (wx, x);
18  wx &= 0x7fffffff;
19  return (bool)(wx > 0x7f800000);
20  }
#define GET_FLOAT_WORD(i, d)
Definition: math_private.h:58
Definition: DDAxes.h:10
bool edm::detail::isnan ( double  x)
inline

Definition at line 22 of file math.h.

References EXTRACT_WORDS.

23  {
24  u_int32_t hx, lx;
25 
26  EXTRACT_WORDS (hx, lx, x);
27  lx |= hx & 0xfffff;
28  hx &= 0x7ff00000;
29  return (bool)(hx == 0x7ff00000) && (lx != 0);
30  }
#define EXTRACT_WORDS(ix0, ix1, d)
Definition: math_private.h:66
Definition: DDAxes.h:10
bool edm::detail::isnan ( long double  x)
inline

Definition at line 32 of file math.h.

References GET_LDOUBLE_WORDS.

33  {
34  u_int32_t ex, hx, lx;
35 
36  GET_LDOUBLE_WORDS (ex, hx, lx, x);
37  ex &= 0x7fff;
38  return (bool)((ex == 0x7fff) && ((hx & 0x7fffffff) | lx));
39  }
Definition: DDAxes.h:10
#define GET_LDOUBLE_WORDS(exp, ix0, ix1, d)
Definition: math_private.h:75
template<typename KEY , typename T , typename E >
std::ostream& edm::detail::operator<< ( std::ostream &  os,
ThreadSafeRegistry< KEY, T, E > const &  reg 
)
inline

Definition at line 118 of file ThreadSafeRegistry.h.

118  {
119  reg.print(os);
120  return os;
121  }
template<typename COLLECTION >
void edm::detail::reallyfillPtrVector ( COLLECTION const &  coll,
std::type_info const &  iToType,
std::vector< unsigned long > const &  iIndicies,
std::vector< void const * > &  oPtr 
)

Definition at line 38 of file fillPtrVector.h.

References edm::detail::GetProduct< COLLECTION >::address(), edm::errors::LogicError, mergeVDriftHistosByStation::name, edm::TypeWithDict::pointerToBaseType(), and edm::Exception::throwThis().

Referenced by edm::fillPtrVector(), edm::OwnArray< T, MAX_SIZE, P >::fillPtrVector(), edm::SortedCollection< T, SORT >::fillPtrVector(), and edm::OwnVector< T, P >::fillPtrVector().

42  {
43  typedef COLLECTION product_type;
44  typedef typename GetProduct<product_type>::element_type element_type;
45  typedef typename product_type::const_iterator iter;
46  typedef typename product_type::size_type size_type;
47 
48  oPtr.reserve(iIndicies.size());
49  if(iToType == typeid(element_type)) {
50  for(std::vector<unsigned long>::const_iterator itIndex = iIndicies.begin(),
51  itEnd = iIndicies.end();
52  itIndex != itEnd;
53  ++itIndex) {
54  iter it = coll.begin();
55  std::advance(it, *itIndex);
56  element_type const* address = GetProduct<product_type>::address(it);
57  oPtr.push_back(address);
58  }
59  } else {
60  static TypeWithDict const s_type(typeid(element_type));
61 
62  for(std::vector<unsigned long>::const_iterator itIndex = iIndicies.begin(),
63  itEnd = iIndicies.end();
64  itIndex != itEnd;
65  ++itIndex) {
66  iter it = coll.begin();
67  std::advance(it, *itIndex);
68  element_type const* address = GetProduct<product_type>::address(it);
69  void const* ptr = TypeWithDict(iToType).pointerToBaseType(address, s_type);
70  if(0 != ptr) {
71  oPtr.push_back(ptr);
72  } else {
73  Exception::throwThis(errors::LogicError,
74  "TypeConversionError "
75  "edm::PtrVector<> : unable to convert type ",
76  typeid(element_type).name(),
77  " to ",
78  iToType.name(),
79  "\n");
80  }
81  }
82  }
83  }
char * address
Definition: mlp_lapack.h:14
uint16_t size_type
JetCorrectorParametersCollection coll
Definition: classes.h:16
template<class COLLECTION >
void edm::detail::reallyFillView ( COLLECTION const &  coll,
ProductID const &  id,
std::vector< void const * > &  ptrs,
helper_vector &  helpers 
)

Definition at line 49 of file FillView.h.

References edm::detail::GetProduct< COLLECTION >::address(), alignCSCRings::e, h, i, combine::key, edm::reftobase::RefVectorHolderBase::push_back(), edm::reftobase::RefVectorHolderBase::reserve(), edm::reftobase::RefVectorHolderBase::size(), and relativeConstraints::value.

Referenced by edm::fillView(), edm::AssociationVector< KeyRefProd, CVal, KeyRef, SizeType, KeyReferenceHelper >::fillView(), edm::SortedCollection< T, SORT >::fillView(), edm::DetSetVector< T >::fillView(), edm::reftobase::RefVectorHolder< REFV >::reallyFillView(), edm::reftobase::RefVectorHolderDoFillView< REFV >::reallyFillView(), and edm::RefToBaseProd< T >::RefToBaseProd().

53  {
54  typedef COLLECTION product_type;
55  typedef typename GetProduct<product_type>::element_type element_type;
56  typedef typename product_type::const_iterator iter;
57  typedef typename product_type::size_type size_type;
58  typedef typename FillViewRefTypeTrait<product_type,
60  typename refhelper::FindTrait<product_type,
61  typename refhelper::ValueTrait<product_type>::value>::value>::type ref_type;
62  typedef reftobase::RefHolder<ref_type> holder_type;
63 
64  ptrs.reserve(ptrs.size() + coll.size());
65  helpers.reserve(helpers.size() + coll.size());
66  size_type key = 0;
67  for (iter i = coll.begin(), e = coll.end(); i!=e; ++i, ++key) {
68  element_type const* address = GetProduct<product_type>::address(i);
69  ptrs.push_back(address);
70  ref_type ref(id, address, key, GetProduct<product_type>::product(coll) );
71  holder_type h(ref);
72  helpers.push_back(&h);
73  }
74  }
type
Definition: HCALResponse.h:21
int i
Definition: DBlmapReader.cc:9
char * address
Definition: mlp_lapack.h:14
uint16_t size_type
JetCorrectorParametersCollection coll
Definition: classes.h:16
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
Definition: Activities.doc:4
list key
Definition: combine.py:13
template<typename COLLECTION >
void edm::detail::reallySetPtr ( COLLECTION const &  coll,
std::type_info const &  iToType,
unsigned long  iIndex,
void const *&  oPtr 
)

Definition at line 37 of file setPtr.h.

References edm::detail::GetProduct< COLLECTION >::address(), edm::errors::LogicError, mergeVDriftHistosByStation::name, edm::TypeWithDict::pointerToBaseType(), and edm::Exception::throwThis().

Referenced by edm::setPtr(), and edm::SortedCollection< T, SORT >::setPtr().

40  {
41  typedef COLLECTION product_type;
42  typedef typename GetProduct<product_type>::element_type element_type;
43  typedef typename product_type::const_iterator iter;
44  typedef typename product_type::size_type size_type;
45 
46  if(iToType == typeid(element_type)) {
47  iter it = coll.begin();
48  std::advance(it,iIndex);
49  element_type const* address = GetProduct<product_type>::address( it );
50  oPtr = address;
51  } else {
52  static TypeWithDict const s_type(TypeWithDict(typeid(element_type)));
53 
54  iter it = coll.begin();
55  std::advance(it,iIndex);
56  element_type const* address = GetProduct<product_type>::address( it );
57 
58  oPtr = TypeWithDict(iToType).pointerToBaseType(address, s_type);
59 
60  if(0 == oPtr) {
61  Exception::throwThis(errors::LogicError,
62  "TypeConversionError"
63  "edm::Ptr<> : unable to convert type ",
64  typeid(element_type).name(),
65  " to ",
66  iToType.name(),
67  "\n");
68  }
69  }
70  }
char * address
Definition: mlp_lapack.h:14
uint16_t size_type
JetCorrectorParametersCollection coll
Definition: classes.h:16