[gxml] * add documentation for DocumentType
- From: Richard Hans Schwarting <rschwart src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gxml] * add documentation for DocumentType
- Date: Thu, 21 Jul 2011 19:47:51 +0000 (UTC)
commit 4f44b5b680b306554b3793d7fd1121f2e5c13dea
Author: Richard Schwarting <aquarichy gmail com>
Date: Thu Jul 21 14:37:45 2011 -0400
* add documentation for DocumentType
gxml/DocumentType.vala | 26 +++++++++++++++++++++-----
1 files changed, 21 insertions(+), 5 deletions(-)
---
diff --git a/gxml/DocumentType.vala b/gxml/DocumentType.vala
index f25c0ec..fb304ba 100644
--- a/gxml/DocumentType.vala
+++ b/gxml/DocumentType.vala
@@ -1,6 +1,10 @@
/* -*- Mode: vala; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */
namespace GXml.Dom {
+ /**
+ * Defines a Document, such as the entities that it can use.
+ * For more, see: [[http://www.w3.org/TR/DOM-Level-1/level-one-core.html#ID-412266927]]
+ */
public class DocumentType : XNode {
private Xml.Dtd *int_subset;
private Xml.Dtd *ext_subset;
@@ -15,9 +19,13 @@ namespace GXml.Dom {
}
- /** Public properties */
+ /* Public properties */
- /* That which follows DOCTYPE, e.g. xml */
+ /**
+ * That which follows DOCTYPE, like 'xml' or 'html', For example, the name
+ * 'html' exists for a document with the XML doctype
+ * declaration of {{{ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> }}}
+ */
public string name {
get {
// TODO: is it possible for int_subset and ext_subset to have different names?
@@ -27,11 +35,16 @@ namespace GXml.Dom {
}
}
- public static void myScannerFull (void *payload, void *userdata, string name1, string name2, string name3) {
+ /* TODO: make more static methods internal instead of public, if possible */
+ internal static void myScannerFull (void *payload, void *userdata, string name1, string name2, string name3) {
GLib.message ("scanner found [%s,%s,%s]", name1, name2, name3);
}
/* using GHashTable for XML's NamedNodeMap */
+ /**
+ * A HashTable of entities defined for this DocumentType.
+ */
+ // TODO: provide examples
public HashTable<string,Entity>? entities {
get {
// TODO: need to create a HashTable<string,Entity> uniting these two
@@ -47,13 +60,16 @@ namespace GXml.Dom {
private set {
}
}
-
+ /**
+ * A HashTable of notations defined for this DocumentType.
+ */
+ // TODO: provide examples
public HashTable<string,Notation>? notations {
get {
// TODO: need to create a HashTable<string,Notation> uniting the two
// discard duplicates
// TODO: what type of hashtable is Xml.Dtd*'s notations?
- Xml.HashTable *table = this.int_subset->notations;
+ //Xml.HashTable *table = this.int_subset->notations;
return null;
// TODO: nuisance: libxml2 doesn't have notations wrapped
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]