32 #ifndef _util_group_mstate_h
33 #define _util_group_mstate_h
35 #include <util/state/state.h>
36 #include <util/state/statein.h>
37 #include <util/state/stateout.h>
38 #include <util/group/message.h>
59 int put_array_void(
const void*,
int);
65 virtual void flush() = 0;
75 int put(
unsigned int r);
79 int put(
const char*,
int);
80 int put(
const int*,
int);
81 int put(
const unsigned int*,
int);
82 int put(
const float*,
int);
83 int put(
const double*,
int);
104 int get_array_void(
void*,
int);
142 int get(
char&r,
const char *key = 0);
143 int get(
unsigned int&r,
const char *key = 0);
144 int get(
int&r,
const char *key = 0);
145 int get(
float&r,
const char *key = 0);
146 int get(
double&r,
const char *key = 0);
148 int get(
unsigned int*&);
246 void bcast(
double &);
247 void bcast(
int *&,
int);
248 void bcast(
double *&,
int);
282 std::streambuf *buf_;
285 int get_array_void(
void*,
int);
294 virtual int open(
const char *name);
295 virtual void close();
The MsgStateSend is an abstract base class that sends objects to nodes in a MessageGrp.
Definition: mstate.h:45
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:214
void bcast(int &)
Broadcast data to all nodes.
void next_buffer()
Specializations must implement next_buffer().
A template class that maintains references counts.
Definition: ref.h:332
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:89
void set_buffer_size(int)
The buffer size of statein and stateout objects that communicate with each other must match.
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:383
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:178
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:157
void next_buffer()
Specializations must implement next_buffer().
Restores objects that derive from SavableState.
Definition: statein.h:70
This class is used to contain information about classes.
Definition: class.h:158
void flush()
Flush the buffer.
void forget_references()
Call the StateOut or StateIn forget_references member.
BcastStateBin reads a file in written by StateInBin on node 0 and broadcasts it to all nodes so state...
Definition: mstate.h:274
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:123
virtual void flush()=0
Specializations must implement flush().
int seekable()
Return non-zero if seek does anything sensible.
Serializes objects that derive from SavableState.
Definition: stateout.h:61
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:197
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:232
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:33:04 for MPQC
2.3.1 using the documentation package Doxygen
1.8.16.