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 * 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 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
143 | 143 |
144 void startBackgroundParser(); | 144 void startBackgroundParser(); |
145 void stopBackgroundParser(); | 145 void stopBackgroundParser(); |
146 void validateSpeculations(PassOwnPtr<ParsedChunk> lastChunk); | 146 void validateSpeculations(PassOwnPtr<ParsedChunk> lastChunk); |
147 void discardSpeculationsAndResumeFrom(PassOwnPtr<ParsedChunk> lastChunk, Pas
sOwnPtr<HTMLToken>, PassOwnPtr<HTMLTokenizer>); | 147 void discardSpeculationsAndResumeFrom(PassOwnPtr<ParsedChunk> lastChunk, Pas
sOwnPtr<HTMLToken>, PassOwnPtr<HTMLTokenizer>); |
148 void processParsedChunkFromBackgroundParser(PassOwnPtr<ParsedChunk>); | 148 void processParsedChunkFromBackgroundParser(PassOwnPtr<ParsedChunk>); |
149 void pumpPendingSpeculations(); | 149 void pumpPendingSpeculations(); |
150 | 150 |
151 Document* contextForParsingSession(); | 151 Document* contextForParsingSession(); |
152 | 152 |
153 enum SynchronousMode { | 153 bool canTakeNextToken(PumpSession&); |
154 AllowYield, | 154 void pumpTokenizer(); |
155 ForceSynchronous, | 155 void pumpTokenizerIfPossible(); |
156 }; | |
157 bool canTakeNextToken(SynchronousMode, PumpSession&); | |
158 void pumpTokenizer(SynchronousMode); | |
159 void pumpTokenizerIfPossible(SynchronousMode); | |
160 void constructTreeFromHTMLToken(HTMLToken&); | 156 void constructTreeFromHTMLToken(HTMLToken&); |
161 void constructTreeFromCompactHTMLToken(const CompactHTMLToken&); | 157 void constructTreeFromCompactHTMLToken(const CompactHTMLToken&); |
162 | 158 |
163 void runScriptsForPausedTreeBuilder(); | 159 void runScriptsForPausedTreeBuilder(); |
164 void resumeParsingAfterScriptExecution(); | 160 void resumeParsingAfterScriptExecution(); |
165 | 161 |
166 void attemptToEnd(); | 162 void attemptToEnd(); |
167 void endIfDelayed(); | 163 void endIfDelayed(); |
168 void attemptToRunDeferredScriptsAndEnd(); | 164 void attemptToRunDeferredScriptsAndEnd(); |
169 void end(); | 165 void end(); |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
202 | 198 |
203 bool m_isPinnedToMainThread; | 199 bool m_isPinnedToMainThread; |
204 bool m_endWasDelayed; | 200 bool m_endWasDelayed; |
205 bool m_haveBackgroundParser; | 201 bool m_haveBackgroundParser; |
206 unsigned m_pumpSessionNestingLevel; | 202 unsigned m_pumpSessionNestingLevel; |
207 }; | 203 }; |
208 | 204 |
209 } | 205 } |
210 | 206 |
211 #endif | 207 #endif |
OLD | NEW |