servletutilities.html
来自「JFreeChart的帮助文档」· HTML 代码 · 共 535 行 · 第 1/2 页
HTML
535 行
<DL></DL><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="saveChartAsPNG(org.jfree.chart.JFreeChart, int, int, javax.servlet.http.HttpSession)"><!-- --></A><H3>saveChartAsPNG</H3><PRE>public static java.lang.String <B>saveChartAsPNG</B>(<A HREF="../../../../org/jfree/chart/JFreeChart.html">JFreeChart</A> chart, int width, int height, javax.servlet.http.HttpSession session) throws java.io.IOException</PRE><DL><DD>Saves the chart as a PNG format file in the temporary directory.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>chart</CODE> - the JFreeChart to be saved.<DD><CODE>width</CODE> - the width of the chart.<DD><CODE>height</CODE> - the height of the chart.<DD><CODE>session</CODE> - the HttpSession of the client.<DT><B>Returns:</B><DD>the filename of the chart saved in the temporary directory.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - if there is a problem saving the file.</DL></DD></DL><HR><A NAME="saveChartAsPNG(org.jfree.chart.JFreeChart, int, int, org.jfree.chart.ChartRenderingInfo, javax.servlet.http.HttpSession)"><!-- --></A><H3>saveChartAsPNG</H3><PRE>public static java.lang.String <B>saveChartAsPNG</B>(<A HREF="../../../../org/jfree/chart/JFreeChart.html">JFreeChart</A> chart, int width, int height, <A HREF="../../../../org/jfree/chart/ChartRenderingInfo.html">ChartRenderingInfo</A> info, javax.servlet.http.HttpSession session) throws java.io.IOException</PRE><DL><DD>Saves the chart as a PNG format file in the temporary directory and populates the ChartRenderingInfo object which can be used to generate an HTML image map.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>chart</CODE> - the JFreeChart to be saved.<DD><CODE>width</CODE> - the width of the chart.<DD><CODE>height</CODE> - the height of the chart.<DD><CODE>info</CODE> - the ChartRenderingInfo object to be populated.<DD><CODE>session</CODE> - the HttpSession of the client.<DT><B>Returns:</B><DD>the filename of the chart saved in the temporary directory.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - if there is a problem saving the file.</DL></DD></DL><HR><A NAME="saveChartAsJPEG(org.jfree.chart.JFreeChart, int, int, javax.servlet.http.HttpSession)"><!-- --></A><H3>saveChartAsJPEG</H3><PRE>public static java.lang.String <B>saveChartAsJPEG</B>(<A HREF="../../../../org/jfree/chart/JFreeChart.html">JFreeChart</A> chart, int width, int height, javax.servlet.http.HttpSession session) throws java.io.IOException</PRE><DL><DD>Saves the chart as a JPEG format file in the temporary directory.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>chart</CODE> - the JFreeChart to be saved.<DD><CODE>width</CODE> - the width of the chart.<DD><CODE>height</CODE> - the height of the chart.<DD><CODE>session</CODE> - the HttpSession of the client.<DT><B>Returns:</B><DD>the filename of the chart saved in the temporary directory.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - if there is a problem saving the file.</DL></DD></DL><HR><A NAME="saveChartAsJPEG(org.jfree.chart.JFreeChart, int, int, org.jfree.chart.ChartRenderingInfo, javax.servlet.http.HttpSession)"><!-- --></A><H3>saveChartAsJPEG</H3><PRE>public static java.lang.String <B>saveChartAsJPEG</B>(<A HREF="../../../../org/jfree/chart/JFreeChart.html">JFreeChart</A> chart, int width, int height, <A HREF="../../../../org/jfree/chart/ChartRenderingInfo.html">ChartRenderingInfo</A> info, javax.servlet.http.HttpSession session) throws java.io.IOException</PRE><DL><DD>Saves the chart as a JPEG format file in the temporary directory and populates the ChartRenderingInfo object which can be used to generate an HTML image map.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>chart</CODE> - the JFreeChart to be saved<DD><CODE>width</CODE> - the width of the chart<DD><CODE>height</CODE> - the height of the chart<DD><CODE>info</CODE> - the ChartRenderingInfo object to be populated<DD><CODE>session</CODE> - the HttpSession of the client<DT><B>Returns:</B><DD>the filename of the chart saved in the temporary directory<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - if there is a problem saving the file.</DL></DD></DL><HR><A NAME="createTempDir()"><!-- --></A><H3>createTempDir</H3><PRE>protected static void <B>createTempDir</B>()</PRE><DL><DD>Creates the temporary directory if it does not exist. Throws a RuntimeException if the temporary directory is null. Uses the system property java.io.tmpdir as the temporary directory. Sounds like a strange thing to do but my temporary directory was not created on my default Tomcat 4.0.3 installation. Could save some questions on the forum if it is created when not present.<P><DD><DL></DL></DD></DL><HR><A NAME="registerChartForDeletion(java.io.File, javax.servlet.http.HttpSession)"><!-- --></A><H3>registerChartForDeletion</H3><PRE>protected static void <B>registerChartForDeletion</B>(java.io.File tempFile, javax.servlet.http.HttpSession session)</PRE><DL><DD>Adds a ChartDeleter object to the session object with the name JFreeChart_Deleter if there is not already one bound to the session and adds the filename to the list of charts to be deleted.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>tempFile</CODE> - the file to be deleted.<DD><CODE>session</CODE> - the HTTP session of the client.</DL></DD></DL><HR><A NAME="sendTempFile(java.lang.String, javax.servlet.http.HttpServletResponse)"><!-- --></A><H3>sendTempFile</H3><PRE>public static void <B>sendTempFile</B>(java.lang.String filename, javax.servlet.http.HttpServletResponse response) throws java.io.IOException, java.io.FileNotFoundException</PRE><DL><DD>Binary streams the specified file in the temporary directory to the HTTP response in 1KB chunks<P><DD><DL><DT><B>Parameters:</B><DD><CODE>filename</CODE> - The name of the file in the temporary directory.<DD><CODE>response</CODE> - The HTTP response object.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - if there is an I/O problem.<DD><CODE>java.io.FileNotFoundException</CODE> - if the file is not found.</DL></DD></DL><HR><A NAME="sendTempFile(java.io.File, javax.servlet.http.HttpServletResponse)"><!-- --></A><H3>sendTempFile</H3><PRE>public static void <B>sendTempFile</B>(java.io.File file, javax.servlet.http.HttpServletResponse response) throws java.io.IOException, java.io.FileNotFoundException</PRE><DL><DD>Binary streams the specified file to the HTTP response in 1KB chunks<P><DD><DL><DT><B>Parameters:</B><DD><CODE>file</CODE> - The file to be streamed.<DD><CODE>response</CODE> - The HTTP response object.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - if there is an I/O problem.<DD><CODE>java.io.FileNotFoundException</CODE> - if the file is not found.</DL></DD></DL><HR><A NAME="sendTempFile(java.io.File, javax.servlet.http.HttpServletResponse, java.lang.String)"><!-- --></A><H3>sendTempFile</H3><PRE>public static void <B>sendTempFile</B>(java.io.File file, javax.servlet.http.HttpServletResponse response, java.lang.String mimeType) throws java.io.IOException, java.io.FileNotFoundException</PRE><DL><DD>Binary streams the specified file to the HTTP response in 1KB chunks<P><DD><DL><DT><B>Parameters:</B><DD><CODE>file</CODE> - The file to be streamed.<DD><CODE>response</CODE> - The HTTP response object.<DD><CODE>mimeType</CODE> - The mime type of the file, null allowed.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - if there is an I/O problem.<DD><CODE>java.io.FileNotFoundException</CODE> - if the file is not found.</DL></DD></DL><HR><A NAME="searchReplace(java.lang.String, java.lang.String, java.lang.String)"><!-- --></A><H3>searchReplace</H3><PRE>public static java.lang.String <B>searchReplace</B>(java.lang.String inputString, java.lang.String searchString, java.lang.String replaceString)</PRE><DL><DD>Perform a search/replace operation on a String There are String methods to do this since (JDK 1.4)<P><DD><DL><DT><B>Parameters:</B><DD><CODE>inputString</CODE> - the String to have the search/replace operation.<DD><CODE>searchString</CODE> - the search String.<DD><CODE>replaceString</CODE> - the replace String.<DT><B>Returns:</B><DD>the String with the replacements made.</DL></DD></DL><!-- ========= END OF CLASS DATA ========= --><HR><!-- ========== START OF NAVBAR ========== --><A NAME="navbar_bottom"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0"><TR><TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3"> <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"> <A HREF="../../../../org/jfree/chart/servlet/DisplayChart.html"><B>PREV CLASS</B></A> NEXT CLASS</FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../index.html" TARGET="_top"><B>FRAMES</B></A> <A HREF="ServletUtilities.html" TARGET="_top"><B>NO FRAMES</B></A> <SCRIPT> <!-- if(window==top) { document.writeln('<A HREF="../../../../allclasses-noframe.html" TARGET=""><B>All Classes</B></A>'); } //--></SCRIPT><NOSCRIPT><A HREF="../../../../allclasses-noframe.html" TARGET=""><B>All Classes</B></A></NOSCRIPT></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY: NESTED | FIELD | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: FIELD | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><!-- =========== END OF NAVBAR =========== --><HR></BODY></HTML>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?