Fast Leaf-to-Root Holistic Twig Query on XML Spatiotemporal Data
Luyi Bai · Journal of Computers · 2017
With the increasing applications based on location, the researches on spatiotemporal data, especially queries of spatiotemporal data have attracted a lot of attention.XML, as a standard language of information exchanging over the Web, should have the ability to query spatiotemporal data.In this paper, we propose an algorithm, TwigSPFast, for matching a spatiotemporal XML query twig pattern.We represent spatiotemporal data by adding spatial and temporal attributes in common data and extend Dewey code to mark spatiotemporal data for special process and determine structure relationship of spatiotemporal nodes.Our technique uses streams to store leaf nodes in XML corresponding to leaf query node and filters the streams to delete unmatched nodes, after filtering, we build output list for every matched leaf node that matches the query path from leaf node to root.It can be proved that TwigSPFast is optimal in time complexity and space complexity.