OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007, 2013 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2013 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 * | 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 29 matching lines...) Expand all Loading... |
40 class ExceptionState; | 40 class ExceptionState; |
41 class SQLErrorData; | 41 class SQLErrorData; |
42 class SQLStatementCallback; | 42 class SQLStatementCallback; |
43 class SQLStatementErrorCallback; | 43 class SQLStatementErrorCallback; |
44 class SQLTransactionBackend; | 44 class SQLTransactionBackend; |
45 class SQLTransactionCallback; | 45 class SQLTransactionCallback; |
46 class SQLTransactionErrorCallback; | 46 class SQLTransactionErrorCallback; |
47 class SQLValue; | 47 class SQLValue; |
48 class VoidCallback; | 48 class VoidCallback; |
49 | 49 |
50 class SQLTransaction FINAL | 50 class SQLTransaction final |
51 : public GarbageCollectedFinalized<SQLTransaction> | 51 : public GarbageCollectedFinalized<SQLTransaction> |
52 , public SQLTransactionStateMachine<SQLTransaction> | 52 , public SQLTransactionStateMachine<SQLTransaction> |
53 , public ScriptWrappable { | 53 , public ScriptWrappable { |
54 DEFINE_WRAPPERTYPEINFO(); | 54 DEFINE_WRAPPERTYPEINFO(); |
55 public: | 55 public: |
56 static SQLTransaction* create(Database*, SQLTransactionCallback*, | 56 static SQLTransaction* create(Database*, SQLTransactionCallback*, |
57 VoidCallback* successCallback, SQLTransactionErrorCallback*, bool readOn
ly); | 57 VoidCallback* successCallback, SQLTransactionErrorCallback*, bool readOn
ly); |
58 ~SQLTransaction(); | 58 ~SQLTransaction(); |
59 void trace(Visitor*); | 59 void trace(Visitor*); |
60 | 60 |
(...skipping 14 matching lines...) Expand all Loading... |
75 void setBackend(SQLTransactionBackend*); | 75 void setBackend(SQLTransactionBackend*); |
76 | 76 |
77 private: | 77 private: |
78 SQLTransaction(Database*, SQLTransactionCallback*, | 78 SQLTransaction(Database*, SQLTransactionCallback*, |
79 VoidCallback* successCallback, SQLTransactionErrorCallback*, | 79 VoidCallback* successCallback, SQLTransactionErrorCallback*, |
80 bool readOnly); | 80 bool readOnly); |
81 | 81 |
82 void clearCallbacks(); | 82 void clearCallbacks(); |
83 | 83 |
84 // State Machine functions: | 84 // State Machine functions: |
85 virtual StateFunction stateFunctionFor(SQLTransactionState) OVERRIDE; | 85 virtual StateFunction stateFunctionFor(SQLTransactionState) override; |
86 bool computeNextStateAndCleanupIfNeeded(); | 86 bool computeNextStateAndCleanupIfNeeded(); |
87 | 87 |
88 // State functions: | 88 // State functions: |
89 SQLTransactionState deliverTransactionCallback(); | 89 SQLTransactionState deliverTransactionCallback(); |
90 SQLTransactionState deliverTransactionErrorCallback(); | 90 SQLTransactionState deliverTransactionErrorCallback(); |
91 SQLTransactionState deliverStatementCallback(); | 91 SQLTransactionState deliverStatementCallback(); |
92 SQLTransactionState deliverQuotaIncreaseCallback(); | 92 SQLTransactionState deliverQuotaIncreaseCallback(); |
93 SQLTransactionState deliverSuccessCallback(); | 93 SQLTransactionState deliverSuccessCallback(); |
94 | 94 |
95 SQLTransactionState unreachableState(); | 95 SQLTransactionState unreachableState(); |
(...skipping 10 matching lines...) Expand all Loading... |
106 bool m_executeSqlAllowed; | 106 bool m_executeSqlAllowed; |
107 OwnPtr<SQLErrorData> m_transactionError; | 107 OwnPtr<SQLErrorData> m_transactionError; |
108 | 108 |
109 bool m_readOnly; | 109 bool m_readOnly; |
110 int m_asyncOperationId; | 110 int m_asyncOperationId; |
111 }; | 111 }; |
112 | 112 |
113 } // namespace blink | 113 } // namespace blink |
114 | 114 |
115 #endif // SQLTransaction_h | 115 #endif // SQLTransaction_h |
OLD | NEW |