diff options
Diffstat (limited to 'tools/aapt/tests/MockCacheUpdater.h')
-rw-r--r-- | tools/aapt/tests/MockCacheUpdater.h | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/tools/aapt/tests/MockCacheUpdater.h b/tools/aapt/tests/MockCacheUpdater.h new file mode 100644 index 0000000..c7f4bd7 --- /dev/null +++ b/tools/aapt/tests/MockCacheUpdater.h @@ -0,0 +1,40 @@ +// +// Copyright 2011 The Android Open Source Project +// +#ifndef MOCKCACHEUPDATER_H +#define MOCKCACHEUPDATER_H + +#include <utils/String8.h> +#include "CacheUpdater.h" + +using namespace android; + +class MockCacheUpdater : public CacheUpdater { +public: + + MockCacheUpdater() + : deleteCount(0), processCount(0) { }; + + // Make sure all the directories along this path exist + virtual void ensureDirectoriesExist(String8 path) + { + // Nothing to do + }; + + // Delete a file + virtual void deleteFile(String8 path) { + deleteCount++; + }; + + // Process an image from source out to dest + virtual void processImage(String8 source, String8 dest) { + processCount++; + }; + + // DATA MEMBERS + int deleteCount; + int processCount; +private: +}; + +#endif // MOCKCACHEUPDATER_H
\ No newline at end of file |