Skip to content

Commit

Permalink
Fix warnings about namespaces
Browse files Browse the repository at this point in the history
  • Loading branch information
jmcarcell authored and tmadlener committed Jan 15, 2024
1 parent 35177a4 commit 85a48b4
Show file tree
Hide file tree
Showing 31 changed files with 82 additions and 90 deletions.
4 changes: 2 additions & 2 deletions source/include/marlin/CCProcessor.h
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,8 @@ namespace marlin {
std::shared_ptr<StringParameters> _param; // parameters from processor
Processor* _proc; // associated Marlin processor

const StringVec _error_desc{ "Processor has no Parameters", "Processor not available!", "Some Collections have Errors"}; // error descriptions for all processors
StringVec _errors{}; // list of errors found in a processor
const EVENT::StringVec _error_desc{ "Processor has no Parameters", "Processor not available!", "Some Collections have Errors"}; // error descriptions for all processors
EVENT::StringVec _errors{}; // list of errors found in a processor

sSet _conditions; // processor's conditions

Expand Down
2 changes: 1 addition & 1 deletion source/include/marlin/CMProcessor.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ namespace marlin{
bool isInstalled( const std::string& type );

//utility function to tokenize strings
void tokenize( const std::string str, StringVec& tokens, const std::string& delimiters = " " );
void tokenize( const std::string str, EVENT::StringVec& tokens, const std::string& delimiters = " " );

private:
// Constructor
Expand Down
14 changes: 6 additions & 8 deletions source/include/marlin/ConditionsProcessor.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ namespace lccd{
class IConditionsChangeListener;
}

using namespace lcio ;

namespace marlin{


Expand Down Expand Up @@ -73,7 +71,7 @@ class ConditionsProcessor : public Processor {

/** Updates all registered conditions handlers and adds the data to the event.
*/
virtual void processEvent( LCEvent * evt ) ;
virtual void processEvent( EVENT::LCEvent * evt ) ;


// virtual void check( LCEvent * evt ) ;
Expand All @@ -88,19 +86,19 @@ class ConditionsProcessor : public Processor {
std::string _dbInit="";

/** initialization of SimpleFileHandlers */
StringVec _simpleHandlerInit{};
EVENT::StringVec _simpleHandlerInit{};

/** initialization of DBCondHandlers */
StringVec _dbcondHandlerInit{};
EVENT::StringVec _dbcondHandlerInit{};

/** initialization of DBFileHandlers */
StringVec _dbfileHandlerInit{};
EVENT::StringVec _dbfileHandlerInit{};

/** initialization of DataFileHandlers */
StringVec _datafileHandlerInit{};
EVENT::StringVec _datafileHandlerInit{};

/** the names of all handlers */
StringVec _condHandlerNames{};
EVENT::StringVec _condHandlerNames{};

int _nRun=-1;
int _nEvt=-1;
Expand Down
2 changes: 0 additions & 2 deletions source/include/marlin/DataSourceProcessor.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@

#include "marlin/Processor.h"

using namespace lcio ;


namespace marlin{

Expand Down
13 changes: 5 additions & 8 deletions source/include/marlin/EventSelector.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@
#include <set>
#include <map> // pair

using namespace lcio ;
using namespace marlin ;


/** Simple event selector processor. Returns true if the given event
* was specified in the EvenList parameter.
Expand Down Expand Up @@ -42,15 +39,15 @@ namespace marlin {

/** Called for every run.
*/
virtual void processRunHeader( LCRunHeader* run ) ;
virtual void processRunHeader( EVENT::LCRunHeader* run ) ;

/** Called for every event - the working horse.
*/
virtual void processEvent( LCEvent * evt ) ;
virtual void processEvent( EVENT::LCEvent * evt ) ;

virtual void check( LCEvent * evt ) ;
virtual void check( EVENT::LCEvent * evt ) ;

virtual void modifyEvent( LCEvent *evt ) ;
virtual void modifyEvent( EVENT::LCEvent *evt ) ;

/** Called after data processing for clean up.
*/
Expand All @@ -63,7 +60,7 @@ namespace marlin {

/** Input collection name.
*/
IntVec _evtList{};
EVENT::IntVec _evtList{};
SET _evtSet{};

int _nRun=-1;
Expand Down
8 changes: 4 additions & 4 deletions source/include/marlin/Exceptions.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ namespace marlin{
protected:
ParseException() { /*no_op*/ ; }
public:
virtual ~ParseException() throw() { /*no_op*/; }
virtual ~ParseException() noexcept { /*no_op*/; }

ParseException( std::string text ){
message = "marlin::ParseException: " + text ;
Expand All @@ -40,7 +40,7 @@ namespace marlin{
SkipEventException(const Processor* proc){
message = proc->name() ;
}
virtual ~SkipEventException() throw() { /*no_op*/; }
virtual ~SkipEventException() noexcept { /*no_op*/; }

};

Expand All @@ -58,7 +58,7 @@ namespace marlin{
StopProcessingException(const Processor* proc){
message = proc->name() ;
}
virtual ~StopProcessingException() throw() { /*no_op*/; }
virtual ~StopProcessingException() noexcept { /*no_op*/; }

};

Expand All @@ -76,7 +76,7 @@ namespace marlin{
RewindDataFilesException(const Processor* proc){
message = proc->name() ;
}
virtual ~RewindDataFilesException() throw() { /*no_op*/; }
virtual ~RewindDataFilesException() noexcept { /*no_op*/; }

};

Expand Down
3 changes: 1 addition & 2 deletions source/include/marlin/IFourVectorSmearer.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
#include "CLHEP/Vector/LorentzVector.h"

namespace CLHEP{} // declare namespace CLHEP for backward compatibility
using namespace CLHEP ;


namespace marlin{
Expand All @@ -29,7 +28,7 @@ namespace marlin{

/** Smears the given four vector
*/
virtual HepLorentzVector smearedFourVector( const HepLorentzVector& v, int pdgCode ) = 0 ;
virtual CLHEP::HepLorentzVector smearedFourVector( const CLHEP::HepLorentzVector& v, int pdgCode ) = 0 ;

} ;

Expand Down
20 changes: 9 additions & 11 deletions source/include/marlin/LCIOOutputProcessor.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
#include "IO/LCWriter.h"


using namespace lcio ;

namespace IMPL{
class LCCollectionVec ;
}
Expand Down Expand Up @@ -47,7 +45,7 @@ namespace marlin{
*/
class LCIOOutputProcessor : public Processor {

typedef std::vector< LCCollectionVec* > SubSetVec ;
typedef std::vector< lcio::LCCollectionVec* > SubSetVec ;


public:
Expand All @@ -70,11 +68,11 @@ namespace marlin{

/** Write every run header.
*/
virtual void processRunHeader( LCRunHeader* run) ;
virtual void processRunHeader( EVENT::LCRunHeader* run) ;

/** Write every event.
*/
virtual void processEvent( LCEvent * evt ) ;
virtual void processEvent( EVENT::LCEvent * evt ) ;

/** Close outputfile.
*/
Expand All @@ -83,24 +81,24 @@ namespace marlin{
/** Drops the collections specified in the steering file parameters DropCollectionNames and
* DropCollectionTypes.
*/
void dropCollections( LCEvent * evt ) ;
void dropCollections( EVENT::LCEvent * evt ) ;


protected:

std::string _lcioOutputFile="";
std::string _lcioWriteMode="";

StringVec _dropCollectionNames{};
StringVec _dropCollectionTypes{};
StringVec _keepCollectionNames{};
StringVec _fullSubsetCollections{};
EVENT::StringVec _dropCollectionNames{};
EVENT::StringVec _dropCollectionTypes{};
EVENT::StringVec _keepCollectionNames{};
EVENT::StringVec _fullSubsetCollections{};

int _splitFileSizekB=1992294;

SubSetVec _subSets{};

LCWriter* _lcWrt=NULL;
lcio::LCWriter* _lcWrt=NULL;
int _nRun=-1;
int _nEvt=-1;
int _compressionLevel{6};
Expand Down
3 changes: 0 additions & 3 deletions source/include/marlin/LogicalExpressions.h
Original file line number Diff line number Diff line change
Expand Up @@ -127,9 +127,6 @@ namespace marlin{
_last = c ;
}

~Tokenizer(){
}

std::vector<Expression> & result() {

return _tokens ;
Expand Down
4 changes: 2 additions & 2 deletions source/include/marlin/MarlinSteerCheck.h
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ namespace marlin {
ColVec& getLCIOCols() const;

/** Returns the names of the LCIO files found in the global section*/
StringVec& getLCIOFiles(){ return _lcioFiles; }
EVENT::StringVec& getLCIOFiles(){ return _lcioFiles; }

/** Returns a list of all available Collections for a given type, name and processor (to use in a ComboBox) */
sSet& getColsSet( const std::string& type, const std::string& name, CCProcessor* proc );
Expand Down Expand Up @@ -227,7 +227,7 @@ namespace marlin {
ProcVec _aProc{}; //active processors
ProcVec _iProc{}; //inactive processors
sColVecMap _lcioCols{}; //LCIO collections
StringVec _lcioFiles{}; //LCIO filenames
EVENT::StringVec _lcioFiles{}; //LCIO filenames

sSet _colValues{}; //all available collection values for a given type (use in ComboBox)

Expand Down
12 changes: 5 additions & 7 deletions source/include/marlin/Processor.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@

class MarlinProcessorWrapper;

using namespace lcio ;


namespace marlin{
/** Helper class that gives an external processor manager access to private
Expand Down Expand Up @@ -117,17 +115,17 @@ struct ExternalProcessorMgrAccessor {
/** Called for every run, e.g. overwrite to initialize run dependent
* histograms.
*/
virtual void processRunHeader( LCRunHeader* ) { }
virtual void processRunHeader( EVENT::LCRunHeader* ) { }

/** Called for every event - the working horse.
*/
virtual void processEvent( LCEvent * ) { }
virtual void processEvent( EVENT::LCEvent * ) { }

/** Called for every event - right after processEvent()
* has been called for this processor.
* Use to check processing and/or produce check plots.
*/
virtual void check( LCEvent* ) { }
virtual void check( EVENT::LCEvent* ) { }

/**
* Public overload of setFirstEvent for use in external processor managers
Expand Down Expand Up @@ -316,8 +314,8 @@ struct ExternalProcessorMgrAccessor {
void registerInputCollections(const std::string& collectionType,
const std::string& parameterName,
const std::string& parameterDescription,
StringVec& parameter,
const StringVec& defaultVal,
EVENT::StringVec& parameter,
const EVENT::StringVec& defaultVal,
int setSize=0 ) {

setLCIOInType( parameterName , collectionType ) ;
Expand Down
4 changes: 1 addition & 3 deletions source/include/marlin/ProcessorEventSeeder.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
#include <vector>
#include <map>

using namespace lcio ;

namespace marlin{

class ProcessorMgr;
Expand Down Expand Up @@ -79,7 +77,7 @@ namespace marlin{
/** Create new set of seeds for registered Processors for the given event.
* This method should only be called from ProcessorMgr::processEvent
*/
void refreshSeeds( LCEvent * evt ) ;
void refreshSeeds( EVENT::LCEvent * evt ) ;

ProcessorEventSeeder(const ProcessorEventSeeder&); // prevent copying
ProcessorEventSeeder& operator=(const ProcessorEventSeeder&); // prevent assignment
Expand Down
12 changes: 5 additions & 7 deletions source/include/marlin/ProcessorMgr.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@
#include <set>
#include <list>

using namespace lcio ;

namespace marlin{

class ProcessorEventSeeder;
Expand All @@ -33,7 +31,7 @@ typedef std::map< const std::string , int > SkippedEventMap ;
* @author F. Gaede, DESY
* @version $Id: ProcessorMgr.h,v 1.16 2007-08-13 10:38:39 gaede Exp $
*/
class ProcessorMgr : public LCRunListener, public LCEventListener {
class ProcessorMgr : public IO::LCRunListener, public IO::LCEventListener {

friend class Processor ;
friend class CMProcessor ;
Expand Down Expand Up @@ -85,13 +83,13 @@ friend class MarlinSteerCheck ;
void dumpRegisteredProcessorsXML() ;

virtual void init() ;
virtual void processRunHeader( LCRunHeader* ) ;
virtual void processEvent( LCEvent* ) ;
virtual void processRunHeader( EVENT::LCRunHeader* ) ;
virtual void processEvent( EVENT::LCEvent* ) ;
virtual void end() ;


virtual void modifyRunHeader( LCRunHeader*) ;
virtual void modifyEvent( LCEvent *) ;
virtual void modifyRunHeader( EVENT::LCRunHeader*) ;
virtual void modifyEvent( EVENT::LCEvent *) ;

/** Calls readDataSource() for all Processors of type DataSourceProcessor.
*/
Expand Down
8 changes: 3 additions & 5 deletions source/include/marlin/ProcessorParameter.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
// typedef std::map< std::string , std::vector< std::string > > ParametersMap ;


using namespace lcio ;

namespace marlin{

/** Class that holds a steering variable for a marlin processor - automatically created by
Expand Down Expand Up @@ -148,9 +146,9 @@ namespace marlin{
// return typeid( _parameter ).name() ; }

// make this human readable
if ( typeid( _parameter ) == typeid( IntVec )) return "IntVec" ;
else if( typeid( _parameter ) == typeid( FloatVec )) return "FloatVec" ;
else if( typeid( _parameter ) == typeid( StringVec )) return "StringVec" ;
if ( typeid( _parameter ) == typeid( EVENT::IntVec )) return "IntVec" ;
else if( typeid( _parameter ) == typeid( EVENT::FloatVec )) return "FloatVec" ;
else if( typeid( _parameter ) == typeid( EVENT::StringVec )) return "StringVec" ;
else if( typeid( _parameter ) == typeid( int )) return "int" ;
else if( typeid( _parameter ) == typeid( float )) return "float" ;
else if( typeid( _parameter ) == typeid( double )) return "double" ;
Expand Down
2 changes: 1 addition & 1 deletion source/include/marlin/SimpleClusterSmearer.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ namespace marlin{
* polar angle of the cluster. Returns a vector with all elements 0. if
* no resolution is defined.
*/
virtual HepLorentzVector smearedFourVector( const HepLorentzVector& v, int pdgCode ) ;
virtual CLHEP::HepLorentzVector smearedFourVector( const CLHEP::HepLorentzVector& v, int pdgCode ) ;

protected:

Expand Down
Loading

0 comments on commit 85a48b4

Please sign in to comment.