// Set the local name of the node. The namespace is set via SetNamespace(). func (xmlNode *XmlNode) SetName(name string) { if len(name) > 0 { nameBytes := GetCString([]byte(name)) namePtr := unsafe.Pointer(&nameBytes[0]) C.xmlNodeSetName(xmlNode.Ptr, (*C.xmlChar)(namePtr)) } }
// xmlNodeSetName func (node *Node) SetName(name string) { ptr := C.CString(name) defer C.free_string(ptr) C.xmlNodeSetName(node.Ptr, C.to_xmlcharptr(ptr)) }
func (n *xmlNode) SetNodeName(name string) { C.xmlNodeSetName(n.ptr, stringToXmlChar(name)) }
// NodeSetName sets the name/tag of a node func (xp *Xp) NodeSetName(node *C.xmlNode, name string) { Cname := unsafe.Pointer(C.CString(name)) C.xmlNodeSetName(C.xmlNodePtr(node), (*C.xmlChar)(Cname)) C.free(Cname) }