aboutsummaryrefslogtreecommitdiff
path: root/src/unstable/settingsdriver.h
blob: 4dfe09c8050cf69d6ef641044f008a8c5348ed17 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#ifndef BU_SETTINGS_DRIVER_H
#define BU_SETTINGS_DRIVER_H

#include "bu/utfstring.h"

namespace Bu
{
    class Settings;

    /**
     * Base class for i/o interfaces for Bu::Settings.  By subclassing this you
     * can provide custom storage for application settings.
     */
    class SettingsDriver
    {
    friend class Bu::Settings;
    public:
        SettingsDriver();
        virtual ~SettingsDriver();

    protected:
        virtual void init( const Bu::UtfString &sCompany, const Bu::UtfString &sProduct )=0;
        virtual void set( const Bu::UtfString &sKey, const Bu::UtfString  &sValue )=0;
        virtual Bu::UtfString get( const Bu::UtfString &sKey, const Bu::UtfString &sValue )=0;
    };
};

#endif