MBDyn-1.7.3
|
#include <extedge.h>
Public Member Functions | |
ExtFileHandlerEDGE (std::string &fflagname, std::string &fdataname, mbsleep_t SleepTime, std::streamsize Precision) | |
~ExtFileHandlerEDGE (void) | |
virtual bool | Prepare_pre (void) |
virtual void | Prepare_post (bool ok) |
virtual void | AfterPredict (void) |
virtual bool | Send_pre (SendWhen when) |
virtual void | Send_post (SendWhen when) |
virtual bool | Recv_pre (void) |
virtual bool | Recv_post (void) |
virtual std::ostream * | GetOutStream (void) |
virtual std::istream * | GetInStream (void) |
Public Member Functions inherited from ExtFileHandlerBase | |
ExtFileHandlerBase (mbsleep_t SleepTime, std::streamsize Precision) | |
virtual | ~ExtFileHandlerBase (void) |
virtual Negotiate | NegotiateRequest (void) const |
virtual int | GetOutFileDes (void) |
virtual int | GetSendFlags (void) const |
virtual int | GetInFileDes (void) |
virtual int | GetRecvFlags (void) const |
Protected Types | |
enum | EDGEcmd { EDGE_UNKNOWN = -1, EDGE_INITIALIZING = 0, EDGE_BUSY = 1, EDGE_READ_READY = 2, EDGE_MBDYN_WRITE_DONE = 3, EDGE_GOTO_NEXT_STEP = 4, EDGE_QUIT = 5, EDGE_LAST } |
Protected Member Functions | |
const char * | EDGEcmd2str (int cmd) const |
EDGEcmd | CheckFlag (int &cnt) |
void | SendFlag (EDGEcmd cmd) |
Protected Attributes | |
std::string | fflagname |
std::string | fdataname |
bool | bReadForces |
std::ifstream | infile |
std::ofstream | outfile |
Protected Attributes inherited from ExtFileHandlerBase | |
std::streamsize | Precision |
mbsleep_t | SleepTime |
bool | bOK |
Additional Inherited Members | |
Public Types inherited from ExtFileHandlerBase | |
enum | SendWhen { SEND_FIRST_TIME, SEND_REGULAR, SEND_AFTER_CONVERGENCE } |
enum | Negotiate { NEGOTIATE_NO, NEGOTIATE_CLIENT, NEGOTIATE_SERVER } |
enum | OutputFlags { OUTPUT_KIN = 0x1000, OUTPUT_DYN = 0x2000, OUTPUT_REF = 0x4000, OUTPUT_REF_KIN = (OUTPUT_REF | OUTPUT_KIN), OUTPUT_REF_DYN = (OUTPUT_REF | OUTPUT_DYN) } |
|
protected |
Enumerator | |
---|---|
EDGE_UNKNOWN | |
EDGE_INITIALIZING | |
EDGE_BUSY | |
EDGE_READ_READY | |
EDGE_MBDYN_WRITE_DONE | |
EDGE_GOTO_NEXT_STEP | |
EDGE_QUIT | |
EDGE_LAST |
Definition at line 49 of file extedge.h.
ExtFileHandlerEDGE::ExtFileHandlerEDGE | ( | std::string & | fflagname, |
std::string & | fdataname, | ||
mbsleep_t | SleepTime, | ||
std::streamsize | Precision | ||
) |
Definition at line 135 of file extedge.cc.
References NO_OP.
ExtFileHandlerEDGE::~ExtFileHandlerEDGE | ( | void | ) |
Definition at line 144 of file extedge.cc.
References CheckFlag(), EDGE_GOTO_NEXT_STEP, EDGE_QUIT, EDGE_READ_READY, and SendFlag().
|
virtual |
|
protected |
Definition at line 179 of file extedge.cc.
References buf, done, EDGE_QUIT, EDGEcmd2str(), fflagname, infile, MBDYN_EXCEPT_ARGS, mbdyn_stop_at_end_of_iteration(), mbedge_eat_field(), mbedge_eat_sep(), mbedge_goto_eol(), mbsleep(), ExtFileHandlerBase::SleepTime, and STRLENOF.
Referenced by Recv_pre(), Send_pre(), and ~ExtFileHandlerEDGE().
|
protected |
Definition at line 169 of file extedge.cc.
References EDGE_LAST.
Referenced by CheckFlag(), Recv_pre(), Send_pre(), and SendFlag().
|
virtual |
Reimplemented from ExtFileHandlerBase.
Definition at line 749 of file extedge.cc.
References infile.
|
virtual |
Reimplemented from ExtFileHandlerBase.
Definition at line 743 of file extedge.cc.
References outfile.
|
virtual |
|
virtual |
Implements ExtFileHandlerBase.
Definition at line 562 of file extedge.cc.
|
virtual |
Implements ExtFileHandlerBase.
Definition at line 733 of file extedge.cc.
References bReadForces, and infile.
|
virtual |
Implements ExtFileHandlerBase.
Definition at line 668 of file extedge.cc.
References bReadForces, CheckFlag(), done, EDGE_GOTO_NEXT_STEP, EDGE_QUIT, EDGE_READ_READY, EDGEcmd2str(), fdataname, fflagname, infile, MBDYN_EXCEPT_ARGS, mbdyn_set_stop_at_end_of_time_step(), mbdyn_stop_at_end_of_iteration(), mbsleep(), and ExtFileHandlerBase::SleepTime.
|
virtual |
Implements ExtFileHandlerBase.
Definition at line 638 of file extedge.cc.
References bReadForces, EDGE_MBDYN_WRITE_DONE, outfile, ExtFileHandlerBase::SEND_AFTER_CONVERGENCE, and SendFlag().
Implements ExtFileHandlerBase.
Definition at line 580 of file extedge.cc.
References bReadForces, CheckFlag(), EDGE_BUSY, EDGE_GOTO_NEXT_STEP, EDGE_INITIALIZING, EDGE_READ_READY, EDGE_UNKNOWN, EDGEcmd2str(), fdataname, fflagname, MBDYN_EXCEPT_ARGS, mbdyn_stop_at_end_of_iteration(), mbsleep(), outfile, ExtFileHandlerBase::Precision, and ExtFileHandlerBase::SleepTime.
|
protected |
Definition at line 509 of file extedge.cc.
References EDGEcmd2str(), fdataname, fflagname, MBDYN_EXCEPT_ARGS, mbdyn_stop_at_end_of_iteration(), mbsleep(), mbsleep_init(), and timeout.
Referenced by Send_post(), and ~ExtFileHandlerEDGE().
|
protected |
Definition at line 44 of file extedge.h.
Referenced by AfterPredict(), Recv_post(), Recv_pre(), Send_post(), and Send_pre().
|
protected |
Definition at line 43 of file extedge.h.
Referenced by Recv_pre(), Send_pre(), and SendFlag().
|
protected |
Definition at line 43 of file extedge.h.
Referenced by CheckFlag(), Recv_pre(), Send_pre(), and SendFlag().
|
protected |
Definition at line 46 of file extedge.h.
Referenced by CheckFlag(), GetInStream(), Recv_post(), and Recv_pre().
|
protected |
Definition at line 47 of file extedge.h.
Referenced by GetOutStream(), Send_post(), and Send_pre().