CMS 3D CMS Logo

Classes | Functions

/data/git/CMSSW_5_3_11_patch5/src/DetectorDescription/Core/interface/DDStrVector.h File Reference

#include "DetectorDescription/Core/interface/DDBase.h"
#include "DetectorDescription/Core/interface/DDName.h"
#include <vector>
#include <iostream>

Go to the source code of this file.

Classes

class  DDStrVector
 a named constant corresponding to the DDL-XML tag <Constant> and <ConstantsStrVector> More...

Functions

std::ostream & operator<< (std::ostream &o, const DDStrVector &cons)
 output operator for printing ...

Function Documentation

std::ostream& operator<< ( std::ostream &  o,
const DDStrVector cons 
)

output operator for printing ...

Definition at line 20 of file DDStrVector.cc.

References DDBase< N, C >::isDefined(), DDBase< N, C >::name(), DDStrVector::size(), and DDStrVector::values().

{
  os << "DDStrVector name=" << cons.name(); 
  
  if(cons.isDefined().second) {
    os << " size=" << cons.size() << " vals=( ";
    DDStrVector::value_type::const_iterator it(cons.values().begin()), ed(cons.values().end());
    for(; it<ed; ++it) {
      os << *it << ' ';
    }
    os << ')';
  }
  else {
    os << " constant is not yet defined, only declared.";
  }  
  return os;
}