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

Side by Side Diff: Source/core/dom/DOMStringMap.h

Issue 258143002: Oilpan: move DOM string collection objects to the Oilpan heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase + final adjustments Created 6 years, 7 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 unified diff | Download patch
« no previous file with comments | « Source/core/dom/DOMStringList.idl ('k') | Source/core/dom/DOMStringMap.idl » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2010 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 11 matching lines...) Expand all
22 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 22 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
23 * THE POSSIBILITY OF SUCH DAMAGE. 23 * THE POSSIBILITY OF SUCH DAMAGE.
24 */ 24 */
25 25
26 #ifndef DOMStringMap_h 26 #ifndef DOMStringMap_h
27 #define DOMStringMap_h 27 #define DOMStringMap_h
28 28
29 #include "bindings/v8/ExceptionState.h" 29 #include "bindings/v8/ExceptionState.h"
30 #include "bindings/v8/ScriptWrappable.h" 30 #include "bindings/v8/ScriptWrappable.h"
31 #include "bindings/v8/V8Binding.h" 31 #include "bindings/v8/V8Binding.h"
32 #include "platform/heap/Handle.h"
32 #include "wtf/Noncopyable.h" 33 #include "wtf/Noncopyable.h"
33 #include "wtf/Vector.h" 34 #include "wtf/Vector.h"
34 #include "wtf/text/WTFString.h" 35 #include "wtf/text/WTFString.h"
35 36
36 namespace WebCore { 37 namespace WebCore {
37 38
38 class Element; 39 class Element;
39 40
40 class DOMStringMap : public ScriptWrappable { 41 class DOMStringMap : public NoBaseWillBeGarbageCollectedFinalized<DOMStringMap>, public ScriptWrappable {
41 WTF_MAKE_NONCOPYABLE(DOMStringMap); WTF_MAKE_FAST_ALLOCATED; 42 WTF_MAKE_NONCOPYABLE(DOMStringMap);
43 WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED;
42 public: 44 public:
43 virtual ~DOMStringMap(); 45 virtual ~DOMStringMap();
44 46
47 #if !ENABLE(OILPAN)
45 virtual void ref() = 0; 48 virtual void ref() = 0;
46 virtual void deref() = 0; 49 virtual void deref() = 0;
50 #endif
47 51
48 virtual void getNames(Vector<String>&) = 0; 52 virtual void getNames(Vector<String>&) = 0;
49 virtual String item(const String& name) = 0; 53 virtual String item(const String& name) = 0;
50 virtual bool contains(const String& name) = 0; 54 virtual bool contains(const String& name) = 0;
51 virtual void setItem(const String& name, const String& value, ExceptionState &) = 0; 55 virtual void setItem(const String& name, const String& value, ExceptionState &) = 0;
52 virtual bool deleteItem(const String& name) = 0; 56 virtual bool deleteItem(const String& name) = 0;
53 bool anonymousNamedSetter(const String& name, const String& value, Exception State& exceptionState) 57 bool anonymousNamedSetter(const String& name, const String& value, Exception State& exceptionState)
54 { 58 {
55 setItem(name, value, exceptionState); 59 setItem(name, value, exceptionState);
56 return true; 60 return true;
(...skipping 17 matching lines...) Expand all
74 { 78 {
75 return anonymousNamedSetter(String::number(index), value, exceptionState ); 79 return anonymousNamedSetter(String::number(index), value, exceptionState );
76 } 80 }
77 DeleteResult anonymousIndexedDeleter(uint32_t index) 81 DeleteResult anonymousIndexedDeleter(uint32_t index)
78 { 82 {
79 return anonymousNamedDeleter(AtomicString::number(index)); 83 return anonymousNamedDeleter(AtomicString::number(index));
80 } 84 }
81 85
82 virtual Element* element() = 0; 86 virtual Element* element() = 0;
83 87
88 virtual void trace(Visitor*) { }
89
84 protected: 90 protected:
85 DOMStringMap() 91 DOMStringMap()
86 { 92 {
87 ScriptWrappable::init(this); 93 ScriptWrappable::init(this);
88 } 94 }
89 }; 95 };
90 96
91 } // namespace WebCore 97 } // namespace WebCore
92 98
93 #endif // DOMStringMap_h 99 #endif // DOMStringMap_h
OLDNEW
« no previous file with comments | « Source/core/dom/DOMStringList.idl ('k') | Source/core/dom/DOMStringMap.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698