MCPcopy Create free account
hub / github.com/Kitware/VTK / xmlXPtrNewLocationSetNodes

Function xmlXPtrNewLocationSetNodes

ThirdParty/libxml2/vtklibxml2/xpointer.c:754–770  ·  view source on GitHub ↗

* xmlXPtrNewLocationSetNodes: * @start: the start NodePtr value * @end: the end NodePtr value or NULL * * Create a new xmlXPathObjectPtr of type LocationSet and initialize * it with the single range made of the two nodes @start and @end * * Returns the newly created object. */

Source from the content-addressed store, hash-verified

752 * Returns the newly created object.
753 */
754xmlXPathObjectPtr
755xmlXPtrNewLocationSetNodes(xmlNodePtr start, xmlNodePtr end) {
756 xmlXPathObjectPtr ret;
757
758 ret = (xmlXPathObjectPtr) xmlMalloc(sizeof(xmlXPathObject));
759 if (ret == NULL) {
760 xmlXPtrErrMemory("allocating locationset");
761 return(NULL);
762 }
763 memset(ret, 0 , sizeof(xmlXPathObject));
764 ret->type = XPATH_LOCATIONSET;
765 if (end == NULL)
766 ret->user = xmlXPtrLocationSetCreate(xmlXPtrNewCollapsedRange(start));
767 else
768 ret->user = xmlXPtrLocationSetCreate(xmlXPtrNewRangeNodes(start,end));
769 return(ret);
770}
771
772/**
773 * xmlXPtrNewLocationSetNodeSet:

Callers 2

xmlXPtrHereFunctionFunction · 0.70
xmlXPtrOriginFunctionFunction · 0.70

Calls 4

xmlXPtrErrMemoryFunction · 0.85
xmlXPtrLocationSetCreateFunction · 0.70
xmlXPtrNewCollapsedRangeFunction · 0.70
xmlXPtrNewRangeNodesFunction · 0.70

Tested by

no test coverage detected