28 #ifndef _util_group_mstate_h
29 #define _util_group_mstate_h
31 #include <util/state/state.h>
32 #include <util/state/statein.h>
33 #include <util/state/stateout.h>
34 #include <util/group/message.h>
55 int put_array_void(
const void*,
int);
61 virtual void flush() = 0;
70 int put(
const std::string&);
72 int put(
unsigned int r);
74 int put(
unsigned long r);
79 int put(
const char*,
int);
80 int put(
const int*,
int);
81 int put(
const unsigned int*,
int);
82 int put(
const long*,
int);
83 int put(
const unsigned long*,
int);
84 int put(
const float*,
int);
85 int put(
const double*,
int);
106 int get_array_void(
void*,
int);
144 int get(std::string&);
145 int get(
char&r,
const char *key = 0);
146 int get(
unsigned int&r,
const char *key = 0);
147 int get(
int&r,
const char *key = 0);
148 int get(
unsigned long&r,
const char *key = 0);
149 int get(
long&r,
const char *key = 0);
150 int get(
bool&r,
const char *key = 0);
151 int get(
float&r,
const char *key = 0);
152 int get(
double&r,
const char *key = 0);
154 int get(
unsigned int*&);
156 int get(
unsigned long*&);
272 void bcast(
double &);
273 void bcast(
int *&,
int);
274 void bcast(
double *&,
int);
275 template <
class T>
void bcast(
Ref<T>&a)
309 std::streambuf *buf_;
312 int get_array_void(
void*,
int);
321 virtual int open(
const char *name);
322 virtual void close();
The MsgStateSend is an abstract base class that sends objects to nodes in a MessageGrp.
Definition: mstate.h:41
void next_buffer()
Specializations must implement next_buffer().
virtual void next_buffer()=0
Specializations must implement next_buffer().
int use_directory()
Returns true of this object uses a directory.
BcastStateRecv does the receive part of a broadcast of an object to all nodes.
Definition: mstate.h:238
void next_buffer()
Specializations must implement next_buffer().
A template class that maintains references counts.
Definition: ref.h:361
int version(const ClassDesc *)
Returns the version of the ClassDesc.
The MsgStateBufRecv is an abstract base class that buffers objects sent through a MessageGrp.
Definition: mstate.h:91
void set_buffer_size(int)
The buffer size of statein and stateout objects that communicate with each other must match.
void type(int)
Specify the type.
void set_buffer_size(int)
The buffer size of statein and stateout objects that communicate with each other must match.
T * pointer() const
Returns a pointer the reference counted object.
Definition: ref.h:413
int last_source()
Return the source of the last message received.
BcastState(const Ref< MessageGrp > &, int source=0)
Create a BcastState object. The default source is node 0.
int put(const ClassDesc *)
I only need to override put(const ClassDesc*) but C++ will hide all of the other put's so I must over...
MsgStateBufRecv()
Use the default MessageGrp.
StateRecv is a concrete specialization of MsgStateRecv that does the receive part of point to point c...
Definition: mstate.h:193
void flush()
Force data to be written.
int tell()
Return the current position in the file.
void flush()
Flush the data remaining in the buffer.
StateSend is a concrete specialization of MsgStateSend that does the send part of point to point comm...
Definition: mstate.h:165
void next_buffer()
Specializations must implement next_buffer().
This class is used to contain information about classes.
Definition: class.h:147
void flush()
Flush the buffer.
void forget_references()
Call the StateOut or StateIn forget_references member.
void type(int)
Specify the message type.
BcastStateBin reads a file in written by StateInBin on node 0 and broadcasts it to all nodes so state...
Definition: mstate.h:301
static SavableState * restore_state(StateIn &si)
Restores objects saved with save_state.
void target(int)
Specify the target node.
The MsgStateRecv is an abstract base class that receives objects from nodes in a MessageGrp.
Definition: mstate.h:125
int get_type() const
Return the type.
Definition: mstate.h:185
int get_target() const
Return the target.
Definition: mstate.h:181
virtual void flush()=0
Specializations must implement flush().
int seekable()
Return non-zero if seek does anything sensible.
Definition: stateout.h:71
void save_state(StateOut &)
Save the state of the object as specified by the StateOut object.
BcastStateSend does the send part of a broadcast of an object to all nodes.
Definition: mstate.h:221
int last_type()
Return the type of the last message received.
void source(int s)
Set the source node.
void seek(int loc)
Set the current position in the file.
void source(int)
Specify the source node.
This creates and forwards/retrieves data from either a BcastStateRecv or a BcastStateSend depending o...
Definition: mstate.h:256
Contains all MPQC code up to version 3.
Definition: mpqcin.h:14
void set_buffer_size(int)
Controls the amount of data that is buffered before it is sent.
int get(const ClassDesc **)
I only need to override get(ClassDesc**) but C++ will hide all of the other get's so I must override ...
Generated at Sun Jan 26 2020 23:24:01 for MPQC
3.0.0-alpha using the documentation package Doxygen
1.8.16.