Loading...
Searching...
No Matches
XDRPersistenceManager.h
Go to the documentation of this file.
// -*- Mode: C++; tab-width: 2; -*-
// vi: set ts=2:
//
#ifndef BALL_CONCEPT_XDRPERSISTENCEMANAGER_H
#define BALL_CONCEPT_XDRPERSISTENCEMANAGER_H
#ifndef BALL_CONCEPT_PERSISTENCEMANAGER_H
# include <BALL/CONCEPT/persistenceManager.h>
#endif
#include <rpc/types.h>
#include <rpc/xdr.h>
namespace BALL
{
class BALL_EXPORT XDRPersistenceManager
: public PersistenceManager
{
public:
static const Size STREAM_HEADER;
static const Size STREAM_TRAILER;
static const Size OBJECT_HEADER;
static const Size OBJECT_TRAILER;
XDRPersistenceManager()
;
XDRPersistenceManager(std::istream& is)
;
XDRPersistenceManager(std::ostream& os)
;
XDRPersistenceManager(std::istream& is, std::ostream& os)
;
virtual void writeHeader(const char* type_name, const char* name, LongSize ptr)
;
virtual bool checkHeader(const char* type_name, const char* name, LongSize& ptr)
;
virtual void writeTrailer(const char* name = 0)
;
virtual bool checkTrailer(const char* name = 0)
;
virtual void writeStreamHeader()
;
virtual void writeStreamTrailer()
;
virtual bool checkStreamHeader()
;
virtual bool checkStreamTrailer()
;
virtual bool getObjectHeader(String& type_name, LongSize& ptr)
;
virtual void writeName(const char* name)
;
virtual bool checkName(const char* name)
;
virtual void writeStorableHeader(const char* type_name, const char* name)
;
virtual bool checkStorableHeader(const char* type_name, const char* name)
;
virtual void writePrimitiveHeader(const char* type_name, const char* name)
;
virtual bool checkPrimitiveHeader(const char* type_name, const char* name)
;
virtual void writeStorableTrailer()
;
virtual bool checkStorableTrailer()
;
virtual void writePrimitiveTrailer()
;
virtual bool checkPrimitiveTrailer()
;
virtual void writeObjectPointerHeader(const char* type_name, const char* name)
;
virtual bool checkObjectPointerHeader(const char* type_name, const char* name)
;
virtual void writeObjectReferenceHeader(const char* type_name, const char* name)
;
virtual bool checkObjectReferenceHeader(const char* type_name, const char* name)
;
virtual void writeObjectPointerArrayHeader(const char* type_name, const char* name, Size size)
;
virtual bool checkObjectPointerArrayHeader(const char* type_name, const char* name, Size& size)
;
virtual void writeObjectPointerArrayTrailer()
;
virtual bool checkObjectPointerArrayTrailer()
;
virtual void initializeOutputStream()
;
virtual void finalizeOutputStream()
;
virtual void initializeInputStream()
;
virtual void finalizeInputStream()
;
virtual void put(const char c)
;
virtual void put(const Byte b)
;
virtual void put(const Index i)
;
virtual void put(const Size s)
;
virtual void put(const bool b)
;
virtual void put(const Real f)
;
virtual void put(const DoubleReal d)
;
virtual void put(const string& s)
;
virtual void put(const LongSize p)
;
virtual void get(char& c)
;
virtual void get(Byte& c)
;
virtual void get(Index& s)
;
virtual void get(Size& s)
;
virtual void get(bool& b)
;
virtual void get(Real& f)
;
virtual void get(DoubleReal& d)
;
virtual void get(string& s)
;
virtual void get(LongSize& p)
;
void setHandleStreamsExternally(bool handle_externally);
private:
XDR xdr_in_;
XDR xdr_out_;
bool streams_handled_externally_;
};
} // namespace BALL
#endif // BALL_CONCEPT_XDRPERSISTENCEMANAGER_H
BALL_EXPORT
#define BALL_EXPORT
Definition COMMON/global.h:50
BALL::PersistenceManager::PersistenceManager
PersistenceManager()
BALL::String
Definition string.h:57
BALL::XDRPersistenceManager::checkStreamTrailer
virtual bool checkStreamTrailer()
BALL::XDRPersistenceManager::writeStreamTrailer
virtual void writeStreamTrailer()
BALL::XDRPersistenceManager::checkPrimitiveHeader
virtual bool checkPrimitiveHeader(const char *type_name, const char *name)
BALL::XDRPersistenceManager::initializeOutputStream
virtual void initializeOutputStream()
BALL::XDRPersistenceManager::writeObjectReferenceHeader
virtual void writeObjectReferenceHeader(const char *type_name, const char *name)
BALL::XDRPersistenceManager::writeObjectPointerArrayHeader
virtual void writeObjectPointerArrayHeader(const char *type_name, const char *name, Size size)
BALL::XDRPersistenceManager::checkStorableHeader
virtual bool checkStorableHeader(const char *type_name, const char *name)
BALL::XDRPersistenceManager::get
virtual void get(char &c)
BALL::XDRPersistenceManager::writeHeader
virtual void writeHeader(const char *type_name, const char *name, LongSize ptr)
BALL::XDRPersistenceManager::finalizeInputStream
virtual void finalizeInputStream()
BALL::XDRPersistenceManager::writeName
virtual void writeName(const char *name)
BALL::XDRPersistenceManager::XDRPersistenceManager
XDRPersistenceManager(std::ostream &os)
BALL::XDRPersistenceManager::get
virtual void get(DoubleReal &d)
BALL::XDRPersistenceManager::get
virtual void get(string &s)
BALL::XDRPersistenceManager::STREAM_HEADER
static const Size STREAM_HEADER
Definition XDRPersistenceManager.h:34
BALL::XDRPersistenceManager::XDRPersistenceManager
XDRPersistenceManager(std::istream &is, std::ostream &os)
BALL::XDRPersistenceManager::writePrimitiveHeader
virtual void writePrimitiveHeader(const char *type_name, const char *name)
BALL::XDRPersistenceManager::put
virtual void put(const LongSize p)
BALL::XDRPersistenceManager::checkStorableTrailer
virtual bool checkStorableTrailer()
BALL::XDRPersistenceManager::writeStorableHeader
virtual void writeStorableHeader(const char *type_name, const char *name)
BALL::XDRPersistenceManager::OBJECT_HEADER
static const Size OBJECT_HEADER
Definition XDRPersistenceManager.h:42
BALL::XDRPersistenceManager::checkObjectPointerArrayTrailer
virtual bool checkObjectPointerArrayTrailer()
BALL::XDRPersistenceManager::put
virtual void put(const DoubleReal d)
BALL::XDRPersistenceManager::put
virtual void put(const Size s)
BALL::XDRPersistenceManager::initializeInputStream
virtual void initializeInputStream()
BALL::XDRPersistenceManager::checkStreamHeader
virtual bool checkStreamHeader()
BALL::XDRPersistenceManager::put
virtual void put(const string &s)
BALL::XDRPersistenceManager::writeStorableTrailer
virtual void writeStorableTrailer()
BALL::XDRPersistenceManager::put
virtual void put(const bool b)
BALL::XDRPersistenceManager::get
virtual void get(Real &f)
BALL::XDRPersistenceManager::checkObjectPointerArrayHeader
virtual bool checkObjectPointerArrayHeader(const char *type_name, const char *name, Size &size)
BALL::XDRPersistenceManager::STREAM_TRAILER
static const Size STREAM_TRAILER
Definition XDRPersistenceManager.h:38
BALL::XDRPersistenceManager::put
virtual void put(const char c)
BALL::XDRPersistenceManager::checkPrimitiveTrailer
virtual bool checkPrimitiveTrailer()
BALL::XDRPersistenceManager::XDRPersistenceManager
XDRPersistenceManager()
BALL::XDRPersistenceManager::put
virtual void put(const Index i)
BALL::XDRPersistenceManager::XDRPersistenceManager
XDRPersistenceManager(std::istream &is)
BALL::XDRPersistenceManager::writePrimitiveTrailer
virtual void writePrimitiveTrailer()
BALL::XDRPersistenceManager::get
virtual void get(LongSize &p)
BALL::XDRPersistenceManager::setHandleStreamsExternally
void setHandleStreamsExternally(bool handle_externally)
BALL::XDRPersistenceManager::getObjectHeader
virtual bool getObjectHeader(String &type_name, LongSize &ptr)
BALL::XDRPersistenceManager::get
virtual void get(Index &s)
BALL::XDRPersistenceManager::finalizeOutputStream
virtual void finalizeOutputStream()
BALL::XDRPersistenceManager::writeTrailer
virtual void writeTrailer(const char *name=0)
BALL::XDRPersistenceManager::checkName
virtual bool checkName(const char *name)
BALL::XDRPersistenceManager::put
virtual void put(const Real f)
BALL::XDRPersistenceManager::get
virtual void get(Byte &c)
BALL::XDRPersistenceManager::get
virtual void get(Size &s)
BALL::XDRPersistenceManager::checkTrailer
virtual bool checkTrailer(const char *name=0)
BALL::XDRPersistenceManager::checkObjectReferenceHeader
virtual bool checkObjectReferenceHeader(const char *type_name, const char *name)
BALL::XDRPersistenceManager::writeObjectPointerHeader
virtual void writeObjectPointerHeader(const char *type_name, const char *name)
BALL::XDRPersistenceManager::get
virtual void get(bool &b)
BALL::XDRPersistenceManager::checkHeader
virtual bool checkHeader(const char *type_name, const char *name, LongSize &ptr)
BALL::XDRPersistenceManager::writeStreamHeader
virtual void writeStreamHeader()
BALL::XDRPersistenceManager::put
virtual void put(const Byte b)
BALL::XDRPersistenceManager::checkObjectPointerHeader
virtual bool checkObjectPointerHeader(const char *type_name, const char *name)
BALL::XDRPersistenceManager::OBJECT_TRAILER
static const Size OBJECT_TRAILER
Definition XDRPersistenceManager.h:46
BALL::XDRPersistenceManager::writeObjectPointerArrayTrailer
virtual void writeObjectPointerArrayTrailer()
BALL
Definition constants.h:13
BALL::Size
BALL_SIZE_TYPE Size
Definition COMMON/global.h:114
BALL::DoubleReal
double DoubleReal
Definition COMMON/global.h:156
BALL::LongSize
BALL_ULONG64_TYPE LongSize
Definition COMMON/global.h:192
BALL::Byte
unsigned char Byte
Definition COMMON/global.h:183
BALL::Index
BALL_INDEX_TYPE Index
Definition COMMON/global.h:105
BALL::Real
float Real
Definition COMMON/global.h:148
persistenceManager.h