CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
GeometryConfiguration Class Reference

#include <GeometryConfiguration.h>

Inheritance diagram for GeometryConfiguration:
DDLDocumentProvider

Public Member Functions

bool doValidation () const override
 Return a flag whether to do xml validation or not. More...
 
void dumpFileList (void) const override
 Print out the list of files. More...
 
 GeometryConfiguration (const edm::ParameterSet &p)
 
const std::vector< std::string > & getFileList (void) const override
 Return a list of files as a vector of strings. More...
 
std::string getSchemaLocation () const override
 Return the Schema Location. More...
 
const std::vector< std::string > & getURLList (void) const override
 Return a list of urls as a vector of strings. More...
 
int readConfig (const std::string &filename) override
 Reads in a configuration file and parses it. More...
 
 ~GeometryConfiguration () override
 
- Public Member Functions inherited from DDLDocumentProvider
virtual ~DDLDocumentProvider ()
 

Private Attributes

std::string dummyLocation_
 
std::vector< std::string > emptyStrings_
 
std::vector< std::string > files_
 
std::vector< std::string > relFiles_
 

Detailed Description

May 23, 2006: Michael Case: This class provides the filenames to the DDLParser from the parameter-set passed by XMLIdealGeometryESSource. This removes the dependency on the Configuration Language of the DDD and moves the list of XML files to the parameter-set for provenance.

Definition at line 20 of file GeometryConfiguration.h.

Constructor & Destructor Documentation

GeometryConfiguration::GeometryConfiguration ( const edm::ParameterSet p)

Definition at line 12 of file GeometryConfiguration.cc.

References emptyStrings_, files_, edm::FileInPath::fullPath(), edm::ParameterSet::getParameter(), and relFiles_.

12  : dummyLocation_("") {
13  relFiles_ = pset.getParameter<std::vector<std::string> >("geomXMLFiles");
14  for (std::vector<std::string>::const_iterator rit = relFiles_.begin(), ritEnd = relFiles_.end();
15  rit != ritEnd; ++rit ) {
16  edm::FileInPath fp(*rit);
17  files_.emplace_back(fp.fullPath());
18  emptyStrings_.emplace_back("");
19  }
20 }
std::vector< std::string > relFiles_
std::vector< std::string > emptyStrings_
std::vector< std::string > files_
GeometryConfiguration::~GeometryConfiguration ( )
override

Definition at line 22 of file GeometryConfiguration.cc.

22 { }

Member Function Documentation

bool GeometryConfiguration::doValidation ( void  ) const
overridevirtual

Return a flag whether to do xml validation or not.

Implements DDLDocumentProvider.

Definition at line 31 of file GeometryConfiguration.cc.

References LogDebug.

31  {
32  LogDebug("GeometryConfiguration") << " the doValidation() method not valid for this DDLDocumentProvider" << std::endl;
33  return false;
34 }
#define LogDebug(id)
void GeometryConfiguration::dumpFileList ( void  ) const
overridevirtual

Print out the list of files.

Implements DDLDocumentProvider.

Definition at line 54 of file GeometryConfiguration.cc.

References gather_cfg::cout, FrontierConditions_GlobalTag_cff::file, and files_.

54  {
55  std::cout << "File List:" << std::endl;
56  std::cout << " number of files=" << files_.size() << std::endl;
57  for (const auto & file : files_)
58  std::cout << file << std::endl;
59 }
std::vector< std::string > files_
const std::vector< std::string > & GeometryConfiguration::getFileList ( void  ) const
overridevirtual

Return a list of files as a vector of strings.

Implements DDLDocumentProvider.

Definition at line 37 of file GeometryConfiguration.cc.

References files_.

37  {
38  return files_;
39 }
std::vector< std::string > files_
std::string GeometryConfiguration::getSchemaLocation ( void  ) const
overridevirtual

Return the Schema Location.

Implements DDLDocumentProvider.

Definition at line 25 of file GeometryConfiguration.cc.

References dummyLocation_.

25  {
26  edm::LogError("GeometryConfiguration") << " This sub-class of DDLDocumentProvider does not USE XML parsing!!!" << std::endl;
27  return dummyLocation_;
28 }
const std::vector< std::string > & GeometryConfiguration::getURLList ( void  ) const
overridevirtual

Return a list of urls as a vector of strings.

The EDM should not allow URLs because of provenance. This vector will always be empty.

Implements DDLDocumentProvider.

Definition at line 46 of file GeometryConfiguration.cc.

References emptyStrings_, and LogDebug.

47 {
48  LogDebug("GeometryConfiguration") << " the getURLList of this DDLDocumentProvider empty strings" << std::endl;
49  // return relFiles_;
50  return emptyStrings_;
51 }
#define LogDebug(id)
std::vector< std::string > emptyStrings_
int GeometryConfiguration::readConfig ( const std::string &  filename)
overridevirtual

Reads in a configuration file and parses it.

Implements DDLDocumentProvider.

Definition at line 61 of file GeometryConfiguration.cc.

61  {
62  edm::LogWarning("GeometryConfiguration") << " The readConfig of this DDLDocumentProvider is not valid!" << std::endl;
63  return 0;
64 }

Member Data Documentation

std::string GeometryConfiguration::dummyLocation_
private

Definition at line 55 of file GeometryConfiguration.h.

Referenced by getSchemaLocation().

std::vector< std::string > GeometryConfiguration::emptyStrings_
private

Definition at line 54 of file GeometryConfiguration.h.

Referenced by GeometryConfiguration(), and getURLList().

std::vector< std::string > GeometryConfiguration::files_
private

Definition at line 52 of file GeometryConfiguration.h.

Referenced by dumpFileList(), GeometryConfiguration(), and getFileList().

std::vector< std::string > GeometryConfiguration::relFiles_
private

Definition at line 53 of file GeometryConfiguration.h.

Referenced by GeometryConfiguration().