diff --git a/src/gen/db/base.py b/src/gen/db/base.py index cd8ad494c..30a1e93b4 100644 --- a/src/gen/db/base.py +++ b/src/gen/db/base.py @@ -58,6 +58,20 @@ class DbReadBase(object): derived from this class should be created. """ self.basedb = self + self.__feature = {} # {"feature": VALUE, ...} + + def get_feature(self, feature): + """ + Databases can implement certain features or not. The default is + None, unless otherwise explicitly stated. + """ + return self.__feature.get(feature, None) # can also be explitily None + + def set_feature(self, feature, value): + """ + Databases can implement certain features. + """ + self.__feature[feature] = value def all_handles(self, table): """