java -jar treedemo.jar HOW TO START To browse an XML document, you need to take following steps. press "open a file" button in the window of the application select a file to open press the "OK" button Then you will see a tree root node of the document. You can see sub nodes of the root node by double clicking the root node. HOW TO TRAVERSE This application clearly shows starting resources by changing the icon color of the node to red. Note that the icon color of the starting resource is always red whether the actuate attribute is "onRequest" or not. There are two ways to start traversal. select the starting resource and click the "traversal" button place the mouse cursor on the starting resource and click your right mouse button"> java -jar treedemo.jar HOW TO START To browse an XML document, you need to take following steps. press "open a file" button in the window of the application select a file to open press the "OK" button Then you will see a tree root node of the document. You can see sub nodes of the root node by double clicking the root node. HOW TO TRAVERSE This application clearly shows starting resources by changing the icon color of the node to red. Note that the icon color of the starting resource is always red whether the actuate attribute is "onRequest" or not. There are two ways to start traversal. select the starting resource and click the "traversal" button place the mouse cursor on the starting resource and click your right mouse button">
Download presentation
Presentation is loading. Please wait.
1
XLINK A mechanism to link xml documents
2
Fujitsu’s free xlink processor http://software.fujitsu.com/en/interstage- xwand/activity/xbrltools/xlip/index.htmlhttp://software.fujitsu.com/en/interstage- xwand/activity/xbrltools/xlip/index.html download exe file and sample application. Note that at the time I downloaded the files the name of their sample application was NOT treedemo.jar but XLinkDemo.jar so the documentation is wrong in this regard.
3
From Fujitsu’s site Let's get startedTo run this demo application, you need to take following steps. install JDK 1.2.2(or later) in your computer, if you have not installed it. download the software (which includes the demo application) from the download pagedownload page execute the demo application –double click "treedemo.jar" (Windows Users) –execute the following command (Others) > java -jar treedemo.jar HOW TO START To browse an XML document, you need to take following steps. press "open a file" button in the window of the application select a file to open press the "OK" button Then you will see a tree root node of the document. You can see sub nodes of the root node by double clicking the root node. HOW TO TRAVERSE This application clearly shows starting resources by changing the icon color of the node to red. Note that the icon color of the starting resource is always red whether the actuate attribute is "onRequest" or not. There are two ways to start traversal. select the starting resource and click the "traversal" button place the mouse cursor on the starting resource and click your right mouse button
4
running treedemo (from Fujitsu site, continued) PROCEDURES TO SELECT THE ENDING RESOURCE If you start simple link's traversal, the application directly jumps to the ending resource. Otherwise, following steps occurs. If traversal starts, you will see the dialog which shows a list of arcs and radio buttons. You can start traversal from the list. The radio buttons indicate the type of show. Then if you select one of the items in the list, select the show type and press the "traversal" button, you will see another dialog which shows the locators list which has information about each ending resource. After you select one of the items in the list, the traversal action to the selected ending resource is actuated. NOTE: Characters displayed in both lists indicate the value of the related title attribute. NOTE: This simple procedure only exist to show the concept of XLink. It is easy to customize these actions more intuitively. Pointer Addressing This application provides XPointer addressing functions. After browsing a XML documents, press "Search with XPointer...". Then you will see a dialog box which has one input field. Input XPointer syntax in the field and press "OK" button. You will see the addressing result as highlighting them.
5
Xlink processor
6
C:\javaDir\bin>java XLinkDemo.jar (I moved the two xlink jar files to my java directory) –C:\PROGRA~1\JAVA\JDK15~1.0_0\BIN>java -jar XLinkDemo.jar
7
booklinks.dtd in notes Examples from Deitel’s text chapt 14 in notes.
8
booklinks.xml in notes –I’ve copied some of the arc links onto this slide <arcElement xlink:type = "arc" xlink:from = "JavaBook" xlink:arcrole = "http://deitel.com/xlink/info" xlink:to = "authorDeitel" xlink:show = "new" xlink:actuate = "onRequest" xlink:title = "About the author"/> <arcElement xlink:type = "arc" xlink:from = "JavaBook" xlink:arcrole = "http://deitel.com/xlink/info" xlink:to = "publisherPrenticeHall" xlink:show = "new" xlink:actuate = "onRequest" xlink:title = "About the publisher"/> <arcElement xlink:type = "arc" xlink:from = "publisherPrenticeHall" xlink:arcrole = "http://deitel.com/xlink/stock" xlink:to = "warehouseXYZ" xlink:show = "embed" xlink:actuate = "onLoad" xlink:title = "Publisher's inventory"/>
9
Traversing an outbound link: Booklinks.xml (before pressing button)
10
Selecting author after traversing the link
11
Pressing button “ok” opens a third JFrame
12
DTD and XLink Some details of namespace prefixes and so on can be hidden by providing a DTD for the XLinks.
13
A DTD for Booklinks <!ATTLIST books xmlns:xlink CDATA #FIXED "http://www.w3.org/1999/xlink" xlink:type (extended) #FIXED "extended" xlink:role CDATA #IMPLIED xlink:title CDATA #IMPLIED> <!ATTLIST book xlink:type (resource) #FIXED "resource" xlink:role CDATA #FIXED "http://deitel.com/xlink/book" xlink:title CDATA #IMPLIED xlink:label NMTOKEN #IMPLIED> <!ATTLIST author xlink:type (locator) #FIXED "locator" xlink:href CDATA #REQUIRED xlink:role CDATA #FIXED "http://deitel.com/xlink/author" xlink:title CDATA #IMPLIED xlink:label NMTOKEN #IMPLIED> <!ATTLIST publisher xlink:type (locator) #FIXED "locator" xlink:href CDATA #REQUIRED xlink:role CDATA #FIXED "http://deitel.com/xlink/publisher" xlink:title CDATA #IMPLIED xlink:label NMTOKEN #IMPLIED>
14
DTD continued <!ATTLIST warehouse xlink:type (locator) #FIXED "locator" xlink:href CDATA #REQUIRED xlink:role CDATA #FIXED "http://deitel.com/xlink/warehouse" xlink:title CDATA #IMPLIED xlink:label NMTOKEN #IMPLIED> <!ATTLIST arcElement xlink:type (arc) #FIXED "arc" xlink:arcrole CDATA #IMPLIED xlink:title CDATA #IMPLIED xlink:from NMTOKEN #IMPLIED xlink:to NMTOKEN #IMPLIED xlink:show (new | replace | embed | other | none) #IMPLIED xlink:actuate (onLoad | onRequest | other | none) #IMPLIED>
15
XPointer and XInclude These are not covered in the text but reference urls are provided: www.w3.org.TR/xptr www.w3.org.TR/xinclude
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.