KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > taglibs > dbtags > resultset > WasNotEmptyTag


1
2 /*
3  * Copyright 1999,2004 The Apache Software Foundation.
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  */

17 package org.apache.taglibs.dbtags.resultset;
18
19
20 /**
21  * <p>Executes its body if the last ResultSet tag received more than 0 rows
22  * from the database. You must be after a ResultSet tag and inside
23  * a StatementTag or PreparedStatementTag, or an error will be generated.</p>
24  *
25  * <p>JSP Tag Lib Descriptor
26  * <pre>
27  * &lt;name>wasNotEmpty&lt;/name>
28  * &lt;tagclass>org.apache.taglibs.dbtags.statement.WasNotEmptyTag&lt;/tagclass>
29  * &lt;bodycontent>JSP&lt;/bodycontent>
30  * &lt;info>
31  * Executes its body if the last ResultSet tag received more than 0 rows
32  * from the database. You must be after a ResultSet tag and inside
33  * a StatementTag or PreparedStatementTag, or an error will be generated.
34  * &lt;/info>
35  * </pre>
36  *
37  * @author Morgan Delagrange
38  * @see WasEmptyTag
39  */

40 public class WasNotEmptyTag extends WasEmptyTag {
41
42   /**
43    * Constructor instructs the superclass to only
44    * execute the body if the last ResultSet returned
45    * more than 0 rows.
46    */

47   public WasNotEmptyTag() {
48     setValue(false);
49   }
50
51 }
52
53
Popular Tags