CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_4/src/GeometryReaders/XMLIdealGeometryESSource/src/GeometryConfiguration.cc

Go to the documentation of this file.
00001 
00005 #include "GeometryReaders/XMLIdealGeometryESSource/interface/GeometryConfiguration.h"
00006 
00007 #include "FWCore/ParameterSet/interface/FileInPath.h"
00008 
00009 #include "DetectorDescription/Parser/interface/DDLParser.h"
00010 #include "DetectorDescription/Base/interface/DDdebug.h"
00011 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00012 #include "FWCore/MessageLogger/interface/MessageLogger.h"
00013 
00014 #include <string>
00015 #include <vector>
00016 
00017 GeometryConfiguration::GeometryConfiguration( const edm::ParameterSet& pset ) : dummyLocation_("") { 
00018   relFiles_ = pset.getParameter<std::vector<std::string> >("geomXMLFiles");
00019   for (std::vector<std::string>::const_iterator rit = relFiles_.begin(), ritEnd = relFiles_.end();
00020       rit != ritEnd; ++rit ) {
00021     edm::FileInPath fp(*rit);
00022     files_.push_back(fp.fullPath());
00023     emptyStrings_.push_back("");
00024   }
00025 }
00026 
00027 GeometryConfiguration::~GeometryConfiguration() { }
00028 
00030 std::string GeometryConfiguration::getSchemaLocation() const {
00031   edm::LogError("GeometryConfiguration") << " This sub-class of DDLDocumentProvider does not USE XML parsing!!!" << std::endl;
00032   return dummyLocation_;
00033 }
00034 
00036 bool GeometryConfiguration::doValidation() const {
00037   LogDebug("GeometryConfiguration") << " the doValidation() method not valid for this DDLDocumentProvider" << std::endl;
00038   return false;
00039 }
00040 
00042 const std::vector < std::string >  & GeometryConfiguration::getFileList(void) const {
00043   return files_;
00044 }
00045 
00047 
00051 const std::vector < std::string >  & GeometryConfiguration::getURLList(void) const
00052 {
00053   LogDebug("GeometryConfiguration") << " the getURLList of this DDLDocumentProvider empty strings" << std::endl;
00054   //  return relFiles_;
00055   return emptyStrings_;
00056 }
00057 
00059 void GeometryConfiguration::dumpFileList(void) const {
00060   std::cout << "File List:" << std::endl;
00061   std::cout << "  number of files=" << files_.size() << std::endl;
00062   for (std::vector<std::string>::const_iterator it = files_.begin(), itEnd = files_.end(); it != itEnd; ++it)
00063     std::cout << *it << std::endl;
00064 }
00065 
00066 int GeometryConfiguration::readConfig( const std::string& fname ) {
00067   edm::LogWarning("GeometryConfiguration") << " The readConfig of this DDLDocumentProvider is not valid!" << std::endl;
00068   return 0;
00069 }
00070