| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 5 * Copyright (C) 2004, 2005, 2006, 2008 Apple Inc. All rights reserved. | 5 * Copyright (C) 2004, 2005, 2006, 2008 Apple Inc. All rights reserved. |
| 6 * | 6 * |
| 7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 #include "core/CoreExport.h" | 27 #include "core/CoreExport.h" |
| 28 #include "core/dom/Document.h" | 28 #include "core/dom/Document.h" |
| 29 | 29 |
| 30 namespace blink { | 30 namespace blink { |
| 31 | 31 |
| 32 class Document; | 32 class Document; |
| 33 class DocumentInit; | 33 class DocumentInit; |
| 34 class DocumentType; | 34 class DocumentType; |
| 35 class ExceptionState; | 35 class ExceptionState; |
| 36 class HTMLDocument; | 36 class HTMLDocument; |
| 37 class LocalDOMWindow; |
| 37 class XMLDocument; | 38 class XMLDocument; |
| 38 | 39 |
| 39 class CORE_EXPORT DOMImplementation final | 40 class CORE_EXPORT DOMImplementation final |
| 40 : public GarbageCollected<DOMImplementation>, | 41 : public GarbageCollected<DOMImplementation>, |
| 41 public ScriptWrappable { | 42 public ScriptWrappable { |
| 42 DEFINE_WRAPPERTYPEINFO(); | 43 DEFINE_WRAPPERTYPEINFO(); |
| 43 | 44 |
| 44 public: | 45 public: |
| 45 static DOMImplementation* Create(Document& document) { | 46 static DOMImplementation* Create(Document& document) { |
| 46 return new DOMImplementation(document); | 47 return new DOMImplementation(document); |
| 47 } | 48 } |
| 48 | 49 |
| 49 Document& GetDocument() const { return *document_; } | 50 Document& GetDocument() const { return *document_; } |
| 50 | 51 |
| 51 // DOM methods & attributes for DOMImplementation | 52 // DOM methods & attributes for DOMImplementation |
| 52 bool hasFeature() { return true; } | 53 bool hasFeature() { return true; } |
| 53 DocumentType* createDocumentType(const AtomicString& qualified_name, | 54 DocumentType* createDocumentType(const AtomicString& qualified_name, |
| 54 const String& public_id, | 55 const String& public_id, |
| 55 const String& system_id, | 56 const String& system_id, |
| 56 ExceptionState&); | 57 ExceptionState&); |
| 57 XMLDocument* createDocument(const AtomicString& namespace_uri, | 58 XMLDocument* createDocument(const LocalDOMWindow*, |
| 59 const AtomicString& namespace_uri, |
| 58 const AtomicString& qualified_name, | 60 const AtomicString& qualified_name, |
| 59 DocumentType*, | 61 DocumentType*, |
| 60 ExceptionState&); | 62 ExceptionState&); |
| 61 | 63 |
| 62 // From the HTMLDOMImplementation interface | 64 // From the HTMLDOMImplementation interface |
| 63 HTMLDocument* createHTMLDocument(const String& title); | 65 HTMLDocument* createHTMLDocument(const String& title); |
| 64 | 66 |
| 65 // Other methods (not part of DOM) | 67 // Other methods (not part of DOM) |
| 66 static Document* createDocument(const String& mime_type, | 68 static Document* createDocument(const String& mime_type, |
| 67 const DocumentInit&, | 69 const DocumentInit&, |
| 68 bool in_view_source_mode); | 70 bool in_view_source_mode); |
| 69 | 71 |
| 70 static bool IsXMLMIMEType(const String&); | 72 static bool IsXMLMIMEType(const String&); |
| 71 static bool IsTextMIMEType(const String&); | 73 static bool IsTextMIMEType(const String&); |
| 72 static bool IsJSONMIMEType(const String&); | 74 static bool IsJSONMIMEType(const String&); |
| 73 | 75 |
| 74 DECLARE_TRACE(); | 76 DECLARE_TRACE(); |
| 75 | 77 |
| 76 private: | 78 private: |
| 77 explicit DOMImplementation(Document&); | 79 explicit DOMImplementation(Document&); |
| 78 | 80 |
| 79 Member<Document> document_; | 81 Member<Document> document_; |
| 80 }; | 82 }; |
| 81 | 83 |
| 82 } // namespace blink | 84 } // namespace blink |
| 83 | 85 |
| 84 #endif // DOMImplementation_h | 86 #endif // DOMImplementation_h |
| OLD | NEW |