Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(734)

Unified Diff: Source/core/dom/XMLDocument.h

Issue 144063004: Add support for DOM4's XMLDocument interface (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Remove FIXME about XMLDocument.load() Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/dom/Document.idl ('k') | Source/core/dom/XMLDocument.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/XMLDocument.h
diff --git a/Source/modules/speech/SpeechRecognitionAlternative.h b/Source/core/dom/XMLDocument.h
similarity index 64%
copy from Source/modules/speech/SpeechRecognitionAlternative.h
copy to Source/core/dom/XMLDocument.h
index 464fe9e276e55c1839128720679955974880448b..b65b19ca4252db5e31af60a994e778762187b971 100644
--- a/Source/modules/speech/SpeechRecognitionAlternative.h
+++ b/Source/core/dom/XMLDocument.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2012 Google Inc. All rights reserved.
+ * Copyright (C) 2014 Samsung Electronics. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -23,31 +23,32 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef SpeechRecognitionAlternative_h
-#define SpeechRecognitionAlternative_h
+#ifndef XMLDocument_h
+#define XMLDocument_h
-#include "bindings/v8/ScriptWrappable.h"
-#include "wtf/RefCounted.h"
-#include "wtf/text/WTFString.h"
+#include "core/dom/Document.h"
+#include "wtf/PassRefPtr.h"
namespace WebCore {
-class ExecutionContext;
-
-class SpeechRecognitionAlternative : public ScriptWrappable, public RefCounted<SpeechRecognitionAlternative> {
+class XMLDocument : public Document {
public:
- static PassRefPtr<SpeechRecognitionAlternative> create(const String&, double);
-
- const String& transcript() const { return m_transcript; }
- double confidence() const { return m_confidence; }
-
-private:
- SpeechRecognitionAlternative(const String&, double);
-
- String m_transcript;
- double m_confidence;
+ static PassRefPtr<XMLDocument> create(const DocumentInit& initializer = DocumentInit())
+ {
+ return adoptRef(new XMLDocument(initializer, XMLDocumentClass));
+ }
+
+ static PassRefPtr<XMLDocument> createXHTML(const DocumentInit& initializer = DocumentInit())
+ {
+ return adoptRef(new XMLDocument(initializer, XMLDocumentClass | XHTMLDocumentClass));
+ }
+
+protected:
+ XMLDocument(const DocumentInit&, DocumentClassFlags documentClasses);
};
+DEFINE_DOCUMENT_TYPE_CASTS(XMLDocument);
+
} // namespace WebCore
-#endif // SpeechRecognitionAlternative_h
+#endif // XMLDocument_h
« no previous file with comments | « Source/core/dom/Document.idl ('k') | Source/core/dom/XMLDocument.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698