📄 message.html
字号:
</DL>
<HR>
<A NAME="getRawContent()"><!-- --></A><H3>
getRawContent</H3>
<PRE>
byte[] <B>getRawContent</B>()</PRE>
<DL>
<DD>Gets the body content of the Message as a byte array.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the body content of the Message as a byte array, this method returns null if a body does not exist.</DL>
</DD>
</DL>
<HR>
<A NAME="getContent()"><!-- --></A><H3>
getContent</H3>
<PRE>
java.lang.Object <B>getContent</B>()</PRE>
<DL>
<DD>Gets the body content of the Message as an Object.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the body content of the Message as an Object, this method returns null if a body does not exist.</DL>
</DD>
</DL>
<HR>
<A NAME="removeContent()"><!-- --></A><H3>
removeContent</H3>
<PRE>
void <B>removeContent</B>()</PRE>
<DL>
<DD>Removes the body content from this Message and all associated entity headers, if a body exists, this method returns sliently if no body exists.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="setExpires(javax.sip.header.ExpiresHeader)"><!-- --></A><H3>
setExpires</H3>
<PRE>
void <B>setExpires</B>(<A HREF="../../../javax/sip/header/ExpiresHeader.html" title="interface in javax.sip.header">ExpiresHeader</A> expires)</PRE>
<DL>
<DD>Sets the ExpiresHeader of this Message. This overrides the ExpiresHeader set using the setHeaders method. If no ExpiresHeader exists in this message this ExpiresHeader is added to the end of the Header List.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>expires</CODE> - the new ExpiresHeader object containing the expires values of this Message.</DL>
</DD>
</DL>
<HR>
<A NAME="getExpires()"><!-- --></A><H3>
getExpires</H3>
<PRE>
<A HREF="../../../javax/sip/header/ExpiresHeader.html" title="interface in javax.sip.header">ExpiresHeader</A> <B>getExpires</B>()</PRE>
<DL>
<DD>Gets the ExpiresHeader of this Message. This is the same as <code>this.getHeader(Expires);</code>
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the ExpiresHeader of the message body.</DL>
</DD>
</DL>
<HR>
<A NAME="setSIPVersion(java.lang.String)"><!-- --></A><H3>
setSIPVersion</H3>
<PRE>
void <B>setSIPVersion</B>(java.lang.String version)
throws java.text.ParseException</PRE>
<DL>
<DD>Sets the protocol version of SIP being used by this Message.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>version</CODE> - the new String object containing the version of the SIP Protocol of this Message.
<DT><B>Throws:</B>
<DD><CODE>java.text.ParseException</CODE> - which signals that an error has been reached unexpectedly while parsing the version argument.</DL>
</DD>
</DL>
<HR>
<A NAME="getSIPVersion()"><!-- --></A><H3>
getSIPVersion</H3>
<PRE>
java.lang.String <B>getSIPVersion</B>()</PRE>
<DL>
<DD>Gets the protocol version of SIP being used by this Message.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the protocol version of the SIP protocol of this message.</DL>
</DD>
</DL>
<HR>
<A NAME="clone()"><!-- --></A><H3>
clone</H3>
<PRE>
java.lang.Object <B>clone</B>()</PRE>
<DL>
<DD>Creates and returns a deep copy of the Message. This methods must ensure a deep copy of the message, so that it can be modified without effecting the original message. This provides useful functionality for proxying Requests and Responses, for example: <ul> <li>Recieve a message. <li>Create a deep clone of the message. <li>Modify necessary headers. <li>Proxy the message using the send methods on the SipProvider. </ul> The message contents are cloned as follows: <ul> <li>If the content is of type byte[] a new byte[] array is allocated and the original contents are copied over to the cloned Message. <li>If the content is of type String then a new String equal to the old String is allocated and assigned to the cloned Message. <li>If the content is of type Object and it has a public clone method then it is invoked and the resultant Object is used in the new cloned Message. </ul>
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>a deep copy of Message</DL>
</DD>
</DL>
<HR>
<A NAME="equals(java.lang.Object)"><!-- --></A><H3>
equals</H3>
<PRE>
boolean <B>equals</B>(java.lang.Object object)</PRE>
<DL>
<DD>Compare this SIP Message for equality with another. Implementations need only compare Request/Response line, From, To, CallID, MaxForwards, CSeq and Via headers for message equality.
<P>
<DD><DL>
<DT><B>Overrides:</B><DD><CODE>equals</CODE> in class <CODE>java.lang.Object</CODE></DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>object</CODE> - the object to compare this Message with.
<DT><B>Returns:</B><DD><code>true</code> if <code>obj</code> is an instance of this class representing the same SIP Message as this (on the basis of comparing the headers above), <code>false</code> otherwise.</DL>
</DD>
</DL>
<HR>
<A NAME="hashCode()"><!-- --></A><H3>
hashCode</H3>
<PRE>
int <B>hashCode</B>()</PRE>
<DL>
<DD>Gets a integer hashcode representation of the Header. This method overrides the hashcode method in java.lang.Object. Only the Request/Response line and the required headers should be used to generate the unique hashcode of a message.
<P>
<DD><DL>
<DT><B>Overrides:</B><DD><CODE>hashCode</CODE> in class <CODE>java.lang.Object</CODE></DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>integer representation of the Message hashcode<DT><B>Since:</B></DT>
<DD>v1.2</DD>
</DL>
</DD>
</DL>
<HR>
<A NAME="toString()"><!-- --></A><H3>
toString</H3>
<PRE>
java.lang.String <B>toString</B>()</PRE>
<DL>
<DD>Gets string representation of Message
<P>
<DD><DL>
<DT><B>Overrides:</B><DD><CODE>toString</CODE> in class <CODE>java.lang.Object</CODE></DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>string representation of Message</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=2 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>
<b>JSIP API v1.2<br><font size=-1>November 2006</font></b></EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
PREV CLASS
<A HREF="../../../javax/sip/message/MessageFactory.html" title="interface in javax.sip.message"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../index.html?javax/sip/message/Message.html" target="_top"><B>FRAMES</B></A>
<A HREF="Message.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>
<center>If you have any comments, please mail them to <a href=mailto:JAIN-SIP-INTEREST@java.sun.com>JAIN-SIP-INTEREST@java.sun.com</a> after subscribing at <a href=http://archives.java.sun.com>http://archives.java.sun.com</a><br><a href=../../../copyright.html>Copyright</a> - 2006 BEA Systems and Sun Microsystems</center>
</BODY>
</HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -