![]() |
MAK RTIspy API Documentation for HLA Evolved
|
Distributes fomModule files from initiating federate to RtiExec and then from RtiExec to all joining federates. More...
Inheritance diagram for DtFileDistributor:
Collaboration diagram for DtFileDistributor:Public Member Functions | |
| virtual bool | sendFedFile (const std::vector< MAKRti::DtString > &modules) |
| Override sendFedFile upload fed files passed in. More... | |
| virtual bool | pushFedFile (DtConnectionMgr *connMgr, const MAKRti::DtString &fileName, const unsigned int fileSize, const char *fileBuffer, const DtFederateHandle destination=0) |
| pushFedFile More... | |
| virtual void | fedFileUploaded (const MAKRti::DtString fileUploaded) |
| Called when Fom Module received successfully. More... | |
| virtual bool | fileReceived (const DtFomModuleDistributionMsg &msg, bool &areAllHere) |
| virtual bool | fileRequested (const DtFomModuleRequestMsg &msg) |
| virtual void | removeFile (const MAKRti::DtString fileName) |
| Remove all knowledge of this file from myFiles. More... | |
| virtual void | removeFiles (const std::vector< MAKRti::DtString > &modules) |
| Remove all knowledge of these file from myFiles. More... | |
| virtual bool | fedFileReady (const MAKRti::DtString &fileName) const |
| Does the distributor have a valid copy of this fom Module. More... | |
| virtual bool | fedFilesReady (const std::vector< MAKRti::DtString > *fileNames) const |
| Does the distributor have a valid copy of all of these fom Modules. More... | |
| const FILE * | fedFilePtr (MAKRti::DtString fileName) const |
| Get the fed file pointer. More... | |
| const char * | fedFileBuff (MAKRti::DtString fileName) const |
| Get the fed file buffer. More... | |
| DtFileInformation * | takeFedFile (MAKRti::DtString fileName) |
| Take ownership of the file. More... | |
| unsigned int | fileSize (MAKRti::DtString fileName) const |
| FILE * | getTmpFile () |
| void | setFedHandle (unsigned int newHandle) |
| Set the Fed Handle of the distributor. More... | |
| void | setFedexHandle (unsigned int newHandle) |
| bool | requestsPending () const |
| Are there outstanding requests to be handled? More... | |
Static Public Member Functions | |
| static void | setCreatorFunction (DtFileDistributorCreator fn) |
Protected Types | |
| typedef std::list< DtRtiMsg * > | rtiMsgList |
Protected Member Functions | |
| DtFileDistributor (const int fedExHandle, const int federateHandle, const MAKRti::DtString &fedExName) | |
| Constructor. More... | |
| virtual | ~DtFileDistributor () |
| Destructor. More... | |
Protected Attributes | |
| std::map< MAKRti::DtString, DtFileInformation * > | myFiles |
| Map between files that have been uploaded to me and their 'file names'. More... | |
| std::set< std::pair < DtFederateHandle, MAKRti::DtString > > | myPendingRequests |
| MAKRti::DtString | myFedExName |
| int | myFedExHandle |
| int | myFederateHandle |
| std::map< MAKRti::DtString, FILE * > | myTempFileHandles |
Static Protected Attributes | |
| static DtFileDistributorCreator | theCreator |
Private Member Functions | |
| DtFileDistributor () | |
| DtFileDistributor (const DtFileDistributor &orig) | |
| DtFileDistributor & | operator= (const DtFileDistributor &orig) |
Distributes fomModule files from initiating federate to RtiExec and then from RtiExec to all joining federates.
|
protected |
|
protected |
Constructor.
|
protectedvirtual |
Destructor.
|
private |
|
private |
| const char* DtFileDistributor::fedFileBuff | ( | MAKRti::DtString | fileName | ) | const |
Get the fed file buffer.
| const FILE* DtFileDistributor::fedFilePtr | ( | MAKRti::DtString | fileName | ) | const |
Get the fed file pointer.
|
virtual |
Does the distributor have a valid copy of this fom Module.
|
virtual |
Does the distributor have a valid copy of all of these fom Modules.
|
virtual |
Called when Fom Module received successfully.
|
virtual |
|
virtual |
| unsigned int DtFileDistributor::fileSize | ( | MAKRti::DtString | fileName | ) | const |
| FILE* DtFileDistributor::getTmpFile | ( | ) |
|
private |
|
virtual |
pushFedFile
|
virtual |
Remove all knowledge of this file from myFiles.
|
virtual |
Remove all knowledge of these file from myFiles.
| bool DtFileDistributor::requestsPending | ( | ) | const |
Are there outstanding requests to be handled?
|
virtual |
Override sendFedFile upload fed files passed in.
Reimplemented in DtSynchronousFileDistributor.
|
static |
| void DtFileDistributor::setFedexHandle | ( | unsigned int | newHandle | ) |
| void DtFileDistributor::setFedHandle | ( | unsigned int | newHandle | ) |
Set the Fed Handle of the distributor.
Because federates will use the distributor before they're joined, they'll need to reassign from the connectHandle to their Fed Handle once they're joined.
| DtFileInformation* DtFileDistributor::takeFedFile | ( | MAKRti::DtString | fileName | ) |
Take ownership of the file.
retVal will be zero if file not complete (or nonexistent)
|
protected |
|
protected |
|
protected |
|
protected |
Map between files that have been uploaded to me and their 'file names'.
|
protected |
|
protected |
|
staticprotected |