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

📄 phonecarddevice.html

📁 很好用的基于sip的代理
💻 HTML
📖 第 1 页 / 共 2 页
字号:
<html><head> 	<title> Vovida SIP User Agent	</title> </head><body bgcolor="#FFFFFF"><table align="center" border="0" cellspacing="0" cellpadding="10" width="100%">    <tr>	<td align="center" valign="center" bgcolor="#FFFFFF">    	    <a href="http://www.vovida.org">		<img src="../doc++/vovida-logo2.gif" 		    width="90" height="88" border="0"></a>	</td>	<td colspan="3" align="center" valign="center" bgcolor="#8C0042">    	    <a href="index.html">    	    <font   face="PrimaSans BT,Verdana,sans-serif" 	    	    color="white" size="+2">    		<strong>		    Vovida SIP User Agent		</strong></font></a>	</td>    </tr>    <tr>	<td colspan="4" bgcolor="#FFFFFF">    	    &nbsp;	</td>    </tr></table>In file PhoneCardDevice.hxx:<TABLE BORDER=0><TR><TD VALIGN=TOP><H2>class  <A HREF="#DOC.DOCU">PhoneCardDevice</A></H2></TD></H2></TD></TR></TABLE><BLOCKQUOTE> Initializes a QuickNet PhoneCARD and handles hardware control </BLOCKQUOTE><HR><H2>Inheritance:</H2><APPLET CODE="ClassGraph.class" WIDTH=600 HEIGHT=65><param name=classes value="CResGwDevice,MResGwDevice.html,CPhoneCardDevice,MPhoneCardDevice.html"><param name=before value="M,M"><param name=after value="Md_,M"><param name=indent value="0,1"><param name=arrowdir value="up"></APPLET><HR><DL><P><TABLE><DT><H3>Public Methods</H3><DD><TR><TD VALIGN=TOP><A HREF="#DOC.25.1"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A> </TD><TD><B>PhoneCardDevice</B> ( const char* deviceName, Sptr &lt; Fifo &lt; Sptr &lt; Event &gt; &gt; &gt; inputQ, Sptr &lt; Fifo &lt; Sptr &lt; Event &gt; &gt; &gt; outputQ )<BR><I>Creates a hardware object to control a single port gateway.</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.2"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A> </TD><TD><B>~PhoneCardDevice</B> ()<BR><I>Destructor</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.3"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void* </TD><TD><B>hardwareMain</B> (void* parms)<BR><I>Starts the main processing loop of the hardware </I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.4"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>int </TD><TD><B>addToFdSet</B> (fd_set* fd)<BR><I>Add device's socket to the fd (File Descriptor) </I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.5"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>int </TD><TD><B>process</B> (fd_set* fd)<BR><I>Process all pending hardware events </I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.6"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>int </TD><TD><B>audioStart</B> (const HardwareAudioRequest&amp; request)<BR><I>Start audio channel on device </I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.7"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>int </TD><TD><B>audioStop</B> ()<BR><I>Stops audio channel on device </I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.8"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>int </TD><TD><B>audioSuspend</B> ()<BR><I>Suspend audio channel on device </I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.9"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>int </TD><TD><B>audioResume</B> (const HardwareAudioRequest&amp; request)<BR><I>Resume audio channel on device </I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.10"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>virtual   void </TD><TD><B>processRTP</B> ()<BR><I>process RTP audio packets</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.11"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>virtual   int </TD><TD><B>getRtpPort</B> ()<BR><I>Instantiates a rtp session and reserves a rtp port </I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.12"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>virtual   void </TD><TD><B>releaseRtpPort</B> ()<BR><I>Release the port and deallocate the rtp session</I></TD></TR></TABLE></P><P><TABLE><DT><H3>Private Fields</H3><DD><TR><TD VALIGN=TOP><A HREF="#DOC.25.33"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>Sptr&lt; Fifo &lt; Sptr &lt; Event &gt; &gt; &gt;  </TD><TD><B>sessionQ</B> <BR><I>Output queue to notify endpoint of occurence of hardware events</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.34"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>bool </TD><TD><B>audioActive</B> <BR><I>true if RTP audio packets are being processed</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.35"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>bool </TD><TD><B>audioHalfActive</B> <BR><I>true if only sending RTP audio packets</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.36"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>bool </TD><TD><B>playDialTone</B> <BR><I>Used to turn off dialtone after pressing a digit</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.37"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>RtpSession* </TD><TD><B>audioStack</B> <BR><I>RTP session variables</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.38"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>int </TD><TD><B>ringbackFd</B> <BR><I>variables for remote ringback tone</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.39"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>VMutex </TD><TD><B>deviceMutex</B> <BR><I>This is used to lock the RTP thread and the hardware thread so that they don't access the hardware device simultaneously</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.40"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>int </TD><TD><B>stdinFD</B> <BR><I>needed for proper terminal control</I></TD></TR></TABLE></P><P><TABLE><DT><H3>Private Methods</H3><DD><TR><TD VALIGN=TOP><A HREF="#DOC.25.13"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>int </TD><TD><B>getRingbackTone</B> (char* , int size)<BR><I>???</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.14"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>onhookOrFlash</B> ()<BR><I>Used to determine when an onhook event becomes a flash event </I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.15"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>startSendRingback</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.16"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>stopSendRingback</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.17"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideDialToneStart</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.18"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideDialToneStop</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.19"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideRingStart</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.20"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideRingStop</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.21"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideLocalRingbackStart</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.22"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideLocalRingbackStop</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.23"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideBusyToneStart</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.24"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideBusyToneStop</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.25"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideFastBusyToneStart</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.26"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideFastBusyToneStop</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.27"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideCallInfo</B> (string, string, string)<BR><I>Currently used only in VmcpDevice</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.28"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideDtmf</B> (DeviceSignalType)<BR><I>Prints dtmf digit or symbol to stdout</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.29"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>killTone</B> ()<BR><I>Sends ioctl to hardware to stop dialtone</I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.30"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideCallWaitingBeepStart</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.31"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideCallWaitingBeepStop</B> ()<BR><I></I></TD></TR><TR><TD VALIGN=TOP><A HREF="#DOC.25.32"><IMG ALT="[more]" BORDER=0 SRC=icon1.gif></A>void </TD><TD><B>provideTone</B> ( PhoneCardTone tone )<BR><I>Provide simulated tones by playing corresponding audio file</I></TD></TR></TABLE></P></DL><HR><H3>Inherited from <A HREF="ResGwDevice.html">ResGwDevice</A>:</H3><DL><P><DL><DT><H3>Public Methods</H3><DD><DT><IMG ALT="o" SRC=icon2.gif>virtual   void <B>setCallId</B>( const Sptr&lt;SipCallId&gt; newCallId )<DT><IMG ALT="o" SRC=icon2.gif>virtual   Sptr&lt;SipCallId&gt;  <B>getCallId</B>() const <DT><IMG ALT="o" SRC=icon2.gif>virtual   void <B>addCallWaitingId</B>( const Sptr&lt;SipCallId&gt; newCallId )<DT><IMG ALT="o" SRC=icon2.gif>virtual   Sptr&lt;SipCallId&gt;  <B>getCallWaitingId</B>() const <DT><IMG ALT="o" SRC=icon2.gif>virtual   void <B>removeCallWaitingId</B>( const SipCallId&amp; newCallId )<DT><IMG ALT="o" SRC=icon2.gif>virtual   Sptr&lt;<!1><A HREF="DigitCollector.html">DigitCollector</A>&gt;  <B>getDigitCollector</B>()<DT><IMG ALT="o" SRC=icon2.gif>virtual   HardwareStatusType <B>getHardwareStatus</B>()<DT><IMG ALT="o" SRC=icon2.gif>virtual   bool <B>isMyHardware</B>(const SipCallId&amp; callid)<DT><IMG ALT="o" SRC=icon2.gif>virtual   bool <B>isOnCallWaiting</B>(const SipCallId&amp; callid)<DT><IMG ALT="o" SRC=icon2.gif>inline   Sptr&lt; Fifo &lt; Sptr&lt;Event&gt; &gt; &gt;  <B>getQ</B>()<DT><IMG ALT="o" SRC=icon2.gif>inline   int <B>getFD</B>()<DT><IMG ALT="o" SRC=icon2.gif>void <B>setUseRsvp</B>( bool flag )</DL></P><P><DL><DT><H3>Protected Fields</H3><DD><DT><IMG ALT="o" SRC=icon2.gif>bool <B>useRsvp</B><DT><IMG ALT="o" SRC=icon2.gif>int <B>myFD</B><DT><IMG ALT="o" SRC=icon2.gif>Sptr&lt; Fifo &lt; Sptr&lt;Event&gt; &gt; &gt;  <B>myQ</B><DT><IMG ALT="o" SRC=icon2.gif>bool <B>hookStateOffhook</B><DT><IMG ALT="o" SRC=icon2.gif>Sptr&lt;SipCallId&gt;  <B>callId</B><DT><IMG ALT="o" SRC=icon2.gif>Sptr&lt;CallWaitingIdList&gt;  <B>callWaitingIdList</B><DT><IMG ALT="o" SRC=icon2.gif>Sptr&lt;<!1><A HREF="DigitCollector.html">DigitCollector</A>&gt;  <B>digitCollector</B></DL></P><P><DL><DT><H3>Protected Methods</H3><DD><DT><IMG ALT="o" SRC=icon2.gif>int <B>provideSignal</B>( DeviceSignalType signal )<DT><IMG ALT="o" SRC=icon2.gif>void <B>processSessionMsg</B>( Sptr &lt; Event &gt; event )<DT><IMG ALT="o" SRC=icon2.gif>void <B>reportEvent</B>( Sptr &lt; Fifo &lt; Sptr&lt;Event&gt; &gt; &gt; outputQ, DeviceEventType eventType )</DL></P></DL><A NAME="DOC.DOCU"></A><HR>

⌨️ 快捷键说明

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