FIX::FileStoreFactory Class Reference

Creates a file based implementation of MessageStore. More...

`#include <FileStore.h>`

Inheritance diagram for FIX::FileStoreFactory:
[legend]
Collaboration diagram for FIX::FileStoreFactory:
[legend]

## Public Member Functions

| FileStoreFactory (const SessionSettings &settings)
| FileStoreFactory (const std::string &path)
MessageStore * | create (const SessionID &)
void | destroy (MessageStore *)
Public Member Functions inherited from FIX::MessageStoreFactory
virtual | ~MessageStoreFactory ()

## Private Attributes

std::string | m_path
SessionSettings | m_settings

## Detailed Description

Creates a file based implementation of MessageStore.

Definition at line 56 of file FileStore.h.

## Constructor & Destructor Documentation

## FileStoreFactory() [1/2]

FIX::FileStoreFactory::FileStoreFactory | ( | const SessionSettings & | settings | ) |

inline

Definition at line 59 of file FileStore.h.

:<br>

## FileStoreFactory() [2/2]

FIX::FileStoreFactory::FileStoreFactory | ( | const std::string & | path | ) |

inline

Definition at line 61 of file FileStore.h.

:<br>

## Member Function Documentation

## create()

MessageStore * FIX::FileStoreFactory::create | ( | const SessionID & | s | ) |

virtual

Implements FIX::MessageStoreFactory.

Definition at line 194 of file FileStore.cpp.

{
if ( fseek( m_msgFile, 0, SEEK_END ) )
throw IOException( "Cannot seek to end of " + m_msgFileName );
if ( fseek( m_headerFile, 0, SEEK_END ) )
throw IOException( "Cannot seek to end of " + m_headerFileName );
long offset = ftell( m_msgFile );
if ( offset < 0 )
throw IOException( "Unable to get file pointer position from " + m_msgFileName );

## destroy()

void FIX::FileStoreFactory::destroy | ( | MessageStore * | pStore | ) |

virtual

Implements FIX::MessageStoreFactory.

Definition at line 204 of file FileStore.cpp.

## Member Data Documentation

## m_path

std::string FIX::FileStoreFactory::m_path

private

Definition at line 67 of file FileStore.h.

## m_settings

SessionSettings FIX::FileStoreFactory::m_settings

private

Definition at line 68 of file FileStore.h.

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

- FileStore.h
- FileStore.cpp