Switch to unified view

a/src/utils/circache.h b/src/utils/circache.h
...
...
57
    CirCache(const string& dir);
57
    CirCache(const string& dir);
58
    virtual ~CirCache();
58
    virtual ~CirCache();
59
59
60
    virtual string getReason();
60
    virtual string getReason();
61
61
62
    virtual bool create(off_t maxsize, bool onlyifnotexists = true);
62
    enum CreateFlags {CC_CRNONE=0, CC_CRUNIQUE=1, CC_CRTRUNCATE = 2};
63
    virtual bool create(off_t maxsize, int flags);
63
64
64
    enum OpMode {CC_OPREAD, CC_OPWRITE};
65
    enum OpMode {CC_OPREAD, CC_OPWRITE};
65
    virtual bool open(OpMode mode);
66
    virtual bool open(OpMode mode);
66
67
67
    virtual bool get(const string& udi, string& dic, string& data, 
68
    virtual bool get(const string& udi, string& dic, string& data, 
...
...
69
70
70
    // Note: the dicp MUST have an udi entry
71
    // Note: the dicp MUST have an udi entry
71
    enum PutFlags {NoCompHint = 1};
72
    enum PutFlags {NoCompHint = 1};
72
    virtual bool put(const string& udi, const ConfSimple *dicp, 
73
    virtual bool put(const string& udi, const ConfSimple *dicp, 
73
                     const string& data, unsigned int flags = 0);
74
                     const string& data, unsigned int flags = 0);
75
76
    virtual bool erase(const string& udi);
74
77
75
    /** Walk the archive.
78
    /** Walk the archive.
76
     *
79
     *
77
     * Maybe we'll have separate iterators one day, but this is good
80
     * Maybe we'll have separate iterators one day, but this is good
78
     * enough for now. No put() operations should be performed while
81
     * enough for now. No put() operations should be performed while