[gxml] Moved constants for GXml.DomNode.NodeType to an enum
- From: Daniel Espinosa Ortiz <despinosa src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gxml] Moved constants for GXml.DomNode.NodeType to an enum
- Date: Mon, 18 Jul 2016 05:44:42 +0000 (UTC)
commit 0ca50446a123c72313929e1cd6c4f36e5291601a
Author: Daniel Espinosa <esodan gmail com>
Date: Tue May 10 10:10:44 2016 -0500
Moved constants for GXml.DomNode.NodeType to an enum
gxml/DomNode.vala | 28 +++++++++++++++-------------
gxml/GXmlDocument.vala | 36 +++++++++++++++++++++++++++++++++++-
2 files changed, 50 insertions(+), 14 deletions(-)
---
diff --git a/gxml/DomNode.vala b/gxml/DomNode.vala
index 81401e8..1fb0fcd 100644
--- a/gxml/DomNode.vala
+++ b/gxml/DomNode.vala
@@ -21,19 +21,21 @@
*/
public interface GXml.DomNode : GLib.Object, GXml.DomEventTarget {
- public const ushort ELEMENT_NODE = 1;
- public const ushort ATTRIBUTE_NODE = 2; // historical
- public const ushort TEXT_NODE = 3;
- public const ushort CDATA_SECTION_NODE = 4; // historical
- public const ushort ENTITY_REFERENCE_NODE = 5; // historical
- public const ushort ENTITY_NODE = 6; // historical
- public const ushort PROCESSING_INSTRUCTION_NODE = 7;
- public const ushort COMMENT_NODE = 8;
- public const ushort DOCUMENT_NODE = 9;
- public const ushort DOCUMENT_TYPE_NODE = 10;
- public const ushort DOCUMENT_FRAGMENT_NODE = 11;
- public const ushort NOTATION_NODE = 12; // historical
- public abstract GXml.NodeType node_type { get; }
+ public enum NodeType {
+ ELEMENT_NODE = 1,
+ ATTRIBUTE_NODE, // historical
+ TEXT_NODE,
+ CDATA_SECTION_NODE, // historical
+ ENTITY_REFERENCE_NODE, // historical
+ ENTITY_NODE, // historical
+ PROCESSING_INSTRUCTION_NODE,
+ COMMENT_NODE,
+ DOCUMENT_NODE,
+ DOCUMENT_TYPE_NODE,
+ DOCUMENT_FRAGMENT_NODE,
+ NOTATION_NODE // historical
+ }
+ public abstract NodeType node_type { get; }
public abstract string node_name { owned get; }
public abstract string? base_uri { get; }
diff --git a/gxml/GXmlDocument.vala b/gxml/GXmlDocument.vala
index 10a99a0..2b24917 100644
--- a/gxml/GXmlDocument.vala
+++ b/gxml/GXmlDocument.vala
@@ -179,5 +179,39 @@ public class GXml.GDocument : GXml.GNode, GXml.Document
throws GLib.Error
{
return TDocument.tw_save_as (this, f, cancellable);
- }
+ }/*
+ // DomDocument implementation
+ public abstract DomImplementation implementation { get; }
+ public abstract string url { get; }
+ public abstract string document_uri { get; }
+ public abstract string origin { get; }
+ public abstract string compat_mode { get; }
+ public abstract string character_set { get; }
+ public abstract string content_type { get; }
+
+ public abstract DomDocumentType? doctype { get; }
+ public abstract DomElement? document_element { get; }
+
+ public abstract DomHTMLCollection get_elements_by_tag_name (string local_name);
+ public abstract DomHTMLCollection get_elements_by_tag_name_ns (string? namespace, string local_name);
+ public abstract DomHTMLCollection get_elements_by_class_name(string classNames);
+
+ public abstract DomElement create_element (string localName);
+ public abstract DomElement create_element_ns (string? namespace, string qualified_name);
+ public abstract DomDocumentFragment create_document_fragment();
+ public abstract DomText create_text_node (string data);
+ public abstract DomComment create_comment (string data);
+ public abstract DomProcessingInstruction create_processing_instruction (string target, string data);
+
+ public abstract DomNode import_node (DomNode node, bool deep = false);
+ public abstract DomNode adopt_node (DomNode node);
+
+ public abstract DomEvent create_event (string interface);
+
+ public abstract DomRange create_range();
+
+ // NodeFilter.SHOW_ALL = 0xFFFFFFFF
+ public abstract DomNodeIterator create_node_iterator (DomNode root, ulong whatToShow = (ulong) 0xFFFFFFFF,
DomNodeFilter? filter = null);
+ public abstract DomTreeWalker create_tree_walker (DomNode root, ulong what_to_show = (ulong) 0xFFFFFFFF,
DomNodeFilter? filter = null);
+ */
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]