1 #ifndef __JDB_JDBREADER__ 
    2 #define __JDB_JDBREADER__ 
    7 #include "dbclient/KM3NeTDBClient.h" 
   18 #include "JDB/JDBDictionary.hh" 
   30   using KM3NeT::DB::ResultSet;
 
   31   using KM3NeT::DB::Selector;
 
   60       string parameter = 
to_upper(i->Name);
 
   63         for (string::size_type pos; (pos = parameter.find(*i)) != string::npos; ) {
 
  141       if (columns.empty()) {
 
  145         for (
size_t i = 0; i != rs.FieldCount(); ++i) {
 
  147           string parameter = rs.FieldName(i);
 
  150             for (string::size_type pos; (pos = parameter.find(*i)) != string::npos; ) {
 
  151               parameter.erase(pos);
 
  155           columns.push_back(cls.
find(parameter.c_str()));
 
  159       for (
unsigned int i = 0; i != rs.FieldCount(); ++i) {
 
  210   template<
class JElement_t, 
class JAllocator_t>
 
  213     for (JElement_t 
object; rs >> object; ) {
 
  214       buffer.push_back(
object);
 
ASCII I/O of objects with ROOT dictionary.
 
Simple data structure to support I/O of equations (see class JLANG::JEquation).
 
This class can be used to temporarily redirect an input stream to an input string.
 
Implementation for ASCII input of objects with ROOT dictionary.
 
JRootReader & getObject(T &object)
Read object.
 
Auxiliary classes and methods for database I/O.
 
static const std::string SPECIAL_CHARACTERS
Special characters.
 
bool operator>>(ResultSet &rs, std::vector< JElement_t, JAllocator_t > &buffer)
Read multiple objects with ROOT dictionary from result set.
 
TObject * getObject(const JRootObjectID &id)
Get first TObject with given identifier.
 
Auxiliary classes and methods for language specific functionality.
 
std::string to_upper(const std::string &value)
Convert all character to upper case.
 
static JNullStream null
Null I/O stream.
 
T & getInstance(const T &object)
Get static instance from temporary object.
 
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
 
bool is_valid(const json &js)
Check validity of JSon data.
 
Auxiliary class to read object with ROOT dictionary from database.
 
JDBReader()
Default constructor.
 
static void set(const std::vector< Selector > &selection)
Set default value corresponding to given selection.
 
const T & operator()(ResultSet &rs)
Read object with ROOT dictionary from result set.
 
std::vector< JROOT::JRootReadableClass > columns
field count -> data member
 
static void reset()
Reset internal lookup table and default value.
 
static data_type & getInstance()
Get unique instance of template class.
 
bool is_valid() const
Check validity of this addressable class.
 
JRootAddressableClass find(const char *const name) const
Find addressable base class or data member with given name within current class.
 
ROOT class for reading object.