OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google 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 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
55 return adoptPtr(new InspectorDOMStorageAgent(instrumentingAgents, pageAg
ent, state)); | 55 return adoptPtr(new InspectorDOMStorageAgent(instrumentingAgents, pageAg
ent, state)); |
56 } | 56 } |
57 ~InspectorDOMStorageAgent(); | 57 ~InspectorDOMStorageAgent(); |
58 | 58 |
59 virtual void setFrontend(InspectorFrontend*); | 59 virtual void setFrontend(InspectorFrontend*); |
60 virtual void clearFrontend(); | 60 virtual void clearFrontend(); |
61 | 61 |
62 // Called from the front-end. | 62 // Called from the front-end. |
63 virtual void enable(ErrorString*); | 63 virtual void enable(ErrorString*); |
64 virtual void disable(ErrorString*); | 64 virtual void disable(ErrorString*); |
| 65 virtual void getValue(ErrorString*, const RefPtr<JSONObject>& storageId, con
st String& key, TypeBuilder::OptOutput<WTF::String>* value); |
65 virtual void getDOMStorageItems(ErrorString*, const RefPtr<JSONObject>& stor
ageId, RefPtr<TypeBuilder::Array<TypeBuilder::Array<String> > >& items); | 66 virtual void getDOMStorageItems(ErrorString*, const RefPtr<JSONObject>& stor
ageId, RefPtr<TypeBuilder::Array<TypeBuilder::Array<String> > >& items); |
66 virtual void setDOMStorageItem(ErrorString*, const RefPtr<JSONObject>& stora
geId, const String& key, const String& value); | 67 virtual void setDOMStorageItem(ErrorString*, const RefPtr<JSONObject>& stora
geId, const String& key, const String& value); |
67 virtual void removeDOMStorageItem(ErrorString*, const RefPtr<JSONObject>& st
orageId, const String& key); | 68 virtual void removeDOMStorageItem(ErrorString*, const RefPtr<JSONObject>& st
orageId, const String& key); |
68 | 69 |
69 // Called from the injected script. | 70 // Called from the injected script. |
70 String storageId(Storage*); | 71 String storageId(Storage*); |
71 PassRefPtr<TypeBuilder::DOMStorage::StorageId> storageId(SecurityOrigin*, bo
ol isLocalStorage); | 72 PassRefPtr<TypeBuilder::DOMStorage::StorageId> storageId(SecurityOrigin*, bo
ol isLocalStorage); |
72 | 73 |
73 // Called from InspectorInstrumentation | 74 // Called from InspectorInstrumentation |
74 void didDispatchDOMStorageEvent(const String& key, const String& oldValue, c
onst String& newValue, StorageType, SecurityOrigin*); | 75 void didDispatchDOMStorageEvent(const String& key, const String& oldValue, c
onst String& newValue, StorageType, SecurityOrigin*); |
75 | 76 |
76 private: | 77 private: |
77 | 78 |
78 InspectorDOMStorageAgent(InstrumentingAgents*, InspectorPageAgent*, Inspecto
rCompositeState*); | 79 InspectorDOMStorageAgent(InstrumentingAgents*, InspectorPageAgent*, Inspecto
rCompositeState*); |
79 | 80 |
80 bool isEnabled() const; | 81 bool isEnabled() const; |
81 PassOwnPtr<StorageArea> findStorageArea(ErrorString*, const RefPtr<JSONObjec
t>&, Frame*&); | 82 PassOwnPtr<StorageArea> findStorageArea(ErrorString*, const RefPtr<JSONObjec
t>&, Frame*&); |
82 | 83 |
83 InspectorPageAgent* m_pageAgent; | 84 InspectorPageAgent* m_pageAgent; |
84 InspectorFrontend* m_frontend; | 85 InspectorFrontend* m_frontend; |
85 }; | 86 }; |
86 | 87 |
87 } // namespace WebCore | 88 } // namespace WebCore |
88 | 89 |
89 #endif // !defined(InspectorDOMStorageAgent_h) | 90 #endif // !defined(InspectorDOMStorageAgent_h) |
OLD | NEW |