| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2005 Frerich Raabe <raabe@kde.org> | 2 * Copyright (C) 2005 Frerich Raabe <raabe@kde.org> |
| 3 * Copyright (C) 2006, 2009 Apple Inc. | 3 * Copyright (C) 2006, 2009 Apple 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 10 matching lines...) Expand all Loading... |
| 21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
| 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 #include "core/xml/XPathUtil.h" | 27 #include "core/xml/XPathUtil.h" |
| 28 | 28 |
| 29 #include "core/dom/ContainerNode.h" | 29 #include "core/dom/ContainerNode.h" |
| 30 #include "core/dom/NodeTraversal.h" | 30 #include "core/dom/NodeTraversal.h" |
| 31 #include "wtf/text/StringBuilder.h" | 31 #include "platform/wtf/text/StringBuilder.h" |
| 32 | 32 |
| 33 namespace blink { | 33 namespace blink { |
| 34 namespace XPath { | 34 namespace XPath { |
| 35 | 35 |
| 36 bool IsRootDomNode(Node* node) { | 36 bool IsRootDomNode(Node* node) { |
| 37 return node && !node->parentNode(); | 37 return node && !node->parentNode(); |
| 38 } | 38 } |
| 39 | 39 |
| 40 String StringValue(Node* node) { | 40 String StringValue(Node* node) { |
| 41 switch (node->getNodeType()) { | 41 switch (node->getNodeType()) { |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 case Node::kDocumentFragmentNode: | 79 case Node::kDocumentFragmentNode: |
| 80 case Node::kDocumentTypeNode: | 80 case Node::kDocumentTypeNode: |
| 81 return false; | 81 return false; |
| 82 } | 82 } |
| 83 NOTREACHED(); | 83 NOTREACHED(); |
| 84 return false; | 84 return false; |
| 85 } | 85 } |
| 86 | 86 |
| 87 } // namespace XPath | 87 } // namespace XPath |
| 88 } // namespace blink | 88 } // namespace blink |
| OLD | NEW |