| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. |
| 3 * Copyright (C) 2010 Google, Inc. All Rights Reserved. | 3 * Copyright (C) 2010 Google, Inc. All Rights Reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 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 28 matching lines...) Expand all Loading... |
| 39 public: | 39 public: |
| 40 static PassOwnPtr<HTMLTokenizer> create() { return adoptPtr(new HTMLTokenize
r()); } | 40 static PassOwnPtr<HTMLTokenizer> create() { return adoptPtr(new HTMLTokenize
r()); } |
| 41 ~HTMLTokenizer(); | 41 ~HTMLTokenizer(); |
| 42 | 42 |
| 43 void reset(); | 43 void reset(); |
| 44 | 44 |
| 45 enum State { | 45 enum State { |
| 46 DataState, | 46 DataState, |
| 47 CharacterReferenceInDataState, | 47 CharacterReferenceInDataState, |
| 48 RAWTEXTState, | 48 RAWTEXTState, |
| 49 ScriptDataState, | |
| 50 TagOpenState, | 49 TagOpenState, |
| 51 EndTagOpenState, | 50 EndTagOpenState, |
| 52 TagNameState, | 51 TagNameState, |
| 53 RAWTEXTLessThanSignState, | 52 RAWTEXTLessThanSignState, |
| 54 RAWTEXTEndTagOpenState, | 53 RAWTEXTEndTagOpenState, |
| 55 RAWTEXTEndTagNameState, | 54 RAWTEXTEndTagNameState, |
| 56 ScriptDataLessThanSignState, | |
| 57 ScriptDataEndTagOpenState, | |
| 58 ScriptDataEndTagNameState, | |
| 59 ScriptDataEscapeStartState, | |
| 60 ScriptDataEscapeStartDashState, | |
| 61 ScriptDataEscapedState, | |
| 62 ScriptDataEscapedDashState, | |
| 63 ScriptDataEscapedDashDashState, | |
| 64 ScriptDataEscapedLessThanSignState, | |
| 65 ScriptDataEscapedEndTagOpenState, | |
| 66 ScriptDataEscapedEndTagNameState, | |
| 67 ScriptDataDoubleEscapeStartState, | |
| 68 ScriptDataDoubleEscapedState, | |
| 69 ScriptDataDoubleEscapedDashState, | |
| 70 ScriptDataDoubleEscapedDashDashState, | |
| 71 ScriptDataDoubleEscapedLessThanSignState, | |
| 72 ScriptDataDoubleEscapeEndState, | |
| 73 BeforeAttributeNameState, | 55 BeforeAttributeNameState, |
| 74 AttributeNameState, | 56 AttributeNameState, |
| 75 AfterAttributeNameState, | 57 AfterAttributeNameState, |
| 76 BeforeAttributeValueState, | 58 BeforeAttributeValueState, |
| 77 AttributeValueDoubleQuotedState, | 59 AttributeValueDoubleQuotedState, |
| 78 AttributeValueSingleQuotedState, | 60 AttributeValueSingleQuotedState, |
| 79 AttributeValueUnquotedState, | 61 AttributeValueUnquotedState, |
| 80 CharacterReferenceInAttributeValueState, | 62 CharacterReferenceInAttributeValueState, |
| 81 AfterAttributeValueQuotedState, | 63 AfterAttributeValueQuotedState, |
| 82 SelfClosingStartTagState, | 64 SelfClosingStartTagState, |
| (...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 187 | 169 |
| 188 // We occationally want to emit both a character token and an end tag | 170 // We occationally want to emit both a character token and an end tag |
| 189 // token (e.g., when lexing script). We buffer the name of the end tag | 171 // token (e.g., when lexing script). We buffer the name of the end tag |
| 190 // token here so we remember it next time we re-enter the tokenizer. | 172 // token here so we remember it next time we re-enter the tokenizer. |
| 191 Vector<LChar, 32> m_bufferedEndTagName; | 173 Vector<LChar, 32> m_bufferedEndTagName; |
| 192 }; | 174 }; |
| 193 | 175 |
| 194 } | 176 } |
| 195 | 177 |
| 196 #endif | 178 #endif |
| OLD | NEW |