# $Id: SimpleReport.rep,v 1.1 2004/03/26 12:17:29 graham Exp $ # # Copyright (c) 2004, G. KLYNE. All rights reserved. # See end of this file for licence information. #--------+---------+---------+---------+---------+---------+---------+---------+ @prefix rdf: . @prefix rdfs: . @prefix foaf: . @prefix hdr: . @prefix hrep: . # , "hrep:SimpleReport :-" # , " ( [ rep:cmd rep:open ; rep:chan \"t\" ;" # , " rep:file \"SimpleReport.tmp\" ]" # , " [ rep:cmd rep:write ; rep:chan \"t\" ; rep:data hrep:SimpleHead ]" # , " [ rep:cmd rep:for ; rep:pattern hrep:SimplePattern ;" # , " rep:do" # , " ( [ rep:cmd rep:write ; rep:chan \"t\" ; rep:data hrep:SimpleItem ] ) ]" # , " [ rep:cmd rep:write ; rep:chan \"t\" ; rep:data hrep:SimpleFoot ]" # , " [ rep:cmd rep:close ; rep:chan \"t\" ] ) ." # , "" # , "hrep:SimplePattern :-" # , " ( [ rep:var \"item\" ]" # , " [ rep:and" # , " ( [ rep:uri rdf:type ] [ rep:uri hdr:SimpleType ] )," # , " ( [ rep:uri hdr:name ] [ rep:var \"name\" ] )," # , " ( [ rep:opt" # , " ( [ rep:uri hdr:label ] [ rep:var \"label\" ] ) ] ) " # , " ]" # , " ) ." # , "" # , "hrep:SimpleHead :-" # , " ( \"Simple head\" rep:nl ) ." # , "hrep:SimpleItem :-" # , " ( \"\" rep:nl" # , " \" \" [rep:var \"name\"] \" \" rep:nl" # , " [ rep:if [rep:defined \"label\"] ;" # , " rep:do ( \" \" rep:nl ) ]" # , " \"\" rep:nl" # , " ) ." # , "hrep:SimpleFoot :-" # , " ( \"Simple foot\" rep:nl ) ." @report hrep:SimpleReport OPEN "t" "SimpleReport.tmp" WRITE "t" hrep:SimpleHead FOREACH hrep:SimplePattern WRITE "t" hrep:SimpleItem END WRITE "t" hrep:SimpleFoot CLOSE "t" END @query hrep:SimplePattern ( ?item ( rdf:type hdr:SimpleType & hdr:name ?name & [ hdr:label ?label ] ) ) @text hrep:SimpleHead ( "Simple head" NL ) @text hrep:SimpleItem ( "" NL " " ?name " " NL (IFDEF ?label : " " NL ) "" NL ) @text hrep:SimpleFoot ( "Simple foot" NL ) #--------+---------+---------+---------+---------+---------+---------+---------+ # # Copyright (c) 2004, G. KLYNE. All rights reserved. # # This is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This software is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this software; if not, write to: # The Free Software Foundation, Inc., # 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # or view the web page at: # http://www.gnu.org/copyleft/gpl.html # #--------+---------+---------+---------+---------+---------+---------+---------+ # $Source: /file/cvsdev/CompileRDF/SimpleReport.rep,v $ # $Author: graham $ # $Revision: 1.1 $ # $Log: SimpleReport.rep,v $ # Revision 1.1 2004/03/26 12:17:29 graham # Test input data for report description compiler #