| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2005 Maksim Orlovich <maksim@kde.org> | 2 * Copyright 2005 Maksim Orlovich <maksim@kde.org> |
| 3 * Copyright (C) 2006 Apple Computer, Inc. | 3 * Copyright (C) 2006 Apple Computer, Inc. |
| 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 * | 8 * |
| 9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF | 23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF |
| 24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 24 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 25 */ | 25 */ |
| 26 | 26 |
| 27 #ifndef XPathParser_h | 27 #ifndef XPathParser_h |
| 28 #define XPathParser_h | 28 #define XPathParser_h |
| 29 | 29 |
| 30 #include "core/xml/XPathPredicate.h" | 30 #include "core/xml/XPathPredicate.h" |
| 31 #include "core/xml/XPathStep.h" | 31 #include "core/xml/XPathStep.h" |
| 32 #include "wtf/Allocator.h" |
| 32 | 33 |
| 33 namespace blink { | 34 namespace blink { |
| 34 | 35 |
| 35 class ExceptionState; | 36 class ExceptionState; |
| 36 class XPathNSResolver; | 37 class XPathNSResolver; |
| 37 | 38 |
| 38 namespace XPath { | 39 namespace XPath { |
| 39 | 40 |
| 40 class Expression; | 41 class Expression; |
| 41 class LocationPath; | 42 class LocationPath; |
| 42 class ParseNode; | 43 class ParseNode; |
| 43 class Parser; | 44 class Parser; |
| 44 class Predicate; | 45 class Predicate; |
| 45 | 46 |
| 46 struct Token { | 47 struct Token { |
| 48 STACK_ALLOCATED(); |
| 47 int type; | 49 int type; |
| 48 String str; | 50 String str; |
| 49 Step::Axis axis; | 51 Step::Axis axis; |
| 50 NumericOp::Opcode numop; | 52 NumericOp::Opcode numop; |
| 51 EqTestOp::Opcode eqop; | 53 EqTestOp::Opcode eqop; |
| 52 | 54 |
| 53 Token(int t) : type(t) { } | 55 Token(int t) : type(t) { } |
| 54 Token(int t, const String& v): type(t), str(v) { } | 56 Token(int t, const String& v): type(t), str(v) { } |
| 55 Token(int t, Step::Axis v): type(t), axis(v) { } | 57 Token(int t, Step::Axis v): type(t), axis(v) { } |
| 56 Token(int t, NumericOp::Opcode v): type(t), numop(v) { } | 58 Token(int t, NumericOp::Opcode v): type(t), numop(v) { } |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 | 110 |
| 109 HashSet<OwnPtr<String>> m_strings; | 111 HashSet<OwnPtr<String>> m_strings; |
| 110 }; | 112 }; |
| 111 | 113 |
| 112 } // namespace XPath | 114 } // namespace XPath |
| 113 | 115 |
| 114 } // namespace blink | 116 } // namespace blink |
| 115 | 117 |
| 116 int xpathyyparse(blink::XPath::Parser*); | 118 int xpathyyparse(blink::XPath::Parser*); |
| 117 #endif | 119 #endif |
| OLD | NEW |