Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Made base and inheriting class agree on checkForCompatibility in CalibTracker #26008

Merged
merged 2 commits into from Feb 25, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -35,7 +35,7 @@ class SiStripDQMPopConSourceHandler : public popcon::PopConSourceHandler<T>
virtual T* getObj() const = 0;

virtual std::string getMetaDataString() const;
virtual bool checkForCompatibility( const std::string otherMetaData ) const { return otherMetaData != getMetaDataString(); }
virtual bool checkForCompatibility( const std::string& otherMetaData ) const { return otherMetaData != getMetaDataString(); }

// additional methods needed for SiStripPopConDQMEDHarvester
virtual void initES(const edm::EventSetup&) {}
Expand Down Expand Up @@ -89,7 +89,7 @@ void SiStripDQMPopConSourceHandler<T>::getNewObjects()
<< this->logDBEntry().payloadToken << "\n"
<< this->logDBEntry().exectime << "\n"
<< this->logDBEntry().execmessage << "\n";
if ( this->logDBEntry().usertext != "" )
if ( !this->logDBEntry().usertext.empty() )
ss<< "\n-- user text " << this->logDBEntry().usertext.substr(this->logDBEntry().usertext.find_last_of("@")) ;
} else {
ss << " First object for this tag ";
Expand Down Expand Up @@ -121,7 +121,7 @@ bool SiStripDQMPopConSourceHandler<T>::isTransferNeeded()
std::string ss_logdb{};

//get log information from previous upload
if ( this->logDBEntry().usertext != "" )
if ( !this->logDBEntry().usertext.empty() )
ss_logdb = this->logDBEntry().usertext.substr(this->logDBEntry().usertext.find_last_of("@")+2);

std::string ss = getMetaDataString();
Expand Down
Expand Up @@ -14,7 +14,7 @@ SiStripPopConHistoryDQMBase::~SiStripPopConHistoryDQMBase()
edm::LogInfo("SiStripHistoryDQMService") << "[SiStripHistoryDQMService::~SiStripHistoryDQMService]";
}

bool SiStripPopConHistoryDQMBase::checkForCompatibility(const std::string& otherMetaData)
bool SiStripPopConHistoryDQMBase::checkForCompatibility(const std::string& otherMetaData) const
{
if ( otherMetaData.empty() )
return true;
Expand Down
Expand Up @@ -14,7 +14,7 @@ class SiStripPopConHistoryDQMBase : public SiStripDQMPopConSourceHandler<HDQMSum
~SiStripPopConHistoryDQMBase() override;
void dqmEndJob(DQMStore::IBooker& booker, DQMStore::IGetter& getter) override;
HDQMSummary* getObj() const override;
bool checkForCompatibility( const std::string& otherMetaData );
bool checkForCompatibility( const std::string& otherMetaData ) const override;
private:
std::unique_ptr<HDQMfitUtilities> fitME_;
std::string MEDir_;
Expand Down