#ifndef __JROOT__JABSTRACTSTREAMER__ #define __JROOT__JABSTRACTSTREAMER__ #include /** * \file * * This file contains the basic interface for ASCII I/O of ROOT objects. * \author mdejong */ namespace JROOT {} namespace JPP { using namespace JROOT; } namespace JROOT { class JRootReader; //!< Forward declaration of reader object. class JRootWriter; //!< Forward declaration of writer object. /** * Interface for ASCII I/O of a template class. */ class JAbstractStreamer { public: /** * Virtual destructor. */ virtual ~JAbstractStreamer() {} /** * Read object. * * \param in reader * \param address pointer to object * \return reader */ virtual JRootReader& getObject(JRootReader& in, void* address) const = 0; /** * Writer object. * * \param out writer * \param address pointer to object * \return writer */ virtual JRootWriter& putObject(JRootWriter& out, const void* address) const = 0; /** * Write object according equation format. * * \param out writer * \param prefix prefix * \param address pointer to object * \return writer */ virtual JRootWriter& put(JRootWriter& out, const std::string& prefix, const void* address) const = 0; }; } #endif