libfoedus-core
FOEDUS Core Library
|
Typical implementation of Initializable as a skeleton base class. More...
Typical implementation of Initializable as a skeleton base class.
The implementation of Initializable can either derive from this class or define by its own (eg. to avoid diamond inheritance). If it chooses to use this class, it must define "ErrorStack initialize_once()", and "ErrorStack uninitialize_once()".
Definition at line 157 of file initializable.hpp.
#include <initializable.hpp>
Public Member Functions | |
DefaultInitializable () | |
virtual | ~DefaultInitializable () |
DefaultInitializable (const DefaultInitializable &)=delete | |
DefaultInitializable & | operator= (const DefaultInitializable &)=delete |
ErrorStack | initialize () override final |
Typical implementation of Initializable::initialize() that provides initialize-once semantics. More... | |
ErrorStack | uninitialize () override final |
Typical implementation of Initializable::uninitialize() that provides uninitialize-once semantics. More... | |
bool | is_initialized () const override final |
Returns whether the object has been already initialized or not. More... | |
virtual ErrorStack | initialize_once ()=0 |
virtual ErrorStack | uninitialize_once ()=0 |
![]() | |
virtual | ~Initializable () |
|
inline |
Definition at line 159 of file initializable.hpp.
|
inlinevirtual |
Definition at line 160 of file initializable.hpp.
|
delete |
|
inlinefinaloverridevirtual |
Typical implementation of Initializable::initialize() that provides initialize-once semantics.
Implements foedus::Initializable.
Definition at line 169 of file initializable.hpp.
References CHECK_ERROR, ERROR_STACK, initialize_once(), foedus::ErrorStack::is_error(), is_initialized(), foedus::kErrorCodeAlreadyInitialized, foedus::kRetOk, and uninitialize_once().
Referenced by foedus::storage::array::ArrayComposer::compose(), foedus::storage::hash::HashComposer::compose(), foedus::storage::masstree::MasstreeComposer::compose(), foedus::storage::hash::HashStoragePimpl::debugout_single_thread(), foedus::storage::masstree::MasstreeStoragePimpl::debugout_single_thread(), foedus::snapshot::SnapshotManager::initialize(), foedus::savepoint::SavepointManager::initialize(), foedus::proc::ProcManager::initialize(), foedus::xct::XctManager::initialize(), foedus::log::LogManager::initialize(), foedus::restart::RestartManager::initialize(), foedus::storage::StorageManager::initialize(), foedus::thread::Thread::initialize(), foedus::soc::SocManager::initialize(), foedus::thread::ThreadPool::initialize(), foedus::Engine::initialize(), foedus::memory::PagePool::initialize(), foedus::thread::ThreadPoolPimpl::initialize_once(), foedus::memory::EngineMemory::initialize_once(), foedus::log::LogManagerPimpl::initialize_once(), foedus::thread::ThreadPimpl::initialize_once(), foedus::snapshot::SnapshotManagerPimpl::initialize_once(), foedus::snapshot::LogReducer::initialize_once(), foedus::storage::array::ArrayStoragePimpl::load(), foedus::storage::masstree::MasstreeStoragePimpl::load(), foedus::storage::hash::HashStoragePimpl::load(), and foedus::storage::StorageManagerPimpl::reinitialize_for_recovered_snapshot().
|
pure virtual |
Implemented in foedus::snapshot::MergeSort, foedus::snapshot::LogReducer, foedus::log::ThreadLogBuffer, foedus::snapshot::SnapshotManagerPimpl, foedus::log::Logger, foedus::thread::ThreadPimpl, foedus::savepoint::SavepointManagerPimpl, foedus::xct::XctManagerPimpl, foedus::log::LogManagerPimpl, foedus::memory::PagePoolPimpl, foedus::proc::ProcManagerPimpl, foedus::snapshot::LogMapper, foedus::storage::StorageManagerPimpl, foedus::EnginePimpl, foedus::memory::NumaCoreMemory, foedus::memory::EngineMemory, foedus::cache::SnapshotFileSet, foedus::memory::NumaNodeMemory, foedus::cache::CacheManagerPimpl, foedus::log::MetaLogger, foedus::restart::RestartManagerPimpl, foedus::soc::SocManagerPimpl, foedus::thread::ThreadPoolPimpl, foedus::debugging::DebuggingSupports, foedus::thread::ThreadGroup, and foedus::cache::CacheManager.
Referenced by initialize().
|
inlinefinaloverridevirtual |
Returns whether the object has been already initialized or not.
Implements foedus::Initializable.
Definition at line 196 of file initializable.hpp.
Referenced by foedus::proc::ProcManagerPimpl::emulated_register(), foedus::xct::XctManagerPimpl::handle_epoch_chime(), initialize(), foedus::thread::ThreadPoolPimpl::initialize_once(), foedus::cache::CacheManagerPimpl::initialize_once(), foedus::memory::EngineMemory::initialize_once(), foedus::thread::ThreadPimpl::initialize_once(), foedus::snapshot::SnapshotManager::is_initialized(), foedus::savepoint::SavepointManager::is_initialized(), foedus::proc::ProcManager::is_initialized(), foedus::xct::XctManager::is_initialized(), foedus::log::LogManager::is_initialized(), foedus::restart::RestartManager::is_initialized(), foedus::storage::StorageManager::is_initialized(), foedus::thread::Thread::is_initialized(), foedus::soc::SocManager::is_initialized(), foedus::thread::ThreadPool::is_initialized(), foedus::Engine::is_initialized(), foedus::memory::PagePool::is_initialized(), foedus::proc::ProcManagerPimpl::local_register(), foedus::snapshot::MergeSort::next_batch(), foedus::proc::ProcManagerPimpl::pre_register(), foedus::memory::PagePoolPimpl::release_one(), foedus::soc::SocManagerPimpl::report_engine_fatal_error(), uninitialize(), foedus::thread::ThreadPoolPimpl::uninitialize_once(), and foedus::memory::EngineMemory::uninitialize_once().
|
delete |
|
inlinefinaloverridevirtual |
Typical implementation of Initializable::uninitialize() that provides uninitialize-once semantics.
Implements foedus::Initializable.
Definition at line 187 of file initializable.hpp.
References CHECK_ERROR, is_initialized(), foedus::kRetOk, and uninitialize_once().
Referenced by foedus::storage::array::ArrayComposer::compose(), foedus::storage::hash::HashComposer::compose(), foedus::storage::masstree::MasstreeComposer::compose(), foedus::storage::hash::HashStoragePimpl::debugout_single_thread(), foedus::storage::masstree::MasstreeStoragePimpl::debugout_single_thread(), foedus::storage::array::ArrayStoragePimpl::load(), foedus::storage::masstree::MasstreeStoragePimpl::load(), foedus::storage::hash::HashStoragePimpl::load(), foedus::storage::StorageManagerPimpl::reinitialize_for_recovered_snapshot(), foedus::snapshot::SnapshotManager::uninitialize(), foedus::savepoint::SavepointManager::uninitialize(), foedus::proc::ProcManager::uninitialize(), foedus::xct::XctManager::uninitialize(), foedus::log::LogManager::uninitialize(), foedus::restart::RestartManager::uninitialize(), foedus::storage::StorageManager::uninitialize(), foedus::thread::Thread::uninitialize(), foedus::soc::SocManager::uninitialize(), foedus::thread::ThreadPool::uninitialize(), foedus::Engine::uninitialize(), foedus::memory::PagePool::uninitialize(), foedus::thread::ThreadPoolPimpl::uninitialize_once(), foedus::memory::EngineMemory::uninitialize_once(), foedus::log::LogManagerPimpl::uninitialize_once(), foedus::thread::ThreadPimpl::uninitialize_once(), foedus::snapshot::SnapshotManagerPimpl::uninitialize_once(), and foedus::snapshot::LogReducer::uninitialize_once().
|
pure virtual |
Implemented in foedus::snapshot::MergeSort, foedus::snapshot::LogReducer, foedus::log::ThreadLogBuffer, foedus::snapshot::SnapshotManagerPimpl, foedus::log::Logger, foedus::thread::ThreadPimpl, foedus::savepoint::SavepointManagerPimpl, foedus::xct::XctManagerPimpl, foedus::log::LogManagerPimpl, foedus::memory::PagePoolPimpl, foedus::proc::ProcManagerPimpl, foedus::storage::StorageManagerPimpl, foedus::snapshot::LogMapper, foedus::EnginePimpl, foedus::memory::NumaCoreMemory, foedus::memory::EngineMemory, foedus::cache::SnapshotFileSet, foedus::memory::NumaNodeMemory, foedus::cache::CacheManagerPimpl, foedus::log::MetaLogger, foedus::restart::RestartManagerPimpl, foedus::soc::SocManagerPimpl, foedus::thread::ThreadPoolPimpl, foedus::debugging::DebuggingSupports, foedus::thread::ThreadGroup, and foedus::cache::CacheManager.
Referenced by initialize(), and uninitialize().