Logical location of module.
More...
#include <JModuleLocation.hh>
Logical location of module.
The logical location of a module consists of a string and floor number. This class implements the JLANG::JComparable interface.
Definition at line 36 of file JModuleLocation.hh.
◆ JModuleLocation() [1/2]
JDETECTOR::JModuleLocation::JModuleLocation |
( |
| ) |
|
|
inline |
◆ JModuleLocation() [2/2]
JDETECTOR::JModuleLocation::JModuleLocation |
( |
const int |
string, |
|
|
const int |
floor |
|
) |
| |
|
inline |
◆ getLocation() [1/2]
Get location.
- Returns
- location
Definition at line 68 of file JModuleLocation.hh.
70 return static_cast<const JModuleLocation&>(*
this);
◆ getLocation() [2/2]
Get location.
- Returns
- location
Definition at line 79 of file JModuleLocation.hh.
81 return static_cast<JModuleLocation&>(*
this);
◆ setLocation()
void JDETECTOR::JModuleLocation::setLocation |
( |
const JModuleLocation & |
location | ) |
|
|
inline |
Set location.
- Parameters
-
Definition at line 90 of file JModuleLocation.hh.
92 static_cast<JModuleLocation&>(*
this) = location;
◆ toString() [1/2]
std::string JDETECTOR::JModuleLocation::toString |
( |
| ) |
const |
|
inline |
◆ toString() [2/2]
std::string JDETECTOR::JModuleLocation::toString |
( |
const std::string & |
fmt, |
|
|
const std::string |
target = "%" |
|
) |
| const |
|
inline |
Convert module loation to string.
The targets target
in the format string fmt
are consecutively replaced by floor
and string
.
- Parameters
-
- Returns
- string
Definition at line 117 of file JModuleLocation.hh.
121 buffer.replace(target,
string, 1);
122 buffer.replace(target,
floor, 1);
◆ getString()
int JDETECTOR::JModuleLocation::getString |
( |
| ) |
const |
|
inline |
◆ getFloor()
int JDETECTOR::JModuleLocation::getFloor |
( |
| ) |
const |
|
inline |
◆ less()
bool JDETECTOR::JModuleLocation::less |
( |
const JModuleLocation & |
location | ) |
const |
|
inline |
Less than method.
- Parameters
-
- Returns
- true if first location before second location; else false
Definition at line 156 of file JModuleLocation.hh.
◆ operator>> [1/2]
Read module location from input.
- Parameters
-
in | input stream |
location | module location |
- Returns
- input stream
Definition at line 172 of file JModuleLocation.hh.
175 in >> location.
floor;
◆ operator<< [1/2]
std::ostream& operator<< |
( |
std::ostream & |
out, |
|
|
const JModuleLocation & |
location |
|
) |
| |
|
friend |
Write module location to output.
- Parameters
-
out | output stream |
location | module location |
- Returns
- output stream
Definition at line 188 of file JModuleLocation.hh.
192 out << setw(3) << location.
string;
194 out << setw(2) << location.
floor;
◆ operator>> [2/2]
Read module location from input.
- Parameters
-
in | reader |
location | module location |
- Returns
- reader
Definition at line 207 of file JModuleLocation.hh.
210 in >> location.
floor;
◆ operator<< [2/2]
Write module location to output.
- Parameters
-
out | writer |
location | module location |
- Returns
- writer
Definition at line 223 of file JModuleLocation.hh.
226 out << location.
floor;
◆ string
int JDETECTOR::JModuleLocation::string |
|
protected |
◆ floor
int JDETECTOR::JModuleLocation::floor |
|
protected |
The documentation for this class was generated from the following file: