summaryrefslogtreecommitdiff
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Begin to cater for XML namespaces.John Mark Bell2007-09-264-56/+113
| | | | | | | | | | | The localname member of Node has been removed. The name member already caters for this. Fix NodeList to cope with this and add some pointer vs NULL comparisons for sanity. Replace implementation of dom_element_get_tag_name() with a simple call to dom_node_get_node_name(), which is where the gory details lie. Add the QName building stuff to dom_node_get_node_name() (as per previous implementation of dom_element_get_tag_name()). Implement dom_node_set_prefix(). Ensure dom_node_get_local_name() returns NULL for nodes created by non-namespace-aware methods (nodes must also be Elements or Attributes) svn path=/trunk/dom/; revision=3596
* Add library-internal accessor to the head of an Element's attribute list ↵John Mark Bell2007-09-253-19/+171
| | | | | | | | | | | | | | (dom_element_get_first_attribute()) Implement dom_namednodemap_get_length() Implement dom_namednodemap_get_named_item() Implement dom_namednodemap_set_named_item() Implement dom_namednodemap_remove_named_item() Implement dom_namednodemap_item() All dom_namednodemap_*() still require support for maps of Entity and Notation nodes to be added (this requires DocumentType to gain support for these nodes). svn path=/trunk/dom/; revision=3591
* Move attributes field to struct dom_element as it doesn't apply to other ↵John Mark Bell2007-09-244-22/+69
| | | | | | node types. svn path=/trunk/dom/; revision=3590
* Implement dom_nodelist_get_length()John Mark Bell2007-09-241-9/+111
| | | | | | Implement dom_nodelist_item() svn path=/trunk/dom/; revision=3589
* Add dom_entity_reference_get_textual_representation() as an internal library ↵John Mark Bell2007-09-233-3/+142
| | | | | | | | function. Implement dom_attr_get_value() svn path=/trunk/dom/; revision=3588
* Fix compilation errors. It helps if you compile things before committing them...John Mark Bell2007-09-231-4/+5
| | | | svn path=/trunk/dom/; revision=3583
* Partial implementation of dom_attr_get_name()John Mark Bell2007-09-231-15/+56
| | | | | | | Implement dom_attr_set_value() Rework dom_attr_get_owner() to make use of base class' parent pointer rather than having an explicit owner pointer (the base class' parent pointer would be unused, otherwise, and the Node class is aware that attributes have no parent, so this is safe) svn path=/trunk/dom/; revision=3582
* Fix dom_node_{get,set}_value() to handle Attr nodes correctly -- now ↵John Mark Bell2007-09-231-0/+10
| | | | | | delegates value accesses to the Attr-specific functions. svn path=/trunk/dom/; revision=3581
* Fix dom_element_set_attribute() to use dom_attr_set_value() to replace the ↵John Mark Bell2007-09-231-5/+4
| | | | | | value of an existing attribute -- attribute values are stored as a tree of child nodes, not as a string attached to the nodeValue pointer. svn path=/trunk/dom/; revision=3580
* Fix dom_node_get_parent_node(), dom_node_get_previous_sibling() and ↵John Mark Bell2007-09-231-0/+18
| | | | | | dom_node_get_next_sibling() to return NULL for Attr nodes. svn path=/trunk/dom/; revision=3579
* Note the need for handling of defaulted attributes in ↵John Mark Bell2007-09-221-0/+4
| | | | | | dom_element_remove_attribute{_node} svn path=/trunk/dom/; revision=3578
* Implement dom_element_get_attribute()John Mark Bell2007-09-221-36/+154
| | | | | | | | | | | | | Implement dom_element_set_attribute() Implement dom_element_remove_attribute() Implement dom_element_get_attribute_node() Make dom_element_set_attribute_node() ensure that the element is writable Implement dom_element_remove_attribute_node() Implement dom_element_get_elements_by_tag_name() Implement dom_element_get_elements_by_tag_name_ns() Implement dom_element_has_attribute() svn path=/trunk/dom/; revision=3577
* Make _dom_node_readonly() accessible to library internalsJohn Mark Bell2007-09-222-1/+4
| | | | svn path=/trunk/dom/; revision=3576
* Implement dom_document_get_implementation()John Mark Bell2007-09-221-14/+13
| | | | | | | Implement dom_document_get_elements_by_tag_name() Implement dom_document_get_elements_by_tag_name_ns() svn path=/trunk/dom/; revision=3572
* Implement dom_node_get_child_nodes()John Mark Bell2007-09-221-8/+21
| | | | | | Implement dom_node_get_attributes() svn path=/trunk/dom/; revision=3570
* Whitespace changesJohn Mark Bell2007-09-222-1/+3
| | | | svn path=/trunk/dom/; revision=3569
* Assume that NULL dom_string pointers imply the empty string.John Mark Bell2007-09-221-0/+17
| | | | svn path=/trunk/dom/; revision=3561
* Implement dom_node_remove_node()John Mark Bell2007-09-221-11/+46
| | | | | | | Make _dom_node_replace() handle DocumentFragments correctly. Ensure _dom_node_detach_range() clears range's previous/next pointers. svn path=/trunk/dom/; revision=3558
* Implement dom_node_replace_child()John Mark Bell2007-09-221-5/+83
| | | | svn path=/trunk/dom/; revision=3557
* If new_child is already in the tree ensure its parent is not read onlyJohn Mark Bell2007-09-221-2/+7
| | | | svn path=/trunk/dom/; revision=3556
* Fix misleading commentsJohn Mark Bell2007-09-221-13/+12
| | | | svn path=/trunk/dom/; revision=3555
* Move cardinality constraint checking for Document Element and DocumentType ↵John Mark Bell2007-09-221-89/+130
| | | | | | | | children to _dom_node_permitted_child(). Break tree insertion/removal code out from dom_node_insert_before() and into their own utility routines. svn path=/trunk/dom/; revision=3554
* Implement dom_node_get_node_name()John Mark Bell2007-09-201-12/+133
| | | | | | | | Implement dom_node_get_node_value() Implement dom_node_set_node_value() Implement utility routines to determine if a given node type is permitted as a child of a node and to detect if a given node is read only. svn path=/trunk/dom/; revision=3553
* Begin implementation of DocumentType classJohn Mark Bell2007-09-194-63/+157
| | | | | | | | | | | | | | | Remove dom_document_set_doctype() -- dom_node_insert_before() (and thus _append_child()) can be used to achieve the same effect. DocumentType node is now a child of the Document node (as it should have been) rather than a hidden field. Make dom_node_destroy() aware of DocumentType nodes potentially having no owner. Make dom_node_finalise() aware of it, too. Make dom_node_get_owner_document() return NULL for Document nodes, as per the spec. Fix bug in dom_node_insert_before() -- previously it failed to catch attempts to insert a second root element. Make dom_node_insert_before() handle DocumentType nodes appropriately. Implement XML binding's dom_implementation_create_document_type() function. Fix XML binding's dom_implementation_create_document() implementation to cope with changed API relating to doctype insertion. Fix up XML parser wrapper to cater for new doctype insertion mechanism. Also sprinkle some NULL about for paranoia purposes. svn path=/trunk/dom/; revision=3551
* Implement dom_element_get_tag_name()John Mark Bell2007-09-181-8/+105
| | | | | | Implement dom_element_set_attribute_node() [still has some outstanding sanity checking] svn path=/trunk/dom/; revision=3549
* Implement sanity checking in dom_node_insert_before()John Mark Bell2007-09-181-18/+116
| | | | | | There's still a couple of outstanding issues here, marked as todos. svn path=/trunk/dom/; revision=3548
* Partial implementation of dom_node_insert_before. This has utterly no sanity ↵John Mark Bell2007-09-171-5/+29
| | | | | | checking at present so will probably break, badly. svn path=/trunk/dom/; revision=3546
* Make Document nodes own themselves (removes need for special case for Documents)John Mark Bell2007-09-172-17/+78
| | | | | | | Fixup dom_node_destroy appropriately. Implement dom_node_{set,get}_user_data. svn path=/trunk/dom/; revision=3542
* Fix bug in dom_node_destroy -- Document nodes have no owner, so attempting ↵John Mark Bell2007-09-161-8/+18
| | | | | | to ref/unref it is stupid svn path=/trunk/dom/; revision=3538
* Rename dom_named_node_map to dom_namednodemap to be consistent with the rest ↵James Shaw2007-08-081-2/+2
| | | | | | of the code svn path=/trunk/dom/; revision=3489
* Fix structure name dom_nodelistJames Shaw2007-08-031-2/+2
| | | | svn path=/trunk/dom/; revision=3474
* Comment fixesJohn Mark Bell2007-07-291-2/+2
| | | | svn path=/trunk/dom/; revision=3470
* Implement Document destructor.John Mark Bell2007-07-283-8/+109
| | | | | | Fix handling of nodes within a document (they no longer explicitly reference the document) svn path=/trunk/dom/; revision=3468
* Finalisation and destruction of nodesJohn Mark Bell2007-07-2821-5/+463
| | | | svn path=/trunk/dom/; revision=3467
* Add Document constructorJohn Mark Bell2007-07-281-3/+104
| | | | svn path=/trunk/dom/; revision=3466
* Sort out somewhat messy object construction.John Mark Bell2007-07-2818-144/+465
| | | | | | We now have explicit types for all classes (rather than using the parent class for those which inherit but add no extra data content). svn path=/trunk/dom/; revision=3465
* Implement type-specific node constructors and veneer the appropriate ↵John Mark Bell2007-07-2614-82/+409
| | | | | | Document APIs onto them. svn path=/trunk/dom/; revision=3463
* Add ability to set a document's doctype after the document has been createdJohn Mark Bell2007-07-261-0/+30
| | | | svn path=/trunk/dom/; revision=3462
* Add omitted dom_document_create_comment APIJohn Mark Bell2007-07-221-0/+23
| | | | svn path=/trunk/dom/; revision=3459
* More name changes for consistency with specJames Shaw2007-07-211-6/+6
| | | | svn path=/trunk/dom/; revision=3455
* rename dom_document_get_element() to dom_document_get_document_element()James Shaw2007-07-211-1/+1
| | | | svn path=/trunk/dom/; revision=3453
* Add email addressJames Shaw2007-07-191-1/+1
| | | | svn path=/trunk/dom/; revision=3442
* Fix typoJohn Mark Bell2007-07-161-1/+1
| | | | svn path=/trunk/dom/; revision=3425
* Stub out remainder of DocumentType API.John Mark Bell2007-07-161-3/+131
| | | | | | Minor other changes. svn path=/trunk/dom/; revision=3424
* Stub implementation of of dom_document_type methodsJames Shaw2007-07-162-1/+20
| | | | svn path=/trunk/dom/; revision=3422
* Rename to dom_node_get_owner_document() in line with specJames Shaw2007-07-151-1/+1
| | | | svn path=/trunk/dom/; revision=3414
* Add extra dom_string constructor that permits strings to be manufactured in ↵John Mark Bell2007-07-141-10/+80
| | | | | | | | the situation where there exists no document. This should only be used in order to create dom_strings for use by DocumentType and Document constructors -- in any other situation, a suitable document already exists. svn path=/trunk/dom/; revision=3411
* Modify node value, type and name functions to match w3c specJames Shaw2007-07-141-4/+4
| | | | svn path=/trunk/dom/; revision=3409
* Make NamedNodeMap more genericJohn Mark Bell2007-07-124-35/+28
| | | | svn path=/trunk/dom/; revision=3404
* Add DOMImplementation, DOMImplementationListJohn Mark Bell2007-07-126-2/+507
| | | | | | | | | Add DOMImplementationRegistry Define DOMImplementationSource and provide API to allow their registration This little lot should permit some kind of sensible DOM bootstrapping. svn path=/trunk/dom/; revision=3403