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 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 #include "wtf/PassRefPtr.h" | 44 #include "wtf/PassRefPtr.h" |
45 #include "wtf/RefPtr.h" | 45 #include "wtf/RefPtr.h" |
46 | 46 |
47 namespace WebCore { | 47 namespace WebCore { |
48 | 48 |
49 class DOMError; | 49 class DOMError; |
50 class ExceptionState; | 50 class ExceptionState; |
51 class ExecutionContext; | 51 class ExecutionContext; |
52 | 52 |
53 class IDBDatabase FINAL | 53 class IDBDatabase FINAL |
54 : public RefCountedGarbageCollected<IDBDatabase> | 54 : public RefCountedGarbageCollectedWillBeGarbageCollectedFinalized<IDBDataba
se> |
55 , public ScriptWrappable | 55 , public ScriptWrappable |
56 , public EventTargetWithInlineData | 56 , public EventTargetWithInlineData |
57 , public ActiveDOMObject { | 57 , public ActiveDOMObject { |
58 DEFINE_EVENT_TARGET_REFCOUNTING(RefCountedGarbageCollected<IDBDatabase>); | 58 DEFINE_EVENT_TARGET_REFCOUNTING_WILL_BE_REMOVED(RefCountedGarbageCollected<I
DBDatabase>); |
59 WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(IDBDatabase); | 59 WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(IDBDatabase); |
60 public: | 60 public: |
61 static IDBDatabase* create(ExecutionContext*, PassOwnPtr<blink::WebIDBDataba
se>, IDBDatabaseCallbacks*); | 61 static IDBDatabase* create(ExecutionContext*, PassOwnPtr<blink::WebIDBDataba
se>, IDBDatabaseCallbacks*); |
62 virtual ~IDBDatabase(); | 62 virtual ~IDBDatabase(); |
63 virtual void trace(Visitor*) OVERRIDE; | 63 virtual void trace(Visitor*) OVERRIDE; |
64 | 64 |
65 void setMetadata(const IDBDatabaseMetadata& metadata) { m_metadata = metadat
a; } | 65 void setMetadata(const IDBDatabaseMetadata& metadata) { m_metadata = metadat
a; } |
66 void indexCreated(int64_t objectStoreId, const IDBIndexMetadata&); | 66 void indexCreated(int64_t objectStoreId, const IDBIndexMetadata&); |
67 void indexDeleted(int64_t objectStoreId, int64_t indexId); | 67 void indexDeleted(int64_t objectStoreId, int64_t indexId); |
68 void transactionCreated(IDBTransaction*); | 68 void transactionCreated(IDBTransaction*); |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
153 // Keep track of the versionchange events waiting to be fired on this | 153 // Keep track of the versionchange events waiting to be fired on this |
154 // database so that we can cancel them if the database closes. | 154 // database so that we can cancel them if the database closes. |
155 WillBeHeapVector<RefPtrWillBeMember<Event> > m_enqueuedEvents; | 155 WillBeHeapVector<RefPtrWillBeMember<Event> > m_enqueuedEvents; |
156 | 156 |
157 Member<IDBDatabaseCallbacks> m_databaseCallbacks; | 157 Member<IDBDatabaseCallbacks> m_databaseCallbacks; |
158 }; | 158 }; |
159 | 159 |
160 } // namespace WebCore | 160 } // namespace WebCore |
161 | 161 |
162 #endif // IDBDatabase_h | 162 #endif // IDBDatabase_h |
OLD | NEW |