首页 | 本学科首页   官方微博 | 高级检索  
相似文献
 共查询到20条相似文献,搜索用时 406 毫秒
1.
一种DTDs完全一致性判断算法   总被引:3,自引:1,他引:2  
一个语法上完全正确的DTD可能是不一致的,即不存在任何“有效的”XML文档遵循这个DTD·不一致的DTDs应当尽可能避免·现已提出的无完整性约束的DTDs一致性判断方法,考虑的都是如何判断整个DTDs是否存在有效的XML文档相对应,忽略了对DTDs结构中不合理的子结构的一致性判断,因此一致性成立的DTDs中仍有可能存在子结构没有相对应的有效XML数据·为解决这一问题,提出了DTDs完全一致性的概念,分析了能够导致DTDs不完全一致性的各种因素,并给出了线性时间复杂性的DTDs完全一致性判断算法·  相似文献   

2.
DTDs(或XML Schema)的一致性是XML研究中的一个重要课题.一个DTD是一致的当且仅当存在有效的XML文档遵循这个DTD.然而一个一致性成立的DTD仍有可能存在一致性不成立的不合理子结构,同一致性不成立的DTDs一样,DTDs中一致性不成立的子结构同样应该尽量避免.为解决这一问题,对"元素在DTD中的一致性"、"DTDs完全一致性"等概念进行了定义和分析,并给出了一种新的DTDs完全一致性判断算法,该算法的最坏时间复杂度是O(n),具有较高的效率.  相似文献   

3.
We investigate the typechecking problem for XML queries: statically verifying that every answer to a query conforms to a given output DTD, for inputs satisfying a given input DTD. This problem had been studied by a subset of the authors in a simplified framework that captured the structure of XML documents but ignored data values. We revisit here the typechecking problem in the more realistic case when data values are present in documents and tested by queries. In this extended framework, typechecking quickly becomes undecidable. However, it remains decidable for large classes of queries and DTDs of practical interest. The main contribution of the present paper is to trace a fairly tight boundary of decidability for typechecking with data values. The complexity of typechecking in the decidable cases is also considered.  相似文献   

4.
We study the typechecking problem for XML (eXtensible Markup Language) transformers: given an XML transformation program and a DTD for the input XML documents, check whether every result of the program conforms to a specified output DTD. We model XML transformers using a novel device called a k-pebble transducer, that can express most queries without data-value joins in XML-QL, XSLT, and other XML query languages. Types are modeled by regular tree languages, a robust extension of DTDs. The main result of the paper is that typechecking for k-pebble transducers is decidable. Consequently, typechecking can be performed for a broad range of XML transformation languages, including XML-QL and a fragment of XSLT.  相似文献   

5.
Program slicing is a well-known technique to extract the program statements that (potentially) affect the values computed at some point of interest. In this work, we introduce a novel slicing method for XML documents. Essentially, given an XML document (which is valid w.r.t. some DTD), we produce a new XML document (a slice) that contains the relevant information in the original XML document according to some criterion. Furthermore, we also output a new DTD such that the computed slice is valid w.r.t. this DTD. A prototype implementation of the XML slicer has been undertaken.  相似文献   

6.
XML documents are becoming popular for business process integration. To achieve interoperability between applications, XML documents must also conform to various commonly used data type definitions (DTDs). However, most business data are not maintained as XML documents. They are stored in various native formats, such as database tables or LDAP directories. Hence, a middleware is needed to dynamically generate XML documents conforming to predefined DTDs from various data sources. As industrial consortia and large corporations have created various DTDs, it is both challenging and time-consuming to design the necessary middleware to conform to so many different DTDs. This problem is particularly acute for a small- or medium-sized enterprise because it lacks the IT skills to quickly develop such a middleware. In this paper, we present XLE, an XML Lightweight Extractor, as a practical approach to dynamically extracting DTD-conforming XML documents from heterogeneous data sources. XLE is based on a framework called DTD source annotation (DTDSA). It treats a DTD as the control structure of a program. The annotations become the program statements, such as functions and assignments. DTD-conforming XML documents are generated by parsing annotated DTDs. Basically, DTD annotations describe declaratively the mappings between target XML documents and the source data. The XLE engine implements a few basic annotations, providing a practical solution for many small- and medium-sized enterprises. However, XLE is designed to be versatile. It allows sophisticated users to plug in their own implementations to access new types of data or to achieve better performance. Heterogeneous data sources can be simply specified in the annotations. A GUI tool is provided to highlight the places where annotations are needed.  相似文献   

7.
Type systems built directly into the compiler or interpreter of a programming language cannot be easily extended to keep track of run-time invariants of new abstractions. Yet, programming with domain-specific abstractions could benefit from additional static checking. This paper presents library techniques for extending the type system of C++ to support domain-specific abstractions. The main contribution is a programmable “subtype” relation. As a demonstration of the techniques, we implement a type system for defining type qualifiers in C++, as well as a type system for the XML processing language, capable of, e.g., statically guaranteeing that a program only produces valid XML documents according to a given XML schema.  相似文献   

8.
Many WWW applications generate hypertext markup language or extensible markup language (XML) documents dynamically. Current tools, however, like languages using document object model (DOM) or JAVA Server Pages do not allow to check the validity of the generated documents statically. Instead, validity has to be ‘checked’ dynamically by appropriate test runs. This paper addresses this problem by introducing a new distinct class for each element type of a document type definition (DTD). Each class extends the Element-class of the DOM. The resulting object model is called validating DOM (V-DOM). Parametric XML (P-XML) is an extension of XML allowing to insert values of the newly defined classes in places, where the corresponding element types are allowed according to the underlying DTD. Like V-DOM, P-XML guarantees the validity of all XML documents generated by using P-XML. V-DOM and P-XML are illustrated by several examples.  相似文献   

9.
Typechecking top-down XML transformations: Fixed input or output schemas   总被引:1,自引:0,他引:1  
Typechecking consists of statically verifying whether the output of an XML transformation always conforms to an output type for documents satisfying a given input type. In this general setting, both the input and output schema as well as the transformation are part of the input for the problem. However, scenarios where the input or output schema can be considered to be fixed, are quite common in practice. In the present work, we investigate the computational complexity of the typechecking problem in the latter setting.  相似文献   

10.
11.
针对XML流数据的复杂Twig Pattern查询处理   总被引:2,自引:0,他引:2  
XML流数据处理在研究领域引起了研究者的广泛兴趣.针对XML流数据的、具有嵌套AND/OR谓词的复杂Twig Pattern查询处理,提出一种新方法.为了提高查询处理性能,将所有Twig Pattern合并为一个共享前缀的查询树,其中,AND/OR谓词被表示为单独的抽象语法树,因而能够以文档顺序、单遍地处理复杂Twig Pattern的匹配,并避免了YFilter中对嵌套谓词进行后置处理所产生的中间结果.实验结果表明,该方法能够有效改善Twig Pattern的处理性能,尤其是在处理大文档的情况下.基于已  相似文献   

12.
从DTD映射到关系模式:一种保持数据依赖的映射方法   总被引:9,自引:0,他引:9  
XML正迅速成为互联网上数据表示和交换的标准.用关系数据库存储XML数据是XML存储策略之一.为了将XML数据存储到关系数据库中,人们研究了从DTD到关系模式的映射方法.提出了一种保持数据依赖的映射方法PDD.与已有的Shared—Inlining方法相比,PDD方法充分考虑了DTD蕴涵的数据依赖关系,保证了XML文档的完整性.通过对泛关系进行模式分解,得到的关系模式保持函数依赖,并且满足2NF.可以证明,这种方法是有效的.  相似文献   

13.
14.
基于DTD节点自动机的XML模式验证方法   总被引:1,自引:0,他引:1  
XML已经成为Web环境中数据表示和交换的标准。XML的模式验证在XML的使用中地位重要。DTD作为模式描述的一种方法,应用广泛,但使用DTD描述的模式不能正常表示同构的XML数据。文章扩展了DTD并提出了一种基于自动机的模式验证方法,将扩展的DTD中每个元素转换为一个自动机,将XML文档编码为字符串,并将字符串作为自动机的输入进行验证,可以有效地验证同构的XML。  相似文献   

15.
XML Schema与DTD的比较及应用   总被引:3,自引:0,他引:3  
XML是目前广泛应用的数据交换标准,而模式是应用XML进行数据交换的正确性的保证机制之一。模式详细描述了文档的结构,确保文档的元素和属性等的正确性。XML Schema和DTD是其中应用最广泛的模式。文中详细比较了两者的异同,并指出了各自的局限及最佳的应用,DTD非常适合于文本密集型XML文档,而XML Schema更适合于数据密集型XML文档。  相似文献   

16.
XML access control models proposed in the literature enforce access restrictions directly on the structure and content of an XML document. Therefore access authorization rules (authorizations, for short), which specify access rights of users on information within an XML document, must be revised if they do not match with changed structure of the XML document. In this paper, we present two authorization translation problems. The first is a problem of translating instance-level authorizations for an XML document. The second is a problem of translating schema-level authorizations for a collection of XML documents conforming to a DTD. For the first problem, we propose an algorithm that translates instance-level authorizations of a source XML document into those for a transformed XML document by using instance-tree mapping from the transformed document instance to the source document instance. For the second problem, we propose an algorithm that translates value-independent schema-level authorizations of non-recursive source DTD into those for a non-recursive target DTD by using schema-tree mapping from the target DTD to the source DTD. The goal of authorization translation is to preserve authorization equivalence at instance node level of the source document. The XML access control models use path expressions of XPath to locate data in XML documents. We define property of the path expressions (called node-reducible path expressions) that we can transform schema-level authorizations of value-independent type by schema-tree mapping. To compute authorizations on instances of schema elements of the target DTD, we need to identify the schema elements whose instances are located by a node-reducible path expression of a value-independent schema-level authorization. We give an algorithm that carries out path fragment containment test to identify the schema elements whose instances are located by a node-reducible path expression.  相似文献   

17.
《IT Professional》2001,3(2):37-40
Schemas add data typing and inheritance features, giving XML the sophistication required to create enterprise-class business applications. The XML schema language describes the legal structure, content, and constraints of XML documents. The XML schema language provides the necessary framework for creating XML documents by specifying the valid structure, constraints, and data types for the various elements and attributes of an XML document. Schema language provides enhanced as well as more comprehensive and powerful features than a document type definition (DTD). The XML schema language provides the rich data typing associated with ordinary programming languages. The W3C XML schema specification defines several different built-in data types, such as string, integer, Boolean, date, and time, among others. The specification also provides the capability for defining new types. Developers can use these built-in as well as user-defined data types to effectively define and constrain XML document attributes and element values  相似文献   

18.
存在多值依赖的XML DTD规范化研究   总被引:1,自引:0,他引:1  
丘威  张立臣 《计算机科学》2007,34(2):149-151
XML DTD文档中可能包含由非函数依赖引起的数据冗余和操作异常,首先从消除DTD文档内数据冗余的角度出发研究了文档的规范化的问题,讨论了在DTD文档中存在多值依赖的情况下,如何规范XML文档,提出了以DTD为模式的XML文档的多值依赖的概念。然后基于多值依赖的概念,提出了XML文档的一种多值依赖范式MXNF。最后在此基础上提出了把一个XML文档的DTD无损联接地分解成为符合MXNF的规范化算法,来规范存在多值依赖的XML DTD文档,并给出了该算法的分析说明。  相似文献   

19.
Typechecking consists of statically verifying whether the output of an XML transformation is always conform to an output type for documents satisfying a given input type. We focus on complete algorithms which always produce the correct answer. We consider top–down XML transformations incorporating XPath expressions and abstract document types by grammars and tree automata. By restricting schema languages and transformations, we identify several practical settings for which typechecking can be done in polynomial time. Moreover, the resulting framework provides a rather complete picture as we show that most scenarios cannot be enlarged without rendering the typechecking problem intractable. So, the present research sheds light on when to use fast complete algorithms and when to reside to sound but incomplete ones.  相似文献   

20.
一个从关系数据模型到XML文档的翻译器设计   总被引:3,自引:0,他引:3  
XML技术与关系数据模型的关系非常密切,将关系数据库中的数据转换为XML文档格式有着重要的现实意义,本文介绍了利用OmniMark语言开发一个从关系数据模型到XML文档翻译器的方法,重点分析了关系模式、DTD与XMLSchemas,跨平台无关性,SGML语法检查等关键技术。  相似文献   

设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号