|
OOFEM
2.1
|
The purpose of DataStream abstract class is to allow to store/restore context to different streams, including file, communication buffers, etc., using the same routine. More...
#include <datastream.h>
Inheritance diagram for oofem::DataStream:Public Member Functions | |
| virtual | ~DataStream () |
| Destructor. | |
Data Stream reading methods. | |
These methods read "count" values from data stream into array passed as the first argument. All functions return nonzero if successful. | |
| virtual int | read (int *data, unsigned int count)=0 |
| Reads count integer values into array pointed by data. | |
| virtual int | read (unsigned long *data, unsigned int count)=0 |
| Reads count unsigned long values into array pointed by data. | |
| virtual int | read (long *data, unsigned int count)=0 |
| Reads count long values into array pointed by data. | |
| virtual int | read (double *data, unsigned int count)=0 |
| Reads count double values into array pointed by data. | |
| virtual int | read (char *data, unsigned int count)=0 |
| Reads count char values into array pointed by data. | |
| virtual int | read (bool *data, unsigned int count)=0 |
| Reads count bool values into array pointed by data. | |
| int | read (std::string &data) |
| Reads a string (stored as an int for the length followed by char*). | |
Data Stream writing methods. | |
These methods write "count" values of data into stream. All functions return nonzero if successful. | |
| virtual int | write (const int *data, unsigned int count)=0 |
| Writes count integer values from array pointed by data. | |
| virtual int | write (const unsigned long *data, unsigned int count)=0 |
| Writes count unsigned long values from array pointed by data. | |
| virtual int | write (const long *data, unsigned int count)=0 |
| Writes count long values from array pointed by data. | |
| virtual int | write (const double *data, unsigned int count)=0 |
| Writes count double values from array pointed by data. | |
| virtual int | write (const char *data, unsigned int count)=0 |
| Writes count char values from array pointed by data. | |
| virtual int | write (const bool *data, unsigned int count)=0 |
| Writes count bool values from array pointed by data. | |
| int | write (const std::string &data) |
| Reads a string (stored as an int for the length followed by char*). | |
The purpose of DataStream abstract class is to allow to store/restore context to different streams, including file, communication buffers, etc., using the same routine.
This will facilitate many algorithms relying on saving/moving state of components (such as load balancing), without writing new (and very similar) routines. This will lead to a better consistency of code.
Definition at line 53 of file datastream.h.
| virtual oofem::DataStream::~DataStream | ( | ) | [inline, virtual] |
Destructor.
Definition at line 57 of file datastream.h.
| virtual int oofem::DataStream::read | ( | int * | data, |
| unsigned int | count | ||
| ) | [pure virtual] |
Reads count integer values into array pointed by data.
Implemented in oofem::ProcessCommDataStream, oofem::ComBuffDataStream, and oofem::FileDataStream.
Referenced by read(), oofem::B3SolidMaterialStatus::restoreContext(), oofem::PatchIntegrationRule::restoreContext(), oofem::MazarsMaterialStatus::restoreContext(), oofem::MPSMaterialStatus::restoreContext(), oofem::BinghamFluidMaterial2Status::restoreContext(), oofem::Patch::restoreContext(), oofem::PlasticMaterialStatus::restoreContext(), oofem::CebFipSlip90MaterialStatus::restoreContext(), oofem::PerfectlyPlasticMaterialStatus::restoreContext(), oofem::DruckerPragerPlasticitySMStatus::restoreContext(), oofem::IsoInterfaceDamageMaterialStatus::restoreContext(), oofem::MPlasticMaterialStatus::restoreContext(), oofem::IsotropicDamageMaterial1Status::restoreContext(), oofem::RCSDEMaterialStatus::restoreContext(), oofem::RCSDMaterialStatus::restoreContext(), oofem::MPlasticMaterial2Status::restoreContext(), oofem::IDGMaterialStatus::restoreContext(), oofem::Dictionary::restoreContext(), oofem::TrabBone3DStatus::restoreContext(), oofem::PlastData::restoreContext(), oofem::Concrete2MaterialStatus::restoreContext(), oofem::HydrationModelStatus::restoreContext(), oofem::SimpleSlaveDof::restoreContext(), oofem::ConcreteDPMStatus::restoreContext(), oofem::LEPlicElementInterface::restoreContext(), oofem::NonLinearStatic::restoreContext(), oofem::HuertaErrorEstimator::restoreContext(), oofem::SlaveDof::restoreContext(), oofem::NlDEIDynamic::restoreContext(), oofem::XfemManager::restoreContext(), oofem::IsotropicDamageMaterialStatus::restoreContext(), oofem::ConcreteDPM2Status::restoreContext(), oofem::MasterDof::restoreContext(), oofem::LevelSetPCS::restoreContext(), oofem::NonisoData::restoreContext(), oofem::FEMComponent::restoreContext(), oofem::Node::restoreContext(), oofem::CylindricalALM::restoreContext(), oofem::TimeStep::restoreContext(), oofem::PrimaryField::restoreContext(), oofem::IntegrationRule::restoreContext(), oofem::MisesMatStatus::restoreContext(), oofem::RankineMatStatus::restoreContext(), oofem::DofManager::restoreContext(), oofem::Dof::restoreContext(), oofem::Domain::restoreContext(), oofem::HellmichMaterialStatus::restoreContext(), oofem::EngngModel::restoreContext(), oofem::Element::restoreContext(), oofem::StressStrainBaseVector::restoreYourself(), oofem::IntArray::restoreYourself(), oofem::FloatArray::restoreYourself(), and oofem::FloatMatrix::restoreYourself().
| virtual int oofem::DataStream::read | ( | unsigned long * | data, |
| unsigned int | count | ||
| ) | [pure virtual] |
Reads count unsigned long values into array pointed by data.
Implemented in oofem::ProcessCommDataStream, oofem::ComBuffDataStream, and oofem::FileDataStream.
| virtual int oofem::DataStream::read | ( | long * | data, |
| unsigned int | count | ||
| ) | [pure virtual] |
Reads count long values into array pointed by data.
Implemented in oofem::ProcessCommDataStream, oofem::ComBuffDataStream, and oofem::FileDataStream.
| virtual int oofem::DataStream::read | ( | double * | data, |
| unsigned int | count | ||
| ) | [pure virtual] |
Reads count double values into array pointed by data.
Implemented in oofem::ProcessCommDataStream, oofem::ComBuffDataStream, and oofem::FileDataStream.
| virtual int oofem::DataStream::read | ( | char * | data, |
| unsigned int | count | ||
| ) | [pure virtual] |
Reads count char values into array pointed by data.
Implemented in oofem::ProcessCommDataStream, oofem::ComBuffDataStream, and oofem::FileDataStream.
| virtual int oofem::DataStream::read | ( | bool * | data, |
| unsigned int | count | ||
| ) | [pure virtual] |
Reads count bool values into array pointed by data.
Implemented in oofem::ProcessCommDataStream, oofem::ComBuffDataStream, and oofem::FileDataStream.
| int oofem::DataStream::read | ( | std::string & | data | ) |
Reads a string (stored as an int for the length followed by char*).
Definition at line 43 of file datastream.C.
References read().
| virtual int oofem::DataStream::write | ( | const int * | data, |
| unsigned int | count | ||
| ) | [pure virtual] |
Writes count integer values from array pointed by data.
Implemented in oofem::ProcessCommDataStream, oofem::ComBuffDataStream, and oofem::FileDataStream.
Referenced by oofem::B3SolidMaterialStatus::saveContext(), oofem::PatchIntegrationRule::saveContext(), oofem::MazarsMaterialStatus::saveContext(), oofem::MPSMaterialStatus::saveContext(), oofem::BinghamFluidMaterial2Status::saveContext(), oofem::Patch::saveContext(), oofem::PlasticMaterialStatus::saveContext(), oofem::CebFipSlip90MaterialStatus::saveContext(), oofem::PerfectlyPlasticMaterialStatus::saveContext(), oofem::IsoInterfaceDamageMaterialStatus::saveContext(), oofem::DruckerPragerPlasticitySMStatus::saveContext(), oofem::MPlasticMaterialStatus::saveContext(), oofem::IsotropicDamageMaterial1Status::saveContext(), oofem::RCSDEMaterialStatus::saveContext(), oofem::RCSDMaterialStatus::saveContext(), oofem::MPlasticMaterial2Status::saveContext(), oofem::IDGMaterialStatus::saveContext(), oofem::Dictionary::saveContext(), oofem::TrabBone3DStatus::saveContext(), oofem::PlastData::saveContext(), oofem::Concrete2MaterialStatus::saveContext(), oofem::HydrationModelStatus::saveContext(), oofem::SimpleSlaveDof::saveContext(), oofem::LEPlicElementInterface::saveContext(), oofem::ConcreteDPMStatus::saveContext(), oofem::XfemManager::saveContext(), oofem::NonLinearStatic::saveContext(), oofem::HuertaErrorEstimator::saveContext(), oofem::SlaveDof::saveContext(), oofem::NlDEIDynamic::saveContext(), oofem::IsotropicDamageMaterialStatus::saveContext(), oofem::ConcreteDPM2Status::saveContext(), oofem::MasterDof::saveContext(), oofem::LevelSetPCS::saveContext(), oofem::FEMComponent::saveContext(), oofem::NonisoData::saveContext(), oofem::Node::saveContext(), oofem::TimeStep::saveContext(), oofem::CylindricalALM::saveContext(), oofem::PrimaryField::saveContext(), oofem::IntegrationRule::saveContext(), oofem::MisesMatStatus::saveContext(), oofem::RankineMatStatus::saveContext(), oofem::DofManager::saveContext(), oofem::Domain::saveContext(), oofem::Dof::saveContext(), oofem::HellmichMaterialStatus::saveContext(), oofem::EngngModel::saveContext(), oofem::Element::saveContext(), oofem::StressStrainBaseVector::storeYourself(), oofem::FloatArray::storeYourself(), oofem::FloatMatrix::storeYourself(), and write().
| virtual int oofem::DataStream::write | ( | const unsigned long * | data, |
| unsigned int | count | ||
| ) | [pure virtual] |
Writes count unsigned long values from array pointed by data.
Implemented in oofem::ProcessCommDataStream, oofem::ComBuffDataStream, and oofem::FileDataStream.
| virtual int oofem::DataStream::write | ( | const long * | data, |
| unsigned int | count | ||
| ) | [pure virtual] |
Writes count long values from array pointed by data.
Implemented in oofem::ProcessCommDataStream, oofem::ComBuffDataStream, and oofem::FileDataStream.
| virtual int oofem::DataStream::write | ( | const double * | data, |
| unsigned int | count | ||
| ) | [pure virtual] |
Writes count double values from array pointed by data.
Implemented in oofem::ProcessCommDataStream, oofem::ComBuffDataStream, and oofem::FileDataStream.
| virtual int oofem::DataStream::write | ( | const char * | data, |
| unsigned int | count | ||
| ) | [pure virtual] |
Writes count char values from array pointed by data.
Implemented in oofem::ProcessCommDataStream, oofem::ComBuffDataStream, and oofem::FileDataStream.
| virtual int oofem::DataStream::write | ( | const bool * | data, |
| unsigned int | count | ||
| ) | [pure virtual] |
Writes count bool values from array pointed by data.
Implemented in oofem::ProcessCommDataStream, oofem::ComBuffDataStream, and oofem::FileDataStream.
| int oofem::DataStream::write | ( | const std::string & | data | ) |
Reads a string (stored as an int for the length followed by char*).
Definition at line 56 of file datastream.C.
References write().