new ctor and bugfixes
This commit is contained in:
1 parent
d873fcbf8e
commit
291710f257
4 files changed
+40
-22
No files matched your search
@@ -3,6 +3,12 @@
|
||||
ConstStorageAccessor::ConstStorageAccessor(store_address_t storeId):
|
||||
storeId(storeId) {}
|
||||
|
||||
ConstStorageAccessor::ConstStorageAccessor(store_address_t storeId,
|
||||
StorageManagerIF* store):
|
||||
storeId(storeId), store(store) {
|
||||
internalState = AccessState::ASSIGNED;
|
||||
}
|
||||
|
||||
ConstStorageAccessor::~ConstStorageAccessor() {
|
||||
if(deleteData and store != nullptr) {
|
||||
sif::debug << "deleting store data" << std::endl;
|
||||
@@ -27,6 +33,11 @@ StorageAccessor::StorageAccessor(store_address_t storeId):
|
||||
ConstStorageAccessor(storeId) {
|
||||
}
|
||||
|
||||
StorageAccessor::StorageAccessor(store_address_t storeId,
|
||||
StorageManagerIF* store):
|
||||
ConstStorageAccessor(storeId, store) {
|
||||
}
|
||||
|
||||
StorageAccessor& StorageAccessor::operator =(
|
||||
StorageAccessor&& other) {
|
||||
// Call the parent move assignment and also assign own member.
|
||||
@@ -97,7 +108,7 @@ void ConstStorageAccessor::print() const {
|
||||
}
|
||||
|
||||
void ConstStorageAccessor::assignStore(StorageManagerIF* store) {
|
||||
internalState = AccessState::READ;
|
||||
internalState = AccessState::ASSIGNED;
|
||||
this->store = store;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user