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

📄 clienttransaction.html

📁 jsip开发文档,对于开发SIP软电话和presence服务很有用
💻 HTML
📖 第 1 页 / 共 2 页
字号:
<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="sendRequest()"><!-- --></A><H3>
sendRequest</H3>
<PRE>
void <B>sendRequest</B>()
                 throws <A HREF="../../javax/sip/SipException.html" title="class in javax.sip">SipException</A></PRE>
<DL>
<DD>Sends the Request which created this ClientTransaction. When an  application wishes to send a Request message, it creates a Request from  the <A HREF="../../javax/sip/message/MessageFactory.html" title="interface in javax.sip.message"><CODE>MessageFactory</CODE></A> and then creates a new ClientTransaction from  <A HREF="../../javax/sip/SipProvider.html#getNewClientTransaction(javax.sip.message.Request)"><CODE>SipProvider.getNewClientTransaction(Request)</CODE></A>. Calling this method on the ClientTransaction sends the Request onto the network. The Request  message gets sent via the ListeningPoint information of the SipProvider  that is associated to this ClientTransaction.  <p> This method assumes that the Request is sent out of Dialog. It uses  the Router to determine the next hop. If the Router returns a empty  iterator, and a Dialog is associated with the outgoing request of the  Transaction then the Dialog route set is used to send the outgoing  request. <p> This method implies that the application is functioning as either a UAC  or a stateful proxy, hence the underlying implementation acts statefully.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>

<DT><B>Throws:</B>
<DD><CODE><A HREF="../../javax/sip/SipException.html" title="class in javax.sip">SipException</A></CODE> - if the SipProvider cannot send the Request for any  reason.<DT><B>See Also:</B><DD><A HREF="../../javax/sip/message/Request.html" title="interface in javax.sip.message"><CODE>Request</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="createCancel()"><!-- --></A><H3>
createCancel</H3>
<PRE>
<A HREF="../../javax/sip/message/Request.html" title="interface in javax.sip.message">Request</A> <B>createCancel</B>()
                     throws <A HREF="../../javax/sip/SipException.html" title="class in javax.sip">SipException</A></PRE>
<DL>
<DD>Creates a new Cancel message from the Request associated with this client transaction. The CANCEL request, is used to cancel the previous request  sent by this client transaction. Specifically, it asks the UAS to cease  processing the request and to generate an error response to that request.  A CANCEL request constitutes its own transaction, but also references  the transaction to be cancelled. CANCEL has no effect on a request to  which a UAS has already given a final response. <p> Note that both the transaction corresponding to the original request and the CANCEL transaction will complete independently.  However, a UAC canceling a request cannot rely on receiving a 487 (Request Terminated) response for the original request, as an RFC 2543 compliant UAS will not generate such a response. Therefore if there is no final response for the original request the application will receieve a TimeoutEvent with <A HREF="../../javax/sip/Timeout.html#TRANSACTION"><CODE>Timeout.TRANSACTION</CODE></A> and the client should then consider the original transaction cancelled. <ul> <li> UAC - A UAC should not send a CANCEL request to any request explicitly supported by this specification other than INVITE request. The reason  being requests other than INVITE are responded to immediately and sending  a CANCEL for a non-INVITE request would always create a race condition.  CANCELs are useful as a UAC can not send a BYE request on a dialog  until receipt of 2xx final response to the INVITE request. The CANCEL  attempts to force a non-2xx response to the INVITE, therefore if a UAC  wishes to give up on its call attempt entirely it can send a CANCEL. <li>Stateful proxies - A stateful proxy may generate CANCEL requests  for: <ul> <li>INVITE Requests - A CANCEL can be sent on pending INVITE client transactions based on the period specified in the INVITE's Expires header field elapsing.  However, this is generally unnecessary since the endpoints involved will take care of signaling the end of the transaction. <li> Other Requests - An implementation of this specification does not need to support CANCELing non-INVITE transactions. </ul> </ul>
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>

<DT><B>Returns:</B><DD>the new cancel Request specific to the Request of this client transaction.
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../javax/sip/SipException.html" title="class in javax.sip">SipException</A></CODE> - if this method is called to cancel a request that can't be cancelled i.e. ACK.</DL>
</DD>
</DL>
<HR>

<A NAME="createAck()"><!-- --></A><H3>
createAck</H3>
<PRE>
<A HREF="../../javax/sip/message/Request.html" title="interface in javax.sip.message">Request</A> <B>createAck</B>()
                  throws <A HREF="../../javax/sip/SipException.html" title="class in javax.sip">SipException</A></PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;<I>Since v1.2. As a transaction that received a 2xx response terminates immediately, it cannot be used for creating the corresponding ACK. If this transaction created a dialog, the  <A HREF="../../javax/sip/Dialog.html#createAck(long)"><CODE>Dialog.createAck(long)</CODE></A> method should be used. Otherwise the stack will automatically create and send the ACK for non-2xx responses that need to be acknowledged.  That is the application should never need to use this method.</I>
<P>
<DD>Creates a new Ack message from the Request associated with this client transaction. This ACK can be used to acknowledge the 2xx response to the  request sent by this transaction.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>

<DT><B>Returns:</B><DD>the new ACK Request specific to the Request of this client transaction.
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../javax/sip/SipException.html" title="class in javax.sip">SipException</A></CODE> - if this method is called before a final response  is received for the transaction.</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>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</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">
&nbsp;PREV CLASS&nbsp;
&nbsp;<A HREF="../../javax/sip/Dialog.html" title="interface in javax.sip"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../index.html?javax/sip/ClientTransaction.html" target="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="ClientTransaction.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
&nbsp;<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:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<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 + -