⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 message.html

📁 jsip开发文档,对于开发SIP软电话和presence服务很有用
💻 HTML
📖 第 1 页 / 共 4 页
字号:
<PRE>
java.util.ListIterator <B>getHeaderNames</B>()</PRE>
<DL>
<DD>Gets a ListIterator over the set of all all the header names in this Message.  Note that the order of the Header Names in the ListIterator is same as the  order in which they appear in the SIP Message.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>

<DT><B>Returns:</B><DD>the ListIterator over the set of all the Header Names in the Message.</DL>
</DD>
</DL>
<HR>

<A NAME="getHeaders(java.lang.String)"><!-- --></A><H3>
getHeaders</H3>
<PRE>
java.util.ListIterator <B>getHeaders</B>(java.lang.String&nbsp;headerName)</PRE>
<DL>
<DD>Gets a ListIterator over all the Headers of the newly specified name   in this Message. Note that order of the Headers in ListIterator is the  same as the order in which they appear in the SIP Message.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>headerName</CODE> - the new string name of Header types requested.
<DT><B>Returns:</B><DD>the ListIterator over all the Headers of the specified name in  the Message, this method returns an empty ListIterator if no Headers  exist of this header type.</DL>
</DD>
</DL>
<HR>

<A NAME="getHeader(java.lang.String)"><!-- --></A><H3>
getHeader</H3>
<PRE>
<A HREF="../../../javax/sip/header/Header.html" title="interface in javax.sip.header">Header</A> <B>getHeader</B>(java.lang.String&nbsp;headerName)</PRE>
<DL>
<DD>Gets the Header of the specified name in this Message. If multiple  Headers of this header name exist in the message, the first header in the message is returned.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>headerName</CODE> - the new string name of Header type requested.
<DT><B>Returns:</B><DD>the Header of the specified name in the Message, this method  returns null if the Header does not exist.</DL>
</DD>
</DL>
<HR>

<A NAME="getUnrecognizedHeaders()"><!-- --></A><H3>
getUnrecognizedHeaders</H3>
<PRE>
java.util.ListIterator <B>getUnrecognizedHeaders</B>()</PRE>
<DL>
<DD>Returns a ListIterator over all the UnrecognizedHeaders in this Message. Note the order of the UnrecognizedHeaders in the ListIterator is the same as order in which they appeared in the SIP Message. UnrecognizedHeaders are headers that the underlying implementation does not recognize.  If the message is missing a required header (From, To, Call-ID, CSeq, Via) the entire message willl be dropped by the underlying implementation and the header will not be included in the list. Headers that are part of the supported set of headers but are not properly formatted will  be included in this list. Note that Headers that are not part of the supported set of headers are retrieved as Extension Headers. These must have a name:value format else they will be rejected by the underling implementation and included in this list. A Proxy should not delete UnrecognizedHeaders and should add these Headers to the end of the header list of the Message that is being forwarded. A User Agent may display these unrecognized headers to the user.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>

<DT><B>Returns:</B><DD>the ListIterator over all the UnrecognizedHeaders in the Message  represented as Strings, this method returns an empty ListIterator if no  UnrecognizedHeaders exist.</DL>
</DD>
</DL>
<HR>

<A NAME="setHeader(javax.sip.header.Header)"><!-- --></A><H3>
setHeader</H3>
<PRE>
void <B>setHeader</B>(<A HREF="../../../javax/sip/header/Header.html" title="interface in javax.sip.header">Header</A>&nbsp;header)</PRE>
<DL>
<DD>Sets the new Header to replace existings Header of that type in the message. If the SIP message contains more than one Header of  the new Header type it should replace the first occurance of this  Header and removes all other Headers of this type. If no Header of this  type exists this header is added to the end of the SIP Message. This method should be used to change required Headers and overwrite  optional Headers.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>header</CODE> - the new Header to replace any existing Headers of that  type.</DL>
</DD>
</DL>
<HR>

<A NAME="setContentLength(javax.sip.header.ContentLengthHeader)"><!-- --></A><H3>
setContentLength</H3>
<PRE>
void <B>setContentLength</B>(<A HREF="../../../javax/sip/header/ContentLengthHeader.html" title="interface in javax.sip.header">ContentLengthHeader</A>&nbsp;contentLength)</PRE>
<DL>
<DD>Set the ContentLengthHeader of this Message.  The actual content length for the outgoing message will be computed from  the content assigned. If the content is speficied as an object it will  be converted to a String before the message is sent out and the content  length computed from the length of the string. If the message content is  specified in bytes, the length of the byte array specified will be used  to determine the content length header, that is in both cases, the length  of the content overrides any value specified in the content-length  header.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>contentLength</CODE> - the new ContentLengthHeader object containing the  content length value of this Message.</DL>
</DD>
</DL>
<HR>

<A NAME="getContentLength()"><!-- --></A><H3>
getContentLength</H3>
<PRE>
<A HREF="../../../javax/sip/header/ContentLengthHeader.html" title="interface in javax.sip.header">ContentLengthHeader</A> <B>getContentLength</B>()</PRE>
<DL>
<DD>Gets the ContentLengthHeader of the body content of this Message. This is  the same as <code>this.getHeader(Content-Length);</code>
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>

<DT><B>Returns:</B><DD>the ContentLengthHeader of the message body.</DL>
</DD>
</DL>
<HR>

<A NAME="setContentLanguage(javax.sip.header.ContentLanguageHeader)"><!-- --></A><H3>
setContentLanguage</H3>
<PRE>
void <B>setContentLanguage</B>(<A HREF="../../../javax/sip/header/ContentLanguageHeader.html" title="interface in javax.sip.header">ContentLanguageHeader</A>&nbsp;contentLanguage)</PRE>
<DL>
<DD>Sets the ContentLanguageHeader of this Message. This overrides the  ContentLanguageHeader set using the setHeaders method. If no  ContentLanguageHeader exists in this message this ContentLanguageHeader  is added to the end of the Header List.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>contentLanguage</CODE> - the new ContentLanguageHeader object containing the  content language value of this Message.</DL>
</DD>
</DL>
<HR>

<A NAME="getContentLanguage()"><!-- --></A><H3>
getContentLanguage</H3>
<PRE>
<A HREF="../../../javax/sip/header/ContentLanguageHeader.html" title="interface in javax.sip.header">ContentLanguageHeader</A> <B>getContentLanguage</B>()</PRE>
<DL>
<DD>Gets the ContentLanguageHeader of this Message. This is the same as <code>this.getHeader(Content-Langauge);</code>
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>

<DT><B>Returns:</B><DD>the ContentLanguageHeader of the message body.</DL>
</DD>
</DL>
<HR>

<A NAME="setContentEncoding(javax.sip.header.ContentEncodingHeader)"><!-- --></A><H3>
setContentEncoding</H3>
<PRE>
void <B>setContentEncoding</B>(<A HREF="../../../javax/sip/header/ContentEncodingHeader.html" title="interface in javax.sip.header">ContentEncodingHeader</A>&nbsp;contentEncoding)</PRE>
<DL>
<DD>Sets the ContentEncodingHeader of this Message. This overrides the  ContentEncodingHeader set using the setHeaders method. If no  ContentEncodingHeader exists in this message this ContentEncodingHeader  is added to the end of the Header List.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>contentEncoding</CODE> - the new ContentEncodingHeader object containing the  content encoding values of this Message.</DL>
</DD>
</DL>
<HR>

<A NAME="getContentEncoding()"><!-- --></A><H3>
getContentEncoding</H3>
<PRE>
<A HREF="../../../javax/sip/header/ContentEncodingHeader.html" title="interface in javax.sip.header">ContentEncodingHeader</A> <B>getContentEncoding</B>()</PRE>
<DL>
<DD>Gets the ContentEncodingHeader of this Message. This is the same as <code>this.getHeader(Content-Encoding);</code>
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>

<DT><B>Returns:</B><DD>the ContentEncodingHeader of the message body.</DL>
</DD>
</DL>
<HR>

<A NAME="setContentDisposition(javax.sip.header.ContentDispositionHeader)"><!-- --></A><H3>
setContentDisposition</H3>
<PRE>
void <B>setContentDisposition</B>(<A HREF="../../../javax/sip/header/ContentDispositionHeader.html" title="interface in javax.sip.header">ContentDispositionHeader</A>&nbsp;contentDisposition)</PRE>
<DL>
<DD>Sets the ContentDispositionHeader of this Message. This overrides the  ContentDispositionHeader set using the setHeaders method. If no  ContentDispositionHeader exists in this message this ContentDispositionHeader  is added to the end of the Header List.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>contentDisposition</CODE> - the new ContentDispositionHeader object  containing the content disposition value of this Message.</DL>
</DD>
</DL>
<HR>

<A NAME="getContentDisposition()"><!-- --></A><H3>
getContentDisposition</H3>
<PRE>
<A HREF="../../../javax/sip/header/ContentDispositionHeader.html" title="interface in javax.sip.header">ContentDispositionHeader</A> <B>getContentDisposition</B>()</PRE>
<DL>
<DD>Gets the ContentDispositionHeader of this Message. This is the same as <code>this.getHeader(Content-Disposition);</code>
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>

<DT><B>Returns:</B><DD>the ContentDispositionHeader of the message body.</DL>
</DD>
</DL>
<HR>

<A NAME="setContent(java.lang.Object, javax.sip.header.ContentTypeHeader)"><!-- --></A><H3>
setContent</H3>
<PRE>
void <B>setContent</B>(java.lang.Object&nbsp;content,
                <A HREF="../../../javax/sip/header/ContentTypeHeader.html" title="interface in javax.sip.header">ContentTypeHeader</A>&nbsp;contentTypeHeader)
                throws java.text.ParseException</PRE>
<DL>
<DD>Sets the body of this Message, with the ContentType defined by the new ContentTypeHeader object and the string value of the content.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>content</CODE> - the new Object value of the content of the Message.<DD><CODE>contentTypeHeader</CODE> - the new ContentTypeHeader object that defines the content type value.
<DT><B>Throws:</B>
<DD><CODE>java.text.ParseException</CODE> - which signals that an error has been reached unexpectedly while parsing the body.</DL>
</DD>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -