blob: c7f4bd7359a195f04d8f73eedb91931a41593df7 [file] [log] [blame]
Adam Lesinski282e1812014-01-23 18:17:42 -08001//
2// Copyright 2011 The Android Open Source Project
3//
4#ifndef MOCKCACHEUPDATER_H
5#define MOCKCACHEUPDATER_H
6
7#include <utils/String8.h>
8#include "CacheUpdater.h"
9
10using namespace android;
11
12class MockCacheUpdater : public CacheUpdater {
13public:
14
15 MockCacheUpdater()
16 : deleteCount(0), processCount(0) { };
17
18 // Make sure all the directories along this path exist
19 virtual void ensureDirectoriesExist(String8 path)
20 {
21 // Nothing to do
22 };
23
24 // Delete a file
25 virtual void deleteFile(String8 path) {
26 deleteCount++;
27 };
28
29 // Process an image from source out to dest
30 virtual void processImage(String8 source, String8 dest) {
31 processCount++;
32 };
33
34 // DATA MEMBERS
35 int deleteCount;
36 int processCount;
37private:
38};
39
40#endif // MOCKCACHEUPDATER_H