AGX Dynamics 2.40.1.2
Loading...
Searching...
No Matches
agxData::JournalArchive Class Referenceabstract

The JournalArchive provides an abstract class for inspecting and manipulating the contents of a created journal. More...

#include <JournalArchive.h>

+ Inheritance diagram for agxData::JournalArchive:

Public Types

typedef agxNet::StructuredMessage PlotData
 
typedef agx::ref_ptr< PlotDataPlotDataRef
 
typedef agx::Vector< PlotDataRefPlotDataRefVector
 
typedef agx::observer_ptr< const SessionSessionConstObserver
 
typedef agx::ref_ptr< const SessionSessionConstRef
 
typedef agx::observer_ptr< SessionSessionObserver
 
typedef agx::ref_ptr< SessionSessionRef
 
typedef agx::HashTable< agx::Name, agxData::JournalArchive::SessionRefSessionTable
 

Public Member Functions

bool copySession (agxData::JournalArchive::Session *session, agxData::JournalArchive *target)
 Copy the given session from this journal into the given target journal.
 
bool copyTo (agxData::JournalArchive *target)
 Copy the session to another JournalArchive.
 
virtual DiskFrameReadercreateFrameReader (agxData::JournalArchive::Session *session)=0
 
virtual DiskFrameWritercreateFrameWriter (agxData::JournalArchive::Session *session)=0
 
virtual agxData::JournalArchive::SessioncreateNewSession (const agx::Name &name)=0
 Create a new session with the given name.
 
virtual void finalizeHeader ()=0
 
agx::UInt32 getAgxVersionNumber () const
 
const agx::StringgetAgxVersionString () const
 
virtual void getAllPlots (PlotDataRefVector &result)=0
 
agx::Real64 getComputationTime () const
 
virtual agx::String getCustomFilesPath (bool create=true) const =0
 Returns the path to a disk directory where custom files related to the journal may be stored.
 
virtual agx::String getCustomFilesPath (bool create=true) const =0
 Get the path a disk directory where additional files related to the session may be stored.
 
virtual agx::String getCustomFilesPath (const agx::Name &sessionName, bool create=true) const =0
 Returns the path to a disk directory where custom files related to the given session may be stored.
 
const agx::DategetDate () const
 
agx::UInt64 getFirstFrameIndex () const
 
agx::Real64 getFirstFrameTimeStamp () const
 
virtual agxData::Frame::Header getFrameHeader (agx::UInt frameIndex) const =0
 Load the header data for a particular frame.
 
agxData::FrameIOgetFrameIO ()
 
agx::UInt64 getFrameStride () const
 
SerializedFrame::HeaderFormat getHeaderFormat () const
 
agxData::JournalArchivegetJournal ()
 
const agxData::JournalArchivegetJournal () const
 
agx::UInt64 getLastFrameIndex () const
 
agx::Real64 getLastFrameTimeStamp () const
 
const agx::NamegetName () const
 
const agx::NamegetName () const
 
virtual agx::UInt getNextFrameIndex (agx::UInt currentFrameIndex, agx::Int offset) const =0
 
agx::UInt64 getNumFrames () const
 
size_t getNumSessions () const
 
const agx::StringgetPath () const
 
virtual agx::String getPath () const =0
 Returns a format specific string that identifies the location of this session within a journal.
 
virtual PlotDatagetPlot (const agx::String &plotName)=0
 
virtual void getPlotList (agx::StringVector &result)=0
 
virtual agx::String getScenePath (bool create=true) const =0
 Get the path on disk where the .agx file, called the scene file, containing the initial state of the simulation may be stored.
 
agxData::JournalArchive::SessiongetSession (const agx::Name &name)
 
const agxData::JournalArchive::SessiongetSession (const agx::Name &name) const
 
const SessionTablegetSessions () const
 
agx::ComponentgetSimulationHeader ()
 
agx::Real64 getTimeStep () const
 
bool is64BitArchitecture () const
 
bool is64BitReal () const
 
bool isLittleEndian () const
 
bool isOwnerOf (const agxData::JournalArchive::Session *session) const
 
void listSessionNames (agx::Vector< agx::Name > &result) const
 Add to the end of the given Vector the names of all the sessions in the Journal.
 
virtual bool packSceneData (std::istream &sceneData)=0
 Copy the scene data found in the given stringstream into the journal in some format specific way.
 
virtual bool packSceneData (std::stringstream &sceneData)=0
 Copy the scene data found in the given stringstream into the journal in some format specific way.
 
virtual bool recordExtraData (const agx::String &key, const agx::String &value)=0
 Store a string key-value pair to the session on disk.
 
bool recordExtraDataAsJSon (const agx::String &key, const agx::String &value)
 Store a string key-value pair to the session on disk, without ruining the .
 
virtual void removePlot (const agx::String &plotName)=0
 
virtual bool removeSession (agxData::JournalArchive::Session *session)=0
 Remove the given session from the journal.
 
bool removeSession (const agx::Name &name)
 Remove the session with the given name from the journal.
 
virtual bool renameSession (agxData::JournalArchive::Session *session, const agx::Name &newName)=0
 Rename the given session to the given new name.
 
agx::String retrieveExtraData (const agx::String &key)
 
virtual bool retrieveExtraData (const agx::String &key, agx::String &value)=0
 Read back the value associated with the key from disk.
 
agx::String retrieveExtraDataAsJSon (const agx::String &key)
 
bool retrieveExtraDataAsJSon (const agx::String &key, agx::String &value)
 Read back the value associated with the key from disk.
 
virtual void savePlot (const PlotData *plot)=0
 
void set64BitArchitecture (bool flag)
 
void set64BitReal (bool flag)
 
void setAgxVersionNumber (const agx::UInt32 version)
 
void setAgxVersionString (const agx::String &version)
 
void setComputationTime (agx::Real64 computationTime)
 
void setDate (agx::Date *date)
 
void setFirstFrameIndex (agx::UInt64 startFrame)
 
void setFirstFrameTimeStamp (agx::Real64 startTime)
 
void setFrameIO (agxData::FrameIO *frameIO)
 
void setFrameStride (agx::UInt64 stride)
 
void setHeaderFormat (SerializedFrame::HeaderFormat format)
 Some journal formats support more than one format for frame metadata.
 
void setLastFrameIndex (agx::UInt64 endFrame)
 
void setLastFrameTimeStamp (agx::Real64 endTime)
 
void setLittleEndian (bool flag)
 
void setNumFrames (agx::UInt64 numFrames)
 
void setSimulationHeader (agx::Component *header)
 
void setTimeStep (agx::Real64 timeStep)
 
bool transferSession (agxData::JournalArchive::Session *session, agxData::JournalArchive *target)
 Transfer the given session from this journal into the given target.
 
bool transferTo (agxData::JournalArchive *target)
 Transfer the session to another JournalArchive. The target JournalArchive must be of the same correct type.
 
virtual bool truncate (agx::UInt firstFrameToRemove)=0
 Remove all frames from the given index and forward.
 
virtual bool unpackSceneData (std::ostream &sceneData)=0
 Copy scene data from the archive, stored in some format specific way, into the given stringstream.
 
virtual bool unpackSceneData (std::stringstream &sceneData)=0
 Copy scene data from the archive, stored in some format specific way, into the given stringstream.
 
virtual bool unpackSceneFile ()=0
 Ensure that the scene file for the session is available at the location returned by getScenePath.
 
virtual void writeHeader ()=0
 
- Public Member Functions inherited from agx::Referenced
 Referenced ()
 Default constructor.
 
 Referenced (const Referenced &)
 
template<typename T >
T * as ()
 Subclass casting.
 
template<typename T >
const T * as () const
 
template<typename T >
T * asSafe ()
 Safe subclass casting, return nullptr if template type does not match.
 
template<typename T >
const T * asSafe () const
 
int getReferenceCount () const
 
template<typename T >
bool is () const
 Subclass test.
 
Referencedoperator= (const Referenced &)
 Assignment operator. Will increment the number of references to the referenced object.
 
void reference (void *ptr=nullptr) const
 Explicitly increment the reference count by one, indicating that this object has another pointer which is referencing it.
 
void unreference (void *ptr=nullptr) const
 Decrement the reference count by one, indicating that a pointer to this object is referencing it.
 
void unreference_nodelete () const
 Decrement the reference count by one, indicating that a pointer to this object is referencing it.
 

Static Public Member Functions

static agx::String generateNameFromCurrentDate ()
 
- Static Public Member Functions inherited from agx::Referenced
template<typename T >
static bool ValidateCast (const Referenced *object)
 

Protected Member Functions

 JournalArchive ()
 
 JournalArchive (const agx::Name &name, const agx::String &path)
 
virtual ~JournalArchive ()
 
virtual ~Session ()
 
virtual agxData::JournalArchive::SessionmakeCopy (agxData::JournalArchive::Session *session)=0
 Create a copy of the given session. The copy will have its disk data stored in the current JournalArchive.
 
bool registerSession (agxData::JournalArchive::Session *newSession)
 Create the Journal <-> Session coupling.
 
bool rename (const agx::Name &name)
 
 Session (const agx::Name &name)
 
void setName (const agx::Name &name)
 
void setPath (const agx::String &path)
 
bool unregisterSession (agxData::JournalArchive::Session *removedSession)
 Remove the Journal <-> Session coupling.
 
bool updateSessionAndTableWithNewName (agxData::JournalArchive::Session *session, const agx::Name &newName)
 Change the name of the given session. Will ensure that the session table is kept consistent.
 
- Protected Member Functions inherited from agx::Referenced
virtual ~Referenced ()
 Destructor.
 
void allocateObserverVector () const
 
void deleteUsingDeleteHandler () const
 

Additional Inherited Members

- Static Protected Member Functions inherited from agx::Referenced
static DeleteHandlergetDeleteHandler ()
 
static void setDeleteHandler (DeleteHandler *handler)
 Internal: Set a DeleteHandler to which deletion of all referenced counted objects will be delegated to.
 
- Protected Attributes inherited from agx::Referenced
Mutex m_mutex
 
ObserverContainer m_observers
 
AtomicValue m_refCount
 

Detailed Description

The JournalArchive provides an abstract class for inspecting and manipulating the contents of a created journal.

Support for the various saved journal formats is provided by classes deriving from this one.

Definition at line 41 of file JournalArchive.h.

Member Typedef Documentation

◆ PlotData

◆ PlotDataRef

◆ PlotDataRefVector

◆ SessionConstObserver

◆ SessionConstRef

◆ SessionObserver

◆ SessionRef

◆ SessionTable

Constructor & Destructor Documentation

◆ JournalArchive() [1/2]

agxData::JournalArchive::JournalArchive ( const agx::Name name,
const agx::String path 
)
protected

◆ JournalArchive() [2/2]

agxData::JournalArchive::JournalArchive ( )
protected

◆ ~JournalArchive()

virtual agxData::JournalArchive::~JournalArchive ( )
protectedvirtual

◆ ~Session()

virtual agxData::JournalArchive::~Session ( )
protectedvirtual

Member Function Documentation

◆ copySession()

bool agxData::JournalArchive::copySession ( agxData::JournalArchive::Session session,
agxData::JournalArchive target 
)

Copy the given session from this journal into the given target journal.

The session must be owned by the current JournalArchive and the target must be of the same journal type, i.e, use the same disk format.

Parameters
sessionThe session to copy.
targetThe journal that should receive the copy.
Returns
True if the copy is successful, false otherwise.

◆ copyTo()

bool agxData::JournalArchive::copyTo ( agxData::JournalArchive target)

Copy the session to another JournalArchive.

The target JournalArchive must be of the same correct type. The result is the same as if "session->getJournal()->copySession(session, target)" had been called.

◆ createFrameReader()

virtual DiskFrameReader * agxData::JournalArchive::createFrameReader ( agxData::JournalArchive::Session session)
pure virtual

◆ createFrameWriter()

virtual DiskFrameWriter * agxData::JournalArchive::createFrameWriter ( agxData::JournalArchive::Session session)
pure virtual

◆ createNewSession()

virtual agxData::JournalArchive::Session * agxData::JournalArchive::createNewSession ( const agx::Name name)
pure virtual

Create a new session with the given name.

Returns
The session just created.

Implemented in agxData::FileJournal.

◆ finalizeHeader()

virtual void agxData::JournalArchive::finalizeHeader ( )
pure virtual

◆ generateNameFromCurrentDate()

static agx::String agxData::JournalArchive::generateNameFromCurrentDate ( )
static

◆ getAgxVersionNumber()

agx::UInt32 agxData::JournalArchive::getAgxVersionNumber ( ) const

◆ getAgxVersionString()

const agx::String & agxData::JournalArchive::getAgxVersionString ( ) const

◆ getAllPlots()

virtual void agxData::JournalArchive::getAllPlots ( PlotDataRefVector result)
pure virtual

◆ getComputationTime()

agx::Real64 agxData::JournalArchive::getComputationTime ( ) const

◆ getCustomFilesPath() [1/3]

virtual agx::String agxData::JournalArchive::getCustomFilesPath ( bool  create = true) const
pure virtual

Returns the path to a disk directory where custom files related to the journal may be stored.

The directory, including parents, is created if necessary if the 'create' argument is true.

Parameters
createIf true then missing directories in the returned path is created.
Returns
Path to custom files directory on disk.

Implemented in agxData::FileJournal.

◆ getCustomFilesPath() [2/3]

virtual agx::String agxData::JournalArchive::getCustomFilesPath ( bool  create = true) const
pure virtual

Get the path a disk directory where additional files related to the session may be stored.

Can create the folder structure if it does not yet exist.

Parameters
createIf true then the returned folder and its parents are created.
Returns
Path to a folder owned by this session.

Implemented in agxData::FileJournal.

◆ getCustomFilesPath() [3/3]

virtual agx::String agxData::JournalArchive::getCustomFilesPath ( const agx::Name sessionName,
bool  create = true 
) const
pure virtual

Returns the path to a disk directory where custom files related to the given session may be stored.

The directory, including parents, is created if necessary if the 'create' parameter is true. The given session name does not need to denote a session that is part of the journal. If not, then the returned path is the path that a sessions with the given name would have if such a session existed.

Parameters
sessionNameThe name of the session whose custom files path is needed.
Returns
Path to custom files directory on disk for the given session.

Implemented in agxData::FileJournal.

◆ getDate()

const agx::Date * agxData::JournalArchive::getDate ( ) const

◆ getFirstFrameIndex()

agx::UInt64 agxData::JournalArchive::getFirstFrameIndex ( ) const

◆ getFirstFrameTimeStamp()

agx::Real64 agxData::JournalArchive::getFirstFrameTimeStamp ( ) const

◆ getFrameHeader()

virtual agxData::Frame::Header agxData::JournalArchive::getFrameHeader ( agx::UInt  frameIndex) const
pure virtual

Load the header data for a particular frame.

◆ getFrameIO()

agxData::FrameIO * agxData::JournalArchive::getFrameIO ( )

◆ getFrameStride()

agx::UInt64 agxData::JournalArchive::getFrameStride ( ) const

◆ getHeaderFormat()

SerializedFrame::HeaderFormat agxData::JournalArchive::getHeaderFormat ( ) const

◆ getJournal() [1/2]

agxData::JournalArchive * agxData::JournalArchive::getJournal ( )
Returns
The JournalArchive that this session is part of.

◆ getJournal() [2/2]

const agxData::JournalArchive * agxData::JournalArchive::getJournal ( ) const
Returns
The JournalArchive that this session is part of.

◆ getLastFrameIndex()

agx::UInt64 agxData::JournalArchive::getLastFrameIndex ( ) const

◆ getLastFrameTimeStamp()

agx::Real64 agxData::JournalArchive::getLastFrameTimeStamp ( ) const

◆ getName() [1/2]

const agx::Name & agxData::JournalArchive::getName ( ) const
Returns
The name of the journal. This is often the same as the name of a file on disk.

◆ getName() [2/2]

const agx::Name & agxData::JournalArchive::getName ( ) const
Returns
The name of the session.

◆ getNextFrameIndex()

virtual agx::UInt agxData::JournalArchive::getNextFrameIndex ( agx::UInt  currentFrameIndex,
agx::Int  offset 
) const
pure virtual

◆ getNumFrames()

agx::UInt64 agxData::JournalArchive::getNumFrames ( ) const

◆ getNumSessions()

size_t agxData::JournalArchive::getNumSessions ( ) const
Returns
The number of sessions currently stored in the journal.

◆ getPath() [1/2]

const agx::String & agxData::JournalArchive::getPath ( ) const
Returns
A search path to the saved journal. The semantics of the string is storage format dependent, but is often a path to a file on disk.

◆ getPath() [2/2]

virtual agx::String agxData::JournalArchive::getPath ( ) const
pure virtual

Returns a format specific string that identifies the location of this session within a journal.

This may be, for example, a disk or HDF5 path.

◆ getPlot()

virtual PlotData * agxData::JournalArchive::getPlot ( const agx::String plotName)
pure virtual

◆ getPlotList()

virtual void agxData::JournalArchive::getPlotList ( agx::StringVector result)
pure virtual

◆ getScenePath()

virtual agx::String agxData::JournalArchive::getScenePath ( bool  create = true) const
pure virtual

Get the path on disk where the .agx file, called the scene file, containing the initial state of the simulation may be stored.

Actual presence of the .agx file depends on if it has been written yet.

If the journal stores the scene data in some internal format, then the unpackSceneFile may be used to copy the initial state from the internal format into a .agx file located at the path returned by this function.

Returns
The path to the .agx file containing the initial state of the simulation.

◆ getSession() [1/2]

agxData::JournalArchive::Session * agxData::JournalArchive::getSession ( const agx::Name name)
Returns
The session with the given name, or nullptr if no such session exists.

◆ getSession() [2/2]

const agxData::JournalArchive::Session * agxData::JournalArchive::getSession ( const agx::Name name) const
Returns
The session with the given name, or nullptr if no such session exists.

◆ getSessions()

const SessionTable & agxData::JournalArchive::getSessions ( ) const
Returns
A table containing all sessions stored in the journal, mapping session names to sessions themselves.

◆ getSimulationHeader()

agx::Component * agxData::JournalArchive::getSimulationHeader ( )

◆ getTimeStep()

agx::Real64 agxData::JournalArchive::getTimeStep ( ) const

◆ is64BitArchitecture()

bool agxData::JournalArchive::is64BitArchitecture ( ) const

◆ is64BitReal()

bool agxData::JournalArchive::is64BitReal ( ) const

◆ isLittleEndian()

bool agxData::JournalArchive::isLittleEndian ( ) const

◆ isOwnerOf()

bool agxData::JournalArchive::isOwnerOf ( const agxData::JournalArchive::Session session) const
Returns
True if this journal is the owner of the given session. False otherwise.

◆ listSessionNames()

void agxData::JournalArchive::listSessionNames ( agx::Vector< agx::Name > &  result) const

Add to the end of the given Vector the names of all the sessions in the Journal.

◆ makeCopy()

virtual agxData::JournalArchive::Session * agxData::JournalArchive::makeCopy ( agxData::JournalArchive::Session session)
protectedpure virtual

Create a copy of the given session. The copy will have its disk data stored in the current JournalArchive.

Implemented in agxData::FileJournal.

◆ packSceneData() [1/2]

virtual bool agxData::JournalArchive::packSceneData ( std::istream &  sceneData)
pure virtual

Copy the scene data found in the given stringstream into the journal in some format specific way.

The method is intended to be used with a stringstream filled using the agxSDK::Simulation::write method.

◆ packSceneData() [2/2]

virtual bool agxData::JournalArchive::packSceneData ( std::stringstream &  sceneData)
pure virtual

Copy the scene data found in the given stringstream into the journal in some format specific way.

The method is intended to be used with a stringstream filled using the agxSDK::Simulation::write method.

◆ recordExtraData()

virtual bool agxData::JournalArchive::recordExtraData ( const agx::String key,
const agx::String value 
)
pure virtual

Store a string key-value pair to the session on disk.

◆ recordExtraDataAsJSon()

bool agxData::JournalArchive::recordExtraDataAsJSon ( const agx::String key,
const agx::String value 
)

Store a string key-value pair to the session on disk, without ruining the .

◆ registerSession()

bool agxData::JournalArchive::registerSession ( agxData::JournalArchive::Session newSession)
protected

Create the Journal <-> Session coupling.

Will fail if there already is a session with the given name in the session table.

◆ removePlot()

virtual void agxData::JournalArchive::removePlot ( const agx::String plotName)
pure virtual

◆ removeSession() [1/2]

virtual bool agxData::JournalArchive::removeSession ( agxData::JournalArchive::Session session)
pure virtual

Remove the given session from the journal.

Implemented in agxData::FileJournal.

◆ removeSession() [2/2]

bool agxData::JournalArchive::removeSession ( const agx::Name name)

Remove the session with the given name from the journal.

◆ rename()

bool agxData::JournalArchive::rename ( const agx::Name name)
protected

◆ renameSession()

virtual bool agxData::JournalArchive::renameSession ( agxData::JournalArchive::Session session,
const agx::Name newName 
)
pure virtual

Rename the given session to the given new name.

Parameters
sessionThe session to rename.
newNameThe name that the session should be renamed to.

Implemented in agxData::FileJournal.

◆ retrieveExtraData() [1/2]

agx::String agxData::JournalArchive::retrieveExtraData ( const agx::String key)

◆ retrieveExtraData() [2/2]

virtual bool agxData::JournalArchive::retrieveExtraData ( const agx::String key,
agx::String value 
)
pure virtual

Read back the value associated with the key from disk.

The value, if found, is stored in 'value'

◆ retrieveExtraDataAsJSon() [1/2]

agx::String agxData::JournalArchive::retrieveExtraDataAsJSon ( const agx::String key)

◆ retrieveExtraDataAsJSon() [2/2]

bool agxData::JournalArchive::retrieveExtraDataAsJSon ( const agx::String key,
agx::String value 
)

Read back the value associated with the key from disk.

The value, if found, is stored in 'value'

◆ savePlot()

virtual void agxData::JournalArchive::savePlot ( const PlotData plot)
pure virtual

◆ Session()

agxData::JournalArchive::Session ( const agx::Name name)
protected

◆ set64BitArchitecture()

void agxData::JournalArchive::set64BitArchitecture ( bool  flag)

◆ set64BitReal()

void agxData::JournalArchive::set64BitReal ( bool  flag)

◆ setAgxVersionNumber()

void agxData::JournalArchive::setAgxVersionNumber ( const agx::UInt32  version)

◆ setAgxVersionString()

void agxData::JournalArchive::setAgxVersionString ( const agx::String version)

◆ setComputationTime()

void agxData::JournalArchive::setComputationTime ( agx::Real64  computationTime)

◆ setDate()

void agxData::JournalArchive::setDate ( agx::Date date)

◆ setFirstFrameIndex()

void agxData::JournalArchive::setFirstFrameIndex ( agx::UInt64  startFrame)

◆ setFirstFrameTimeStamp()

void agxData::JournalArchive::setFirstFrameTimeStamp ( agx::Real64  startTime)

◆ setFrameIO()

void agxData::JournalArchive::setFrameIO ( agxData::FrameIO frameIO)

◆ setFrameStride()

void agxData::JournalArchive::setFrameStride ( agx::UInt64  stride)

◆ setHeaderFormat()

void agxData::JournalArchive::setHeaderFormat ( SerializedFrame::HeaderFormat  format)

Some journal formats support more than one format for frame metadata.

It is the responsibility of the agxData::Track reading or writing from/to the session to ensure that the set header format matches the actual format used on disk. In particular, setHeaderFormat cannot be used to change the header format of a session.

◆ setLastFrameIndex()

void agxData::JournalArchive::setLastFrameIndex ( agx::UInt64  endFrame)

◆ setLastFrameTimeStamp()

void agxData::JournalArchive::setLastFrameTimeStamp ( agx::Real64  endTime)

◆ setLittleEndian()

void agxData::JournalArchive::setLittleEndian ( bool  flag)

◆ setName()

void agxData::JournalArchive::setName ( const agx::Name name)
protected

◆ setNumFrames()

void agxData::JournalArchive::setNumFrames ( agx::UInt64  numFrames)

◆ setPath()

void agxData::JournalArchive::setPath ( const agx::String path)
protected

◆ setSimulationHeader()

void agxData::JournalArchive::setSimulationHeader ( agx::Component header)

◆ setTimeStep()

void agxData::JournalArchive::setTimeStep ( agx::Real64  timeStep)

◆ transferSession()

bool agxData::JournalArchive::transferSession ( agxData::JournalArchive::Session session,
agxData::JournalArchive target 
)

Transfer the given session from this journal into the given target.

The session must be owned by the current JournalArchive and the target must be of the same journal type, i.e., use the same disk format. It is safe to continue using pointers to the transfered session, then in-memory object is updated rather than recreated.

Parameters
sessionThe session to transfer.
targetThe journal that should take over ownership of the session.
Returns
True of the transfer is successful, false otherwise.

◆ transferTo()

bool agxData::JournalArchive::transferTo ( agxData::JournalArchive target)

Transfer the session to another JournalArchive. The target JournalArchive must be of the same correct type.

◆ truncate()

virtual bool agxData::JournalArchive::truncate ( agx::UInt  firstFrameToRemove)
pure virtual

Remove all frames from the given index and forward.

◆ unpackSceneData() [1/2]

virtual bool agxData::JournalArchive::unpackSceneData ( std::ostream &  sceneData)
pure virtual

Copy scene data from the archive, stored in some format specific way, into the given stringstream.

The stringstream can then be passed on to the agxSDK::Simulation::read method.

◆ unpackSceneData() [2/2]

virtual bool agxData::JournalArchive::unpackSceneData ( std::stringstream &  sceneData)
pure virtual

Copy scene data from the archive, stored in some format specific way, into the given stringstream.

The stringstream can then be passed on to the agxSDK::Simulation::read method.

◆ unpackSceneFile()

virtual bool agxData::JournalArchive::unpackSceneFile ( )
pure virtual

Ensure that the scene file for the session is available at the location returned by getScenePath.

Will overwrite the scene file with the packed version if a file is already present at the path returned by getScenePath.

◆ unregisterSession()

bool agxData::JournalArchive::unregisterSession ( agxData::JournalArchive::Session removedSession)
protected

Remove the Journal <-> Session coupling.

Note that this will do an unreference of the session and may therefore delete the session.

◆ updateSessionAndTableWithNewName()

bool agxData::JournalArchive::updateSessionAndTableWithNewName ( agxData::JournalArchive::Session session,
const agx::Name newName 
)
protected

Change the name of the given session. Will ensure that the session table is kept consistent.

◆ writeHeader()

virtual void agxData::JournalArchive::writeHeader ( )
pure virtual

The documentation for this class was generated from the following file: