📄 commonsmultipartrequesthandler.commonsformfile.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN""http://www.w3.org/TR/REC-html40/frameset.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc on Thu Mar 09 15:31:25 GMT 2006 -->
<TITLE>
Apache Struts API Documentation: Class CommonsMultipartRequestHandler.CommonsFormFile
</TITLE>
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
</HEAD>
<BODY BGCOLOR="white">
<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_top"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_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="class-use/CommonsMultipartRequestHandler.CommonsFormFile.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </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/apache/struts/upload/CommonsMultipartRequestHandler.html"><B>PREV CLASS</B></A>
<A HREF="../../../../org/apache/struts/upload/DiskFile.html"><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="CommonsMultipartRequestHandler.CommonsFormFile.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: INNER | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->
<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
org.apache.struts.upload</FONT>
<BR>
Class CommonsMultipartRequestHandler.CommonsFormFile</H2>
<PRE>
java.lang.Object
|
+--<B>org.apache.struts.upload.CommonsMultipartRequestHandler.CommonsFormFile</B>
</PRE>
<DL>
<DT><B>All Implemented Interfaces:</B> <DD><A HREF="../../../../org/apache/struts/upload/FormFile.html">FormFile</A>, java.io.Serializable</DD>
</DL>
<DL>
<DT><B>Enclosing class: </B><DD><A HREF="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.html">CommonsMultipartRequestHandler</A></DD>
</DL>
<HR>
<DL>
<DT>static class <B>CommonsMultipartRequestHandler.CommonsFormFile</B><DT>extends java.lang.Object<DT>implements <A HREF="../../../../org/apache/struts/upload/FormFile.html">FormFile</A>, java.io.Serializable</DL>
<P>
This class implements the Struts <code>FormFile</code> interface by wrapping the Commons FileUpload <code>FileItem</code> interface. This implementation is <i>read-only</i>; any attempt to modify an instance of this class will result in an <code>UnsupportedOperationException</code>.
<P>
<DL>
<DT><B>See Also: </B><DD><A HREF="../../../../serialized-form.html#org.apache.struts.upload.CommonsMultipartRequestHandler.CommonsFormFile">Serialized Form</A></DL>
<HR>
<P>
<!-- ======== INNER CLASS SUMMARY ======== -->
<!-- =========== FIELD SUMMARY =========== -->
<A NAME="field_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Field Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>(package private) org.apache.commons.fileupload.FileItem</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#fileItem">fileItem</A></B></CODE>
<BR>
The <code>FileItem</code> instance wrapped by this object.</TD>
</TR>
</TABLE>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<A NAME="constructor_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#CommonsMultipartRequestHandler.CommonsFormFile(org.apache.commons.fileupload.FileItem)">CommonsMultipartRequestHandler.CommonsFormFile</A></B>(org.apache.commons.fileupload.FileItem fileItem)</CODE>
<BR>
Constructs an instance of this class which wraps the supplied file item.</TD>
</TR>
</TABLE>
<!-- ========== METHOD SUMMARY =========== -->
<A NAME="method_summary"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<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> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#destroy()">destroy</A></B>()</CODE>
<BR>
Destroy all content for this form file.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#getBaseFileName(java.lang.String)">getBaseFileName</A></B>(java.lang.String filePath)</CODE>
<BR>
Returns the base file name from the supplied file path.</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="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#getContentType()">getContentType</A></B>()</CODE>
<BR>
Returns the content type for this file.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> byte[]</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#getFileData()">getFileData</A></B>()</CODE>
<BR>
Returns the data for this file as a byte array.</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="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#getFileName()">getFileName</A></B>()</CODE>
<BR>
Returns the (client-side) file name for this file.</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="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#getFileSize()">getFileSize</A></B>()</CODE>
<BR>
Returns the size, in bytes, of this file.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> java.io.InputStream</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#getInputStream()">getInputStream</A></B>()</CODE>
<BR>
Get an InputStream that represents this file.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#setContentType(java.lang.String)">setContentType</A></B>(java.lang.String contentType)</CODE>
<BR>
Sets the content type for this file.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#setFileName(java.lang.String)">setFileName</A></B>(java.lang.String fileName)</CODE>
<BR>
Sets the (client-side) file name for this file.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#setFileSize(int)">setFileSize</A></B>(int filesize)</CODE>
<BR>
Sets the size, in bytes, for this file.</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="../../../../org/apache/struts/upload/CommonsMultipartRequestHandler.CommonsFormFile.html#toString()">toString</A></B>()</CODE>
<BR>
Returns the (client-side) file name for this file.</TD>
</TR>
</TABLE>
<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class java.lang.Object</B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><clinit>, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait</CODE></TD>
</TR>
</TABLE>
<P>
<!-- ============ FIELD DETAIL =========== -->
<A NAME="field_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Field Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="fileItem"><!-- --></A><H3>
fileItem</H3>
<PRE>
org.apache.commons.fileupload.FileItem <B>fileItem</B></PRE>
<DL>
<DD>The <code>FileItem</code> instance wrapped by this object.</DL>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -