#include <tbox/StatTransaction.h>
A stattistic transaction represents a simple copy communication transaction between two processors for sending and gathering statistic information generated on different processors.
- See also
- tbox::Schedule
-
tbox::Transaction
◆ StatTransaction() [1/2]
| SAMRAI::tbox::StatTransaction::StatTransaction |
( |
Pointer< Statistic > |
stat, |
|
|
int |
src_proc_id, |
|
|
int |
dst_proc_id |
|
) |
| |
Create a transaction for communicating local statistic information. This transaction will be responsible for either: (1) packing a message stream with statistic information if this processor number is the same as the given source processor id, or (2) unpacking tatistic information from the message stream if this processor number is the same as the given destination processor. The statistic pointer passed in through the argument list must be non-null and will be used as either the source or destination statistic depending on whether case (1) or (2) applies.
Note that generally this transaction class is used to pass information between two different processors and unexpected behavior may result if the source and destination processors are the same. Also, note that the copyLocalData() routine has an empty implementation.
◆ ~StatTransaction()
| virtual SAMRAI::tbox::StatTransaction::~StatTransaction |
( |
| ) |
|
|
virtual |
The virtual destructor for the copy transaction releases all memory associated with the transaction.
◆ StatTransaction() [2/2]
◆ canEstimateIncomingMessageSize()
| virtual bool SAMRAI::tbox::StatTransaction::canEstimateIncomingMessageSize |
( |
| ) |
|
|
virtual |
Return a boolean indicating whether this transaction can estimate the size of an incoming message. If this is false, then a different communications protocol kicks in and the message size is transmitted between nodes.
Implements SAMRAI::tbox::Transaction.
◆ computeIncomingMessageSize()
| virtual int SAMRAI::tbox::StatTransaction::computeIncomingMessageSize |
( |
| ) |
|
|
virtual |
Return the amount of buffer space needed for the incoming message. This routine is only called if the transaction can estimate the size of the incoming message.
Implements SAMRAI::tbox::Transaction.
◆ computeOutgoingMessageSize()
| virtual int SAMRAI::tbox::StatTransaction::computeOutgoingMessageSize |
( |
| ) |
|
|
virtual |
◆ getSourceProcessor()
| virtual int SAMRAI::tbox::StatTransaction::getSourceProcessor |
( |
| ) |
|
|
virtual |
◆ getDestinationProcessor()
| virtual int SAMRAI::tbox::StatTransaction::getDestinationProcessor |
( |
| ) |
|
|
virtual |
◆ packStream()
| virtual void SAMRAI::tbox::StatTransaction::packStream |
( |
AbstractStream & |
stream | ) |
|
|
virtual |
◆ unpackStream()
| virtual void SAMRAI::tbox::StatTransaction::unpackStream |
( |
AbstractStream & |
stream | ) |
|
|
virtual |
◆ copyLocalData()
| virtual void SAMRAI::tbox::StatTransaction::copyLocalData |
( |
| ) |
|
|
virtual |
Perform the local data copy for the transaction. This function drops through as it is not needed.
Implements SAMRAI::tbox::Transaction.
◆ printClassData()
| virtual void SAMRAI::tbox::StatTransaction::printClassData |
( |
std::ostream & |
stream | ) |
const |
|
virtual |
◆ operator=()
◆ d_stat
◆ d_src_id
| int SAMRAI::tbox::StatTransaction::d_src_id |
|
private |
◆ d_dst_id
| int SAMRAI::tbox::StatTransaction::d_dst_id |
|
private |
The documentation for this class was generated from the following file: