Ref T29, utility function added and flag names adjusted

This commit is contained in:
Klaus Basan
2017-07-13 23:28:24 +02:00
committed by Mathew Sutcliffe
parent 224c61c7e9
commit 9e4cfca2cc
3 changed files with 32 additions and 13 deletions

View File

@@ -51,6 +51,19 @@ namespace BlackMisc
return list.join(',');
}
CDbFlags::DataRetrievalModeFlag CDbFlags::modeToModeFlag(DataRetrievalMode mode)
{
if (mode == Unspecified) return Unspecified;
if (mode == DbReading) return DbReading;
if (mode == DbWriting) return DbWriting;
if (mode == Shared) return Shared;
if (mode == SharedInfoOnly) return SharedInfoOnly;
if (mode == Cached) return Cached;
if (mode == Canceled) return Canceled;
if (mode == Ignore) return Ignore;
return Unspecified;
}
CDbFlags::DataRetrievalMode CDbFlags::adjustWhenDbIsDown(DataRetrievalMode mode)
{
switch (mode)