Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: libadblockplus-android/jni/JniCallbacks.h

Issue 29347315: Issue 4231 - Fix unstable FilterEngineTest.testSetRemoveFilterChangeCallback (Closed)
Patch Set: patchset 2 + patchset 3 + applied Eyeo's codestyle Created Aug. 8, 2016, 8:09 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « libadblockplus-android/jni/Android.mk ('k') | libadblockplus-android/jni/JniFileSystem.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: libadblockplus-android/jni/JniCallbacks.h
diff --git a/libadblockplus-android/jni/JniCallbacks.h b/libadblockplus-android/jni/JniCallbacks.h
index d0261eb3e2cd217cc3712e2885810a11f6f897d4..603779d45bb8654f8585b919bc3e497a1d77d615 100644
--- a/libadblockplus-android/jni/JniCallbacks.h
+++ b/libadblockplus-android/jni/JniCallbacks.h
@@ -87,6 +87,21 @@ private:
const JniGlobalReference<jclass>::Ptr logLevelClass;
};
+class JniFileSystemCallback : public JniCallbackBase, public AdblockPlus::FileSystem
+{
+public:
+ JniFileSystemCallback(JNIEnv* env, jobject callbackObject);
+ std::shared_ptr<std::istream> Read(const std::string& path) const;
+ void Write(const std::string& path, std::shared_ptr<std::istream> data);
+ void Move(const std::string& fromPath, const std::string& toPath);
+ void Remove(const std::string& path);
+ AdblockPlus::FileSystem::StatResult Stat(const std::string& path) const;
+ std::string Resolve(const std::string& path) const;
+
+private:
+ const JniGlobalReference<jclass>::Ptr statResultClass;
+};
+
class JniShowNotificationCallback : public JniCallbackBase
{
public:
« no previous file with comments | « libadblockplus-android/jni/Android.mk ('k') | libadblockplus-android/jni/JniFileSystem.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld