<?xml version="1.0"?> | |
<!-- | |
Copyright 2002,2004 The Apache Software Foundation. | |
Licensed under the Apache License, Version 2.0 (the "License"); | |
you may not use this file except in compliance with the License. | |
You may obtain a copy of the License at | |
http://www.apache.org/licenses/LICENSE-2.0 | |
Unless required by applicable law or agreed to in writing, software | |
distributed under the License is distributed on an "AS IS" BASIS, | |
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
See the License for the specific language governing permissions and | |
limitations under the License. | |
--> | |
<!-- this script represents some sample service that we will test | |
|| via Mock Tags | |
--> | |
<j:jelly xmlns:j="jelly:core" xmlns:my="myFoodWebService" xmlns:log="jelly:log"> | |
<!-- <sql:query var="results"> | |
select * from food where kind = ? | |
--> | |
<!-- lets pass in some parametrized value --> | |
<!-- <sql:param value="${foodKind}"/> | |
</sql:query> | |
--> | |
<!-- invoke some service | |
<j:forEach items="${results.rows}" var="row"> | |
<log:info>Found row with ID ${row.id}</log:info> | |
--> | |
<!-- this tag could invoke a web service etc | |
<my:eat cheese="${row.id}"/> --> | |
<!-- FIXME: Commented code above and repeated line are a | |
workaround as the sql taglib has been removed | |
--> | |
<my:eat cheese="abc"/> | |
<my:eat cheese="def"/> | |
<!-- </j:forEach> --> | |
</j:jelly> |