libmoost
moost::io::file_backed_data_source< DataPolicy > Class Template Reference

#include <file_backed_data_source.hpp>

Inheritance diagram for moost::io::file_backed_data_source< DataPolicy >:
Collaboration diagram for moost::io::file_backed_data_source< DataPolicy >:

List of all members.

Public Types

typedef DataPolicy::data_type data_type

Public Member Functions

 file_backed_data_source (const DataPolicy &dataPolicy)
void configure (file_backed_data_source_config conf)
const
file_backed_data_source_config
getConfig () const
size_t size () const
int getLastLoadTime () const
void registerLoadable (boost::shared_ptr< loadable > pOther, bool loadOtherFirst=true)
boost::shared_ptr< data_typeget_shared_ptr ()
void load ()

Private Types

typedef std::vector
< boost::shared_ptr< loadable > > 
registered_t

Private Member Functions

void reload (file_watcher::file_action action, const std::string &filepath)
void loadWithErrorHandling (boost::shared_ptr< data_type > &pData, const std::string &filepath)

Private Attributes

DataPolicy m_dataPolicy
file_backed_data_source_config m_conf
bool m_firstLoad
int m_lastLoadTime
file_watcher m_fileWatcher
moost::safe_shared_ptr< data_typem_pData
registered_t m_preRegistered
registered_t m_postRegistered

Detailed Description

template<typename DataPolicy>
class moost::io::file_backed_data_source< DataPolicy >

Definition at line 228 of file file_backed_data_source.hpp.


Member Typedef Documentation

template<typename DataPolicy >
typedef DataPolicy::data_type moost::io::file_backed_data_source< DataPolicy >::data_type

Definition at line 232 of file file_backed_data_source.hpp.

template<typename DataPolicy >
typedef std::vector<boost::shared_ptr<loadable> > moost::io::file_backed_data_source< DataPolicy >::registered_t [private]

Definition at line 296 of file file_backed_data_source.hpp.


Constructor & Destructor Documentation

template<typename DataPolicy >
moost::io::file_backed_data_source< DataPolicy >::file_backed_data_source ( const DataPolicy &  dataPolicy) [inline]

Definition at line 234 of file file_backed_data_source.hpp.


Member Function Documentation

template<typename DataPolicy >
void moost::io::file_backed_data_source< DataPolicy >::configure ( file_backed_data_source_config  conf) [inline]

Definition at line 237 of file file_backed_data_source.hpp.

template<typename DataPolicy >
boost::shared_ptr<data_type> moost::io::file_backed_data_source< DataPolicy >::get_shared_ptr ( ) [inline]

Definition at line 266 of file file_backed_data_source.hpp.

Here is the call graph for this function:

template<typename DataPolicy >
const file_backed_data_source_config& moost::io::file_backed_data_source< DataPolicy >::getConfig ( ) const [inline]

Definition at line 242 of file file_backed_data_source.hpp.

template<typename DataPolicy >
int moost::io::file_backed_data_source< DataPolicy >::getLastLoadTime ( ) const [inline]

Definition at line 253 of file file_backed_data_source.hpp.

template<typename DataPolicy >
void moost::io::file_backed_data_source< DataPolicy >::load ( ) [inline, virtual]

Implements moost::io::loadable.

Definition at line 271 of file file_backed_data_source.hpp.

Here is the call graph for this function:

template<typename DataPolicy >
void moost::io::file_backed_data_source< DataPolicy >::loadWithErrorHandling ( boost::shared_ptr< data_type > &  pData,
const std::string &  filepath 
) [inline, private]

Definition at line 335 of file file_backed_data_source.hpp.

Here is the caller graph for this function:

template<typename DataPolicy >
void moost::io::file_backed_data_source< DataPolicy >::registerLoadable ( boost::shared_ptr< loadable pOther,
bool  loadOtherFirst = true 
) [inline]

Definition at line 258 of file file_backed_data_source.hpp.

template<typename DataPolicy >
void moost::io::file_backed_data_source< DataPolicy >::reload ( file_watcher::file_action  action,
const std::string &  filepath 
) [inline, private]

Definition at line 300 of file file_backed_data_source.hpp.

Here is the call graph for this function:

Here is the caller graph for this function:

template<typename DataPolicy >
size_t moost::io::file_backed_data_source< DataPolicy >::size ( ) const [inline]

Definition at line 247 of file file_backed_data_source.hpp.

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

template<typename DataPolicy >
file_backed_data_source_config moost::io::file_backed_data_source< DataPolicy >::m_conf [private]

Definition at line 288 of file file_backed_data_source.hpp.

template<typename DataPolicy >
DataPolicy moost::io::file_backed_data_source< DataPolicy >::m_dataPolicy [private]

Definition at line 286 of file file_backed_data_source.hpp.

template<typename DataPolicy >
file_watcher moost::io::file_backed_data_source< DataPolicy >::m_fileWatcher [private]

Definition at line 292 of file file_backed_data_source.hpp.

template<typename DataPolicy >
bool moost::io::file_backed_data_source< DataPolicy >::m_firstLoad [private]

Definition at line 289 of file file_backed_data_source.hpp.

template<typename DataPolicy >
int moost::io::file_backed_data_source< DataPolicy >::m_lastLoadTime [private]

Definition at line 290 of file file_backed_data_source.hpp.

template<typename DataPolicy >
moost::safe_shared_ptr<data_type> moost::io::file_backed_data_source< DataPolicy >::m_pData [private]

Definition at line 294 of file file_backed_data_source.hpp.

template<typename DataPolicy >
registered_t moost::io::file_backed_data_source< DataPolicy >::m_postRegistered [private]

Definition at line 298 of file file_backed_data_source.hpp.

template<typename DataPolicy >
registered_t moost::io::file_backed_data_source< DataPolicy >::m_preRegistered [private]

Definition at line 297 of file file_backed_data_source.hpp.


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