func (n *xmlNode) SetNodeValue(value string) { // TODO: Implement this in C if n.NodeType() != AttributeNode { C.xmlNodeSetContent(n.ptr, stringToXmlChar(value)) return } ptr := n.ptr if ptr.children != nil { ptr.last = nil C.xmlFreeNodeList(ptr.children) } ptr.children = C.xmlNewText(stringToXmlChar(value)) ptr.children.parent = ptr ptr.children.doc = ptr.doc ptr.last = ptr.children }
// xmlFreeNodeList func (node *Node) FreeList() { C.xmlFreeNodeList(node.Ptr) node.Ptr = nil }