MULTIBODY SIMULATION SOFTWARE - API documentation

chrono::ChBinaryArchive Class Reference

#include <CHstream.h>

Inheritance diagram for chrono::ChBinaryArchive:

Inheritance graph
[legend]

List of all members.

Public Member Functions

bool IsBigEndianMachine ()
void Init ()
int PutPointer (void *object)

Protected Attributes

bool big_endian_machine
std::vector< void * > objects_pointers


Detailed Description

Base class for streams (either in or out) based on binary formats. This class implements a basic functionality about platform-independent treatment of data (the big-endian/little-endian issue). Also this class implements functionality to avoid storing multiple times the same object (persistent data archive).

Member Function Documentation

bool chrono::ChBinaryArchive::IsBigEndianMachine (  ) 

Returns TRUE if the machine where the code runs has big endian byte ordering, returns FALSE otherwise.

void chrono::ChBinaryArchive::Init (  ) 

Reinitialize the vector of pointers to loaded/saved objects.

int chrono::ChBinaryArchive::PutPointer ( void *  object  ) 

Put a pointer in pointer vector, but only if it was not previously interted. Returns position of pointer if already existing, otherwise -1.


Member Data Documentation

std::vector<void*> chrono::ChBinaryArchive::objects_pointers [protected]

vector of pointers to stored/retrieved objects, to avoid saving duplicates or deadlocks


CHRONO::ENGINE
C++ library for multibody simulation, (C) Alessandro Tasora
This API documentation has been generated on 17 Jul 2009 by Doxygen