📄 result.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"><!--NewPage--><HTML><HEAD><!-- Generated by javadoc (build 1.4.2_05) on Mon Oct 25 13:31:38 PDT 2004 --><TITLE>Result</TITLE><META NAME="keywords" CONTENT="javax.servlet.jsp.jstl.sql.Result interface"><LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style"><SCRIPT type="text/javascript">function windowTitle(){ parent.document.title="Result";}</SCRIPT></HEAD><BODY BGCOLOR="white" onload="windowTitle();"><!-- ========= START OF TOP NAVBAR ======= --><A NAME="navbar_top"><!-- --></A><A HREF="#skip-navbar_top" title="Skip navigation links"></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""><TR><TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_top_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY=""> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> PREV CLASS <A HREF="../../../../../javax/servlet/jsp/jstl/sql/SQLExecutionTag.html" title="interface in javax.servlet.jsp.jstl.sql"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../../index.html" target="_top"><B>FRAMES</B></A> <A HREF="Result.html" target="_top"><B>NO FRAMES</B></A> <SCRIPT type="text/javascript"> <!-- if(window==top) { document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>'); } //--></SCRIPT><NOSCRIPT> <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A></NOSCRIPT></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: NESTED | FIELD | CONSTR | <A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: FIELD | CONSTR | <A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_top"></A><!-- ========= END OF TOP NAVBAR ========= --><HR><!-- ======== START OF CLASS DATA ======== --><H2><FONT SIZE="-1">javax.servlet.jsp.jstl.sql</FONT><BR>Interface Result</H2><HR><DL><DT>public interface <B>Result</B></DL><P><p>This interface represents the result of a <sql:query> action. It provides access to the following information in the query result:</p> <ul> <li> The result rows (<tt>getRows()</tt> and <tt>getRowsByIndex()</tt>) <li> The column names (<tt>getColumnNames()</tt>) <li> The number of rows in the result (<tt>getRowCount()</tt>) <li> An indication whether the rows returned represent the complete result or just a subset that is limited by a maximum row setting (<tt>isLimitedByMaxRows()</tt>) </ul> <p>An implementation of the <tt>Result</tt> interface provides a <i>disconnected</i> view into the result of a query.<P><P><DL><DT><B>Author:</B></DT> <DD>Justyna Horwat</DD></DL><HR><P><!-- ======== NESTED CLASS SUMMARY ======== --><!-- =========== FIELD SUMMARY =========== --><!-- ======== CONSTRUCTOR SUMMARY ======== --><!-- ========== METHOD SUMMARY =========== --><A NAME="method_summary"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=2><FONT SIZE="+2"><B>Method Summary</B></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> java.lang.String[]</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../javax/servlet/jsp/jstl/sql/Result.html#getColumnNames()">getColumnNames</A></B>()</CODE><BR> Returns the names of the columns in the result.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> int</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../javax/servlet/jsp/jstl/sql/Result.html#getRowCount()">getRowCount</A></B>()</CODE><BR> Returns the number of rows in the cached ResultSet</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> java.util.SortedMap[]</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../javax/servlet/jsp/jstl/sql/Result.html#getRows()">getRows</A></B>()</CODE><BR> Returns the result of the query as an array of <code>SortedMap</code> objects.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> java.lang.Object[][]</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../javax/servlet/jsp/jstl/sql/Result.html#getRowsByIndex()">getRowsByIndex</A></B>()</CODE><BR> Returns the result of the query as an array of arrays.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../javax/servlet/jsp/jstl/sql/Result.html#isLimitedByMaxRows()">isLimitedByMaxRows</A></B>()</CODE><BR> Returns true if the query was limited by a maximum row setting</TD></TR></TABLE> <P><!-- ============ FIELD DETAIL =========== --><!-- ========= CONSTRUCTOR DETAIL ======== --><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="getRows()"><!-- --></A><H3>getRows</H3><PRE>public java.util.SortedMap[] <B>getRows</B>()</PRE><DL><DD><p>Returns the result of the query as an array of <code>SortedMap</code> objects. Each item of the array represents a specific row in the query result.</p> <p>A row is structured as a <code>SortedMap</code> object where the key is the column name, and where the value is the value associated with the column identified by the key. The column value is an Object of the Java type corresponding to the mapping between column types and Java types defined by the JDBC specification when the <code>ResultSet.getObject()</code> method is used.</p> <p>The <code>SortedMap</code> must use the <code>Comparator</code> <code>java.util.String.CASE_INSENSITIVE_ORDER</code>. This makes it possible to access the key as a case insensitive representation of a column name. This method will therefore work regardless of the case of the column name returned by the database.</p><P><DD><DL><DT><B>Returns:</B><DD>The result rows as an array of <code>SortedMap</code> objects</DL></DD></DL><HR><A NAME="getRowsByIndex()"><!-- --></A><H3>getRowsByIndex</H3><PRE>public java.lang.Object[][] <B>getRowsByIndex</B>()</PRE><DL><DD>Returns the result of the query as an array of arrays. The first array dimension represents a specific row in the query result. The array elements for each row are Object instances of the Java type corresponding to the mapping between column types and Java types defined by the JDBC specification when the <code>ResultSet.getObject()</code> method is used.<P><DD><DL><DT><B>Returns:</B><DD>the result rows as an array of <code>Object[]</code> objects</DL></DD></DL><HR><A NAME="getColumnNames()"><!-- --></A><H3>getColumnNames</H3><PRE>public java.lang.String[] <B>getColumnNames</B>()</PRE><DL><DD>Returns the names of the columns in the result. The order of the names in the array matches the order in which columns are returned in method getRowsByIndex().<P><DD><DL><DT><B>Returns:</B><DD>the column names as an array of <code>String</code> objects</DL></DD></DL><HR><A NAME="getRowCount()"><!-- --></A><H3>getRowCount</H3><PRE>public int <B>getRowCount</B>()</PRE><DL><DD>Returns the number of rows in the cached ResultSet<P><DD><DL><DT><B>Returns:</B><DD>the number of rows in the result</DL></DD></DL><HR><A NAME="isLimitedByMaxRows()"><!-- --></A><H3>isLimitedByMaxRows</H3><PRE>public boolean <B>isLimitedByMaxRows</B>()</PRE><DL><DD>Returns true if the query was limited by a maximum row setting<P><DD><DL><DT><B>Returns:</B><DD><tt>true</tt> if the query was limited by a maximum row setting</DL></DD></DL><!-- ========= END OF CLASS DATA ========= --><HR><!-- ======= START OF BOTTOM NAVBAR ====== --><A NAME="navbar_bottom"><!-- --></A><A HREF="#skip-navbar_bottom" title="Skip navigation links"></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""><TR><TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY=""> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> PREV CLASS <A HREF="../../../../../javax/servlet/jsp/jstl/sql/SQLExecutionTag.html" title="interface in javax.servlet.jsp.jstl.sql"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../../index.html" target="_top"><B>FRAMES</B></A> <A HREF="Result.html" target="_top"><B>NO FRAMES</B></A> <SCRIPT type="text/javascript"> <!-- if(window==top) { document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>'); } //--></SCRIPT><NOSCRIPT> <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A></NOSCRIPT></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: NESTED | FIELD | CONSTR | <A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: FIELD | CONSTR | <A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_bottom"></A><!-- ======== END OF BOTTOM NAVBAR ======= --><HR><font size="-1">Copyright 2003 Sun Microsystems, Inc. All Rights Reserved.</font></BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -