1 #ifndef __JDETECTOR__JDETECTORVERSION__
2 #define __JDETECTOR__JDETECTORVERSION__
26 namespace JDETECTOR {}
27 namespace JPP {
using namespace JDETECTOR; }
132 public std::map<std::string, JDetectorVersion::JVersion_t>
141 #define MAKE_ENTRY(A) std::make_pair(to_upper(getClassname(#A)), A)
163 const_iterator i = this->find(
to_upper(version));
165 if (i != this->end()) {
196 const_iterator i = this->find(
to_upper(version));
198 if (i != this->end())
227 for (const_iterator i = this->begin(); i != this->end(); ++i) {
228 if (i->second == value) {
242 public std::map<JDetectorVersion::JVersion_t, std::string>
253 for (JGetDetectorVersion::const_iterator i = input.begin(); i != input.end(); ++i) {
254 this->insert(make_pair(i->second, i->first));
267 const_iterator i = this->find(value);
269 if (i != this->end()) {
287 const_iterator i = this->find(value);
289 if (i != this->end())
JGetDetectorVersion()
Default constructor.
Interface for binary output.
Auxiliary class to map detector version to numerical value.
std::vector< T >::difference_type distance(typename std::vector< T >::const_iterator first, typename PhysicsEvent::const_iterator< T > second)
Specialisation of STL distance.
JDetectorVersion()
Default constructor.
JVersion_t
Enumeration of version types.
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
JPutDetectorVersion(const JGetDetectorVersion &input)
Constructor.
const std::string & getVersion() const
Get version.
JDetectorVersion::JVersion_t operator()(const std::string &version) const
Get numerical value.
std::string getLatestDetectorVersion(const JType< std::string > &type)
Get latest detector version.
Auxiliary class for a type holder.
friend std::istream & operator>>(std::istream &in, JDetectorVersion &version)
Read version from input.
friend std::ostream & operator<<(std::ostream &out, const JDetectorVersion &version)
Write version to output.
then echo The file $DIR KM3NeT_00000001_00000000 root already please rename or remove it first
JDetectorVersion::JVersion_t operator()(const JDetectorVersion &version) const
Get numerical value.
int operator[](const JDetectorVersion &version) const
Get index of detector version.
Auxiliary class to map numerical value to detector version.
Version with UTC time and UTM position data.
Version with PMT status field and comments.
Version with quaternion and time offset per module.
const array_type< JValue_t > & make_array(const JValue_t(&array)[N])
Method to create array of values.
do set_variable OUTPUT_DIRECTORY $WORKDIR T
std::vector< std::string > getDetectorVersions(const JType< std::string > &type)
Get detector versions.
std::string to_upper(const std::string &value)
Convert all character to upper case.
Interface for binary input.
Auxiliary methods to convert data members or return values of member methods of a set of objects to a...
static const JGetDetectorVersion getDetectorVersion
Function object to map detector version to numerical value.
static const JPutDetectorVersion putDetectorVersion(getDetectorVersion)
Function object to map numerical value to detector version.
friend JReader & operator>>(JReader &in, JDetectorVersion &version)
Read version from input.
const std::string & operator()(const JDetectorVersion::JVersion_t &value) const
Put detector version.
JDetectorVersion(const JVersion &version)
Constructor.
Version with module status field.
friend JWriter & operator<<(JWriter &out, const JDetectorVersion &version)
Write version to output.
Auxiliary class for version identifier.
then fatal Wrong number of arguments fi set_variable DETECTOR $argv[1] set_variable INPUT_FILE $argv[2] eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY source JAcoustics sh $DETECTOR_ID CHECK_EXIT_CODE typeset A TRIPODS get_tripods $WORKDIR tripod txt TRIPODS for EMITTER in
int operator[](const JDetectorVersion::JVersion_t &value) const
Get index of detector version.
int operator[](const JDetectorVersion::JVersion_t &value) const
Get index of version.
STD extensions for binary I/O.
int operator[](const std::string &version) const
Get index of detector version.