rapidxml
void name ( const Ch *  name,
std::size_t  size 
) [inline]

Sets name of node to a non zero-terminated string. See Ownership Of Strings.

Note that node does not own its name or value, it only stores a pointer to it. It will not delete or otherwise free the pointer on destruction. It is reponsibility of the user to properly manage lifetime of the string. The easiest way to achieve it is to use memory_pool of the document to allocate the string - on destruction of the document the string will be automatically freed.

Size of name must be specified separately, because name does not have to be zero terminated. Use name(const Ch *) function to have the length automatically calculated (string must be zero terminated).

Parameters:
nameName of node to set. Does not have to be zero terminated.
sizeSize of name, in characters. This does not include zero terminator, if one is present.

References xml_base< Ch >::name().