XML-, XML . xs:id xs:key ( ..) xpath . XML- 1: , .
-XML , (, , -), , XML- . XML, ( xs:import xs:include) - XML , XML- XML. - .
, , , , , , , XML , , , , , , , , . , :
/home/username/posts.xml:
<?xml version="1.0" encoding="UTF-8" ?>
<posts>
<post>
<author name="author1"/>
<comment id="12345" pos="1"/>
<comment id="12346" pos="2"/>
<body>I really like my camera...</body>
</post>
...
</posts>
/home/username/comments.xml:
<?xml version="1.0" encoding="UTF-8" ?>
<comments>
<comment id="12345" author="kindguy">
That was a very good post
</comment>
...
</comments>
/home/username/authors.xml:
<?xml version="1.0" encoding="UTF-8" ?>
<authors>
<author name="kindguy" id="1"/>
<author name="author1" id="2"/>
...
</authors>
-XML , Entity. , XML :
<?xml version="1.0" encoding="UTF-8" ?>
<!ENTITY postfile SYSTEM "file:///home/username/posts.xml">
<!ENTITY commentfile SYSTEM "file:///home/username/comments.xml">
<!ENTITY authorfile SYSTEM "file:///home/username/authors.xml">
<root>
&postfile1;
&commentfile;
&authorfile;
</root>
-XML ( XML ... "" - XML , XML) , XML , :
<?xml version="1.0" encoding="UTF-8" ?>
<root>
<posts>
<post>
<author name="author1"/>
<comment id="12345" pos="1"/>
<comment id="12346" pos="2"/>
<body>I really like my camera...</body>
</post>
...
</posts>
<comments>
<comment id="12345" author="kindguy">
That was a very good post
</comment>
...
</comments>
<authors>
<author name="kindguy" id="1"/>
<author name="author1" id="2"/>
...
</authors>
</root>
XML, , . XML-, XML , xpath .