Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(819)

Unified Diff: Source/core/inspector/EditedResourcesContentManager.h

Issue 445023005: DevTools: reduce ResourceAgent dependency on PageAgent. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/inspector/EditedResourcesContentManager.h
diff --git a/Source/core/inspector/EditedResourcesContentManager.h b/Source/core/inspector/EditedResourcesContentManager.h
new file mode 100644
index 0000000000000000000000000000000000000000..040037b236b0574e4a36bbfbef78c1a059a622b3
--- /dev/null
+++ b/Source/core/inspector/EditedResourcesContentManager.h
@@ -0,0 +1,35 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef EditedResourcesContentManager_h
+#define EditedResourcesContentManager_h
+
+#include "platform/heap/Handle.h"
+#include "wtf/Forward.h"
+#include "wtf/HashMap.h"
+#include "wtf/text/StringHash.h"
+#include "wtf/text/WTFString.h"
+
+namespace blink {
+
+class EditedResourcesContentManager : public NoBaseWillBeGarbageCollectedFinalized<EditedResourcesContentManager> {
+ WTF_MAKE_NONCOPYABLE(EditedResourcesContentManager);
+ WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED;
+public:
+ static PassOwnPtrWillBeRawPtr<EditedResourcesContentManager> create();
+ ~EditedResourcesContentManager();
+
+ void clear();
+ void add(const String& url, const String& content);
+ bool get(const String& url, String* content);
+
+private:
+ EditedResourcesContentManager();
+
+ HashMap<String, String> m_editedResourceContent;
+};
+
+} // namespace blink
+
+#endif // EditedResourcesContentManager_h

Powered by Google App Engine
This is Rietveld 408576698