| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * Copyright (C) 2000 Frederik Holljen (frederik.holljen@hig.no) | 3 * Copyright (C) 2000 Frederik Holljen (frederik.holljen@hig.no) |
| 4 * Copyright (C) 2001 Peter Kelly (pmk@post.com) | 4 * Copyright (C) 2001 Peter Kelly (pmk@post.com) |
| 5 * Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 * Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) |
| 6 * Copyright (C) 2004, 2008 Apple Inc. All rights reserved. | 6 * Copyright (C) 2004, 2008 Apple Inc. All rights reserved. |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 * Boston, MA 02110-1301, USA. | 21 * Boston, MA 02110-1301, USA. |
| 22 * | 22 * |
| 23 */ | 23 */ |
| 24 | 24 |
| 25 #ifndef Traversal_h | 25 #ifndef Traversal_h |
| 26 #define Traversal_h | 26 #define Traversal_h |
| 27 | 27 |
| 28 #include <wtf/Forward.h> | 28 #include <wtf/Forward.h> |
| 29 #include <wtf/RefPtr.h> | 29 #include <wtf/RefPtr.h> |
| 30 | 30 |
| 31 #if USE(JSC) | |
| 32 namespace KJS { | |
| 33 class JSValue; | |
| 34 class ExecState; | |
| 35 } | |
| 36 #endif | |
| 37 | 31 |
| 38 namespace WebCore { | 32 namespace WebCore { |
| 39 | 33 |
| 34 class ExceptionContext; |
| 40 class Node; | 35 class Node; |
| 41 class NodeFilter; | 36 class NodeFilter; |
| 42 | 37 |
| 43 class Traversal { | 38 class Traversal { |
| 44 public: | 39 public: |
| 45 Node* root() const { return m_root.get(); } | 40 Node* root() const { return m_root.get(); } |
| 46 unsigned whatToShow() const { return m_whatToShow; } | 41 unsigned whatToShow() const { return m_whatToShow; } |
| 47 NodeFilter* filter() const { return m_filter.get(); } | 42 NodeFilter* filter() const { return m_filter.get(); } |
| 48 bool expandEntityReferences() const { return m_expandEntityReferences; } | 43 bool expandEntityReferences() const { return m_expandEntityReferences; } |
| 49 | 44 |
| 50 protected: | 45 protected: |
| 51 Traversal(PassRefPtr<Node>, unsigned whatToShow, PassRefPtr<NodeFilter>,
bool expandEntityReferences); | 46 Traversal(PassRefPtr<Node>, unsigned whatToShow, PassRefPtr<NodeFilter>,
bool expandEntityReferences); |
| 52 #if USE(JSC) | 47 short acceptNode(ExceptionContext*, Node*) const; |
| 53 short acceptNode(KJS::ExecState*, Node*) const; | |
| 54 #endif | |
| 55 | 48 |
| 56 private: | 49 private: |
| 57 RefPtr<Node> m_root; | 50 RefPtr<Node> m_root; |
| 58 unsigned m_whatToShow; | 51 unsigned m_whatToShow; |
| 59 RefPtr<NodeFilter> m_filter; | 52 RefPtr<NodeFilter> m_filter; |
| 60 bool m_expandEntityReferences; | 53 bool m_expandEntityReferences; |
| 61 }; | 54 }; |
| 62 | 55 |
| 63 } // namespace WebCore | 56 } // namespace WebCore |
| 64 | 57 |
| 65 #endif // Traversal_h | 58 #endif // Traversal_h |
| OLD | NEW |