00001 #ifndef LUX_STORAGE_STORAGEENGINE_H 00002 #define LUX_STORAGE_STORAGEENGINE_H 00003 00004 #include "lux/lux.h" 00005 #include "luxio_btree.h" 00006 #include "luxio_array.h" 00007 00008 namespace Lux { 00009 00010 template <class StorageEnginePolicy> 00011 class StorageEngine : public StorageEnginePolicy { 00012 00013 public: 00014 StorageEngine() 00015 : StorageEnginePolicy() 00016 {} 00017 00018 StorageEngine(const char *filename, db_flags_t open_flags) 00019 : StorageEnginePolicy(filename, open_flags) 00020 {} 00021 00022 StorageEngine(const std::string filename, db_flags_t open_flags) 00023 : StorageEnginePolicy(filename, open_flags) 00024 {} 00025 }; 00026 } 00027 00028 typedef Lux::StorageEngine<Lux::LuxIOBtree> LuxBtreeStorage; 00029 typedef Lux::StorageEngine<Lux::LuxIOArray> LuxArrayStorage; 00030 00031 #endif