Introduce MyMoneyStorageMgr

Authored by wojnilowicz on Feb 8 2018, 3:32 PM.

Description

Introduce MyMoneyStorageMgr

This patch introduces MyMoneyStorageMgr class to avoid needless
duplication of virtual methods in IMyMoneyStorage and IMyMoneySerialize
and juggling between those two interfaces.

It's a cornerstone for getting rid of MyMoneyObjectContainer as
universal cache.

Its code consists in big part from well proven MyMoneySeqAccessMgr and
lends its capabilities to MyMoneyDatabaseMgr. Therefore databases now
work just like xml file, i.e. read to cache, make all operations on
cache and save to the file at the end of program. This brings us speed
and unified code path.

MyMoneyDatabaseMgr looked like duplicate code and had a little bit
different logic in two places, which shouldn't happen. That's why tests
had to be heavily modified and now are probably duplicate of
MyMoneySeqAccessMgr test.

If a database should be connected in real-time to KMyMoney then it's not
possible at the moment and for sure shouldn't be solved as it was solved
before.

Differential Revision: https://phabricator.kde.org/D9869

Details

Committed
wojnilowiczFeb 9 2018, 2:07 PM
Differential Revision
D9869: Introduce MyMoneyStorageMgr
Parents
R261:08ee6d11f4ac: Merge branch '5.0'
Branches
Unknown
Tags
Unknown