libmoost
|
#include <file_backed_data_source.hpp>
Public Types | |
typedef T | data_type |
Public Member Functions | |
virtual | ~data_policy_base () |
virtual std::string | getName () const =0 |
virtual boost::shared_ptr< T > | loadFromFile (const std::string &filepath) const =0 |
virtual size_t | size (boost::shared_ptr< T > pData) const =0 |
Implement this policy to define the data type to be held in your source and how it is loaded from file.
loadFromFile() can throw exceptions. The enclosing source will rethrow your exception if it is loading for the first time and has been configured with throwOnFirstLoadFail set to true. Otherwise the Source will simply log your exception and abandon the reload.
Definition at line 120 of file file_backed_data_source.hpp.
typedef T moost::io::data_policy_base< T >::data_type |
Definition at line 123 of file file_backed_data_source.hpp.
virtual moost::io::data_policy_base< T >::~data_policy_base | ( | ) | [inline, virtual] |
Definition at line 124 of file file_backed_data_source.hpp.
virtual std::string moost::io::data_policy_base< T >::getName | ( | ) | const [pure virtual] |
Implemented in IncrementingIntDataPolicy.
virtual boost::shared_ptr<T> moost::io::data_policy_base< T >::loadFromFile | ( | const std::string & | filepath | ) | const [pure virtual] |
Implemented in IncrementingIntDataPolicy.
virtual size_t moost::io::data_policy_base< T >::size | ( | boost::shared_ptr< T > | pData | ) | const [pure virtual] |
Implemented in IncrementingIntDataPolicy.