XIB: eXtensible Information Broker |
XIB Broker Builder
|
<?xml
version="1.0"?> <TEMPLATE> <CONSTRUCT> <newbook> <author> $a </author> <title> $t </title> <AmazonPrice> $p3 </AmazonPrice> <ChaptersPrice> $p2 </ChaptersPrice> </newbook> </CONSTRUCT> <WHERE> <SOURCE> <amazonBook> <author> $a </author> <title> $t </title> <price> $p1 </price> </amazonBook> <IN> AmazonSearch </IN> <CONDITION> amazonSearch.INPUT.query=newSearch.INPUT.queryString</CONDITION> </SOURCE> <AND/> <SOURCE> <chaptersBook> <authors> $a </authors> <bookName> $t </bookName> <ourPrice> $p2 </ourPrice> </chaptersBook> <IN> ChaptersSearch </IN> <CONDITION> ChaptersSearch.INPUT.queryString=newSearch.INPUT.queryString </CONDITION> </SOURCE> </WHERE> </TEMPLATE> |
This kind of template uses a simplified form of the XML query laguage called XML-QL. The major difference in the syntax of XIB templates is that the IN clause contains wrapper information, instead of an URL that points to a XML file. The Construct component of the template defines the intended output, i.e., a list of <newbook> elements which consist of elements <author>, <title>, <AmazonPrice> and <ChaptersPrice>. The Where part defines how to compose results from different information sources. Note that the strings preceded by the sign $ denote variables. In this example, the information sources are joined by the author and title.
Templates may be edited, loaded or saved in the following frame:
Maintained by Jianguo Lu |