📄 message.html
字号:
<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/sip/message/Message.html#hashCode()">hashCode</A></B>()</CODE>
<BR>
Gets a integer hashcode representation of the Header.</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/sip/message/Message.html#removeContent()">removeContent</A></B>()</CODE>
<BR>
Removes the body content from this Message and all associated entity headers, if a body exists, this method returns sliently if no body exists.</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/sip/message/Message.html#removeFirst(java.lang.String)">removeFirst</A></B>(java.lang.String headerName)</CODE>
<BR>
Removes the first header from a list of headers.</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/sip/message/Message.html#removeHeader(java.lang.String)">removeHeader</A></B>(java.lang.String headerName)</CODE>
<BR>
Removes the Header of the supplied name from the list of headers in this Message.</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/sip/message/Message.html#removeLast(java.lang.String)">removeLast</A></B>(java.lang.String headerName)</CODE>
<BR>
Removes the last header from a list of headers.</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/sip/message/Message.html#setContent(java.lang.Object, javax.sip.header.ContentTypeHeader)">setContent</A></B>(java.lang.Object content,
<A HREF="../../../javax/sip/header/ContentTypeHeader.html" title="interface in javax.sip.header">ContentTypeHeader</A> contentTypeHeader)</CODE>
<BR>
Sets the body of this Message, with the ContentType defined by the new ContentTypeHeader object and the string value of the content.</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/sip/message/Message.html#setContentDisposition(javax.sip.header.ContentDispositionHeader)">setContentDisposition</A></B>(<A HREF="../../../javax/sip/header/ContentDispositionHeader.html" title="interface in javax.sip.header">ContentDispositionHeader</A> contentDisposition)</CODE>
<BR>
Sets the ContentDispositionHeader of this Message.</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/sip/message/Message.html#setContentEncoding(javax.sip.header.ContentEncodingHeader)">setContentEncoding</A></B>(<A HREF="../../../javax/sip/header/ContentEncodingHeader.html" title="interface in javax.sip.header">ContentEncodingHeader</A> contentEncoding)</CODE>
<BR>
Sets the ContentEncodingHeader of this Message.</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/sip/message/Message.html#setContentLanguage(javax.sip.header.ContentLanguageHeader)">setContentLanguage</A></B>(<A HREF="../../../javax/sip/header/ContentLanguageHeader.html" title="interface in javax.sip.header">ContentLanguageHeader</A> contentLanguage)</CODE>
<BR>
Sets the ContentLanguageHeader of this Message.</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/sip/message/Message.html#setContentLength(javax.sip.header.ContentLengthHeader)">setContentLength</A></B>(<A HREF="../../../javax/sip/header/ContentLengthHeader.html" title="interface in javax.sip.header">ContentLengthHeader</A> contentLength)</CODE>
<BR>
Set the ContentLengthHeader of this Message.</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/sip/message/Message.html#setExpires(javax.sip.header.ExpiresHeader)">setExpires</A></B>(<A HREF="../../../javax/sip/header/ExpiresHeader.html" title="interface in javax.sip.header">ExpiresHeader</A> expires)</CODE>
<BR>
Sets the ExpiresHeader of this Message.</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/sip/message/Message.html#setHeader(javax.sip.header.Header)">setHeader</A></B>(<A HREF="../../../javax/sip/header/Header.html" title="interface in javax.sip.header">Header</A> header)</CODE>
<BR>
Sets the new Header to replace existings Header of that type in the message.</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/sip/message/Message.html#setSIPVersion(java.lang.String)">setSIPVersion</A></B>(java.lang.String version)</CODE>
<BR>
Sets the protocol version of SIP being used by this Message.</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/sip/message/Message.html#toString()">toString</A></B>()</CODE>
<BR>
Gets string representation of Message</TD>
</TR>
</TABLE>
<P>
<!-- ============ METHOD DETAIL ========== -->
<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Method Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="addHeader(javax.sip.header.Header)"><!-- --></A><H3>
addHeader</H3>
<PRE>
void <B>addHeader</B>(<A HREF="../../../javax/sip/header/Header.html" title="interface in javax.sip.header">Header</A> header)</PRE>
<DL>
<DD>Adds the new Header to the existing list of Headers contained in this Message. The Header is added to the end of the List and will appear in that order in the SIP Message. <p> Required Headers that are singletons should not be added to the message as they already exist in the message and therefore should be changed using the <A HREF="../../../javax/sip/message/Message.html#setHeader(javax.sip.header.Header)"><CODE>setHeader(Header)</CODE></A> method. <p> This method should be used to support the special case of adding required ViaHeaders to a message. When adding a ViaHeader using this method the implementation will add the ViaHeader to the top of the ViaHeader list, and not the end like all other Headers.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>header</CODE> - the new Header to be added to the existing Headers List.</DL>
</DD>
</DL>
<HR>
<A NAME="addLast(javax.sip.header.Header)"><!-- --></A><H3>
addLast</H3>
<PRE>
void <B>addLast</B>(<A HREF="../../../javax/sip/header/Header.html" title="interface in javax.sip.header">Header</A> header)
throws <A HREF="../../../javax/sip/SipException.html" title="class in javax.sip">SipException</A>,
java.lang.NullPointerException</PRE>
<DL>
<DD>Adds the new Header to the end of existing list of Headers contained in this Message. The Header is added to the end of the List and will appear in that order in the SIP Message. <p> Required Headers that are singletons should not be added to the message as they already exist in the message and therefore should be changed using the <A HREF="../../../javax/sip/message/Message.html#setHeader(javax.sip.header.Header)"><CODE>setHeader(Header)</CODE></A> method. This does the same thing as addHeader in all cases including the Via header. Add a header explicitly to the end of a list of headers.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>header</CODE> - -- the new Header to be added to the end of the existing list of headers
<DT><B>Throws:</B>
<DD><CODE>java.lang.NullPointerException</CODE> - -- if the argument is null.
<DD><CODE><A HREF="../../../javax/sip/SipException.html" title="class in javax.sip">SipException</A></CODE> - -- if the header is a singleton and an instance of the header already exists.<DT><B>Since:</B></DT>
<DD>v1.2</DD>
</DL>
</DD>
</DL>
<HR>
<A NAME="addFirst(javax.sip.header.Header)"><!-- --></A><H3>
addFirst</H3>
<PRE>
void <B>addFirst</B>(<A HREF="../../../javax/sip/header/Header.html" title="interface in javax.sip.header">Header</A> header)
throws <A HREF="../../../javax/sip/SipException.html" title="class in javax.sip">SipException</A>,
java.lang.NullPointerException</PRE>
<DL>
<DD>Adds the new Header to the head of the existing list of Headers contained in this Message. The Header is added to the head of the List and will appear in that order in the SIP Message. <p> Required Headers that are singletons should not be added to the message as they already exist in the message and therefore should be changed using the <A HREF="../../../javax/sip/message/Message.html#setHeader(javax.sip.header.Header)"><CODE>setHeader(Header)</CODE></A> method.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>header</CODE> - the new Header to be added to the existing Headers List.
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../javax/sip/SipException.html" title="class in javax.sip">SipException</A></CODE> - -- if the header to be added is a singleton and an instance of the header already exists.
<DD><CODE>java.lang.NullPointerException</CODE> - -- if the argument is null.<DT><B>Since:</B></DT>
<DD>v1.2</DD>
</DL>
</DD>
</DL>
<HR>
<A NAME="removeFirst(java.lang.String)"><!-- --></A><H3>
removeFirst</H3>
<PRE>
void <B>removeFirst</B>(java.lang.String headerName)
throws java.lang.NullPointerException</PRE>
<DL>
<DD>Removes the first header from a list of headers. If there's only one header of this kind, then it is removed from the message.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>headerName</CODE> - the name of the header to be removed.
<DT><B>Throws:</B>
<DD><CODE>java.lang.NullPointerException</CODE> - -- if the arg is null<DT><B>Since:</B></DT>
<DD>v1.2</DD>
</DL>
</DD>
</DL>
<HR>
<A NAME="removeLast(java.lang.String)"><!-- --></A><H3>
removeLast</H3>
<PRE>
void <B>removeLast</B>(java.lang.String headerName)
throws java.lang.NullPointerException</PRE>
<DL>
<DD>Removes the last header from a list of headers. If there's only one header of this kind, then it is removed from the message.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>headerName</CODE> - the name of the header to be removed.
<DT><B>Throws:</B>
<DD><CODE>java.lang.NullPointerException</CODE><DT><B>Since:</B></DT>
<DD>v1.2</DD>
</DL>
</DD>
</DL>
<HR>
<A NAME="removeHeader(java.lang.String)"><!-- --></A><H3>
removeHeader</H3>
<PRE>
void <B>removeHeader</B>(java.lang.String headerName)</PRE>
<DL>
<DD>Removes the Header of the supplied name from the list of headers in this Message. If multiple headers exist then they are all removed from the header list. If no headers exist then this method returns silently. This method should not be used to remove required Headers, required Headers should be replaced using the <A HREF="../../../javax/sip/message/Message.html#setHeader(javax.sip.header.Header)"><CODE>setHeader(Header)</CODE></A>.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>headerName</CODE> - the new string value name of the Header to be removed.</DL>
</DD>
</DL>
<HR>
<A NAME="getHeaderNames()"><!-- --></A><H3>
getHeaderNames</H3>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -