91 string defaultPath =
"L1Trigger/";
92 string eau_dir =
"L1TMuon/data/bmtf_luts/LUTs_Ass/";
100 if ( file.
open() != 0 )
return -1;
105 int skip2=getIgnoredLines(file);
109 while ( file.
good() ) {
112 if ( !file.
good() )
break;
114 if ( !file.
good() )
break;
116 if ( !file.
good() )
break;
118 if ( !file.
good() )
break;
123 if ( !file.
good() ) { file.
close();
break; }
140 cout <<
"L1 barrel Track Finder ETA Pattern look-up table :" << endl;
141 cout <<
"==================================================" << endl;
144 cout <<
"ETF Patterns : " << m_lut.size() << endl;
145 cout <<
"======================" << endl;
148 LUT::const_iterator iter = m_lut.begin();
149 while ( iter != m_lut.end() ) {
150 cout << (*iter).second << endl;
164 LUT::const_iterator it = m_lut.find(
id);
165 if ( it == m_lut.end() ) {
166 edm::LogError (
"L1MuBMTEtaPatternLut: fine eta not found") <<
"Error: L1MuBMTEtaPatternLut: pattern not found : " <<
id << endl;
173 if ( file.
open() != 0 )
return -1;
175 while ( file.
good() ) {
178 if (str.find(
"#")==0) skip+=1;
180 if ( !file.
good() ) { file.
close();
break; }
L1MuBMTEtaPatternLut()
constructor
int load()
load pattern look-up table
L1MuDTEtaPattern getPattern(int id) const
get pattern with a given ID
bool good()
return status of file stream
virtual ~L1MuBMTEtaPatternLut()
destructor
void ignoreLines(int n)
read and ignore n lines from file
int getIgnoredLines(L1TriggerLutFile file) const
void print() const
print pattern look-up table
std::string readString()
read one string from file
int readInteger()
read one integer from file
std::string fullPath() const
void reset()
reset pattern look-up table