mimetype.html
来自「wifi上网例子程序」· HTML 代码 · 共 672 行 · 第 1/2 页
HTML
672 行
<!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) on Wed Apr 19 08:11:00 PDT 2006 --><TITLE>MimeType (JavaBeans Activation Framework API documentation)</TITLE><META NAME="keywords" CONTENT="javax.activation.MimeType class"><LINK REL ="stylesheet" TYPE="text/css" HREF="../../stylesheet.css" TITLE="Style"><SCRIPT type="text/javascript">function windowTitle(){ parent.document.title="MimeType (JavaBeans Activation Framework API documentation)";}</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="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/MimeType.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-files/index-1.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="../../javax/activation/MailcapCommandMap.html" title="class in javax.activation"><B>PREV CLASS</B></A> <A HREF="../../javax/activation/MimeTypeParameterList.html" title="class in javax.activation"><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="MimeType.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 | <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><A NAME="skip-navbar_top"></A><!-- ========= END OF TOP NAVBAR ========= --><HR><!-- ======== START OF CLASS DATA ======== --><H2><FONT SIZE="-1">javax.activation</FONT><BR>Class MimeType</H2><PRE>java.lang.Object <IMG SRC="../../resources/inherit.gif" ALT="extended by"><B>javax.activation.MimeType</B></PRE><DL><DT><B>All Implemented Interfaces:</B> <DD>java.io.Externalizable, java.io.Serializable</DD></DL><HR><DL><DT>public class <B>MimeType</B><DT>extends java.lang.Object<DT>implements java.io.Externalizable</DL><P>A Multipurpose Internet Mail Extension (MIME) type, as defined in RFC 2045 and 2046.<P><P><DL><DT><B>See Also:</B><DD><A HREF="../../serialized-form.html#javax.activation.MimeType">Serialized Form</A></DL><HR><P><!-- ======== NESTED CLASS SUMMARY ======== --><!-- =========== FIELD SUMMARY =========== --><!-- ======== CONSTRUCTOR SUMMARY ======== --><A NAME="constructor_summary"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><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="../../javax/activation/MimeType.html#MimeType()">MimeType</A></B>()</CODE><BR> Default constructor.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><B><A HREF="../../javax/activation/MimeType.html#MimeType(java.lang.String)">MimeType</A></B>(java.lang.String rawdata)</CODE><BR> Constructor that builds a MimeType from a String.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><B><A HREF="../../javax/activation/MimeType.html#MimeType(java.lang.String, java.lang.String)">MimeType</A></B>(java.lang.String primary, java.lang.String sub)</CODE><BR> Constructor that builds a MimeType with the given primary and sub type but has an empty parameter list.</TD></TR></TABLE> <!-- ========== 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/activation/MimeType.html#getBaseType()">getBaseType</A></B>()</CODE><BR> Return a String representation of this object without the parameter list.</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/activation/MimeType.html#getParameter(java.lang.String)">getParameter</A></B>(java.lang.String name)</CODE><BR> Retrieve the value associated with the given name, or null if there is no current association.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../javax/activation/MimeTypeParameterList.html" title="class in javax.activation">MimeTypeParameterList</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../javax/activation/MimeType.html#getParameters()">getParameters</A></B>()</CODE><BR> Retrieve this object's parameter list.</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/activation/MimeType.html#getPrimaryType()">getPrimaryType</A></B>()</CODE><BR> Retrieve the primary type of this object.</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/activation/MimeType.html#getSubType()">getSubType</A></B>()</CODE><BR> Retrieve the subtype of this object.</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/activation/MimeType.html#match(javax.activation.MimeType)">match</A></B>(<A HREF="../../javax/activation/MimeType.html" title="class in javax.activation">MimeType</A> type)</CODE><BR> Determine if the primary and sub type of this object is the same as what is in the given type.</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/activation/MimeType.html#match(java.lang.String)">match</A></B>(java.lang.String rawdata)</CODE><BR> Determine if the primary and sub type of this object is the same as the content type described in rawdata.</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="../../javax/activation/MimeType.html#readExternal(java.io.ObjectInput)">readExternal</A></B>(java.io.ObjectInput in)</CODE><BR> The object implements the readExternal method to restore its contents by calling the methods of DataInput for primitive types and readObject for objects, strings and arrays.</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="../../javax/activation/MimeType.html#removeParameter(java.lang.String)">removeParameter</A></B>(java.lang.String name)</CODE><BR> Remove any value associated with the given name.</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="../../javax/activation/MimeType.html#setParameter(java.lang.String, java.lang.String)">setParameter</A></B>(java.lang.String name, java.lang.String value)</CODE><BR> Set the value to be associated with the given name, replacing any previous association.</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="../../javax/activation/MimeType.html#setPrimaryType(java.lang.String)">setPrimaryType</A></B>(java.lang.String primary)</CODE><BR> Set the primary type for this object to the given String.</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="../../javax/activation/MimeType.html#setSubType(java.lang.String)">setSubType</A></B>(java.lang.String sub)</CODE><BR> Set the subtype for this object to the given String.</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/activation/MimeType.html#toString()">toString</A></B>()</CODE><BR> Return the String representation of this object.</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="../../javax/activation/MimeType.html#writeExternal(java.io.ObjectOutput)">writeExternal</A></B>(java.io.ObjectOutput out)</CODE><BR> The object implements the writeExternal method to save its contents by calling the methods of DataOutput for its primitive values or calling the writeObject method of ObjectOutput for objects, strings and arrays.</TD></TR></TABLE> <A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from class java.lang.Object</B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait</CODE></TD></TR></TABLE> <P><!-- ============ FIELD DETAIL =========== --><!-- ========= CONSTRUCTOR DETAIL ======== --><A NAME="constructor_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Constructor Detail</B></FONT></TD></TR></TABLE><A NAME="MimeType()"><!-- --></A><H3>MimeType</H3><PRE>public <B>MimeType</B>()</PRE><DL><DD>Default constructor.<P></DL><HR><A NAME="MimeType(java.lang.String)"><!-- --></A><H3>MimeType</H3><PRE>public <B>MimeType</B>(java.lang.String rawdata) throws <A HREF="../../javax/activation/MimeTypeParseException.html" title="class in javax.activation">MimeTypeParseException</A></PRE><DL><DD>Constructor that builds a MimeType from a String.<P><DT><B>Parameters:</B><DD><CODE>rawdata</CODE> - the MIME type string</DL><HR><A NAME="MimeType(java.lang.String, java.lang.String)"><!-- --></A><H3>MimeType</H3><PRE>public <B>MimeType</B>(java.lang.String primary, java.lang.String sub) throws <A HREF="../../javax/activation/MimeTypeParseException.html" title="class in javax.activation">MimeTypeParseException</A></PRE><DL><DD>Constructor that builds a MimeType with the given primary and sub type but has an empty parameter list.<P><DT><B>Parameters:</B><DD><CODE>primary</CODE> - the primary MIME type<DD><CODE>sub</CODE> - the MIME sub-type<DT><B>Throws:</B><DD><CODE><A HREF="../../javax/activation/MimeTypeParseException.html" title="class in javax.activation">MimeTypeParseException</A></CODE> - if the primary type or subtype is not a valid token</DL>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?