📄 class_c_chat_bt_service_advertiser.html
字号:
<tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">void CChatBtServiceAdvertiser::StopAdvertisingL </td> <td class="md" valign="top">( </td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>StopAdvertisingL Stop advertising this service. Remove the record from the sdp database <p>Definition at line <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html#l00146">146</a> of file <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html">ChatBtServiceAdvertiser.cpp</a>.<p>References <a class="el" href="_chat_bt_service_advertiser_8h-source.html#l00133">iRecord</a>, <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html#l00160">IsAdvertising()</a>, and <a class="el" href="_chat_bt_service_advertiser_8h-source.html#l00127">iSdpDatabase</a>.<p>Referenced by <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html#l00075">StartAdvertisingL()</a>, <a class="el" href="_chat_bt_8cpp-source.html#l00565">CChatBt::StopL()</a>, and <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html#l00040">~CChatBtServiceAdvertiser()</a>.<div class="fragment"><pre class="fragment"><a name="l00147"></a>00147 {<a name="l00148"></a>00148 <span class="keywordflow">if</span> ( <a class="code" href="class_c_chat_bt_service_advertiser.html#8b6ebb2e28d11dbf0c365fe8d479df10">IsAdvertising</a>() )<a name="l00149"></a>00149 {<a name="l00150"></a>00150 <a class="code" href="class_c_chat_bt_service_advertiser.html#0624093ab131c90dd1f624ed8a2b4c1b">iSdpDatabase</a>.DeleteRecordL( <a class="code" href="class_c_chat_bt_service_advertiser.html#9b1caea877e51f30ee8c88479638dca8">iRecord</a> );<a name="l00151"></a>00151 <a class="code" href="class_c_chat_bt_service_advertiser.html#9b1caea877e51f30ee8c88479638dca8">iRecord</a> = 0;<a name="l00152"></a>00152 }<a name="l00153"></a>00153 }</pre></div><p> </td> </tr></table><a class="anchor" name="8b6ebb2e28d11dbf0c365fe8d479df10"></a><!-- doxytag: member="CChatBtServiceAdvertiser::IsAdvertising" ref="8b6ebb2e28d11dbf0c365fe8d479df10" args="()" --><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">TBool CChatBtServiceAdvertiser::IsAdvertising </td> <td class="md" valign="top">( </td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>IsAdvertising Does the SDP database contain a record for this service <dl compact><dt><b>Returns:</b></dt><dd>ETrue whether the service is being advertised </dd></dl><p>Definition at line <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html#l00160">160</a> of file <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html">ChatBtServiceAdvertiser.cpp</a>.<p>References <a class="el" href="_chat_bt_service_advertiser_8h-source.html#l00133">iRecord</a>.<p>Referenced by <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html#l00075">StartAdvertisingL()</a>, <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html#l00146">StopAdvertisingL()</a>, <a class="el" href="_chat_bt_8cpp-source.html#l00565">CChatBt::StopL()</a>, and <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html#l00040">~CChatBtServiceAdvertiser()</a>.<div class="fragment"><pre class="fragment"><a name="l00161"></a>00161 {<a name="l00162"></a>00162 <span class="keywordflow">return</span> <a class="code" href="class_c_chat_bt_service_advertiser.html#9b1caea877e51f30ee8c88479638dca8">iRecord</a> != 0;<a name="l00163"></a>00163 }</pre></div><p> </td> </tr></table><a class="anchor" name="29ff2152d04f8af97601d4a42d6ec6c0"></a><!-- doxytag: member="CChatBtServiceAdvertiser::UpdateAvailabilityL" ref="29ff2152d04f8af97601d4a42d6ec6c0" args="(TBool aIsAvailable)" --><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">void CChatBtServiceAdvertiser::UpdateAvailabilityL </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">TBool </td> <td class="mdname1" valign="top" nowrap> <em>aIsAvailable</em> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>UpdateAvailabilityL Update the service availability field of the service record <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>aIsAvailable</em> </td><td>ETrue is the service is not busy. </td></tr> </table></dl><p>Definition at line <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html#l00118">118</a> of file <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html">ChatBtServiceAdvertiser.cpp</a>.<p>References <a class="el" href="_chat_bt_service_advertiser_8h-source.html#l00133">iRecord</a>, <a class="el" href="_chat_bt_service_advertiser_8h-source.html#l00139">iRecordState</a>, and <a class="el" href="_chat_bt_service_advertiser_8h-source.html#l00127">iSdpDatabase</a>.<p>Referenced by <a class="el" href="_chat_bt_8cpp-source.html#l00123">CChatBt::RunL()</a>, and <a class="el" href="_chat_bt_8cpp-source.html#l00453">CChatBt::StartL()</a>.<div class="fragment"><pre class="fragment"><a name="l00119"></a>00119 {<a name="l00120"></a>00120 TUint state;<a name="l00121"></a>00121 <span class="keywordflow">if</span> ( aIsAvailable )<a name="l00122"></a>00122 {<a name="l00123"></a>00123 state = 0xFF; <span class="comment">// Fully unused</span><a name="l00124"></a>00124 }<a name="l00125"></a>00125 <span class="keywordflow">else</span><a name="l00126"></a>00126 {<a name="l00127"></a>00127 state = 0x00; <span class="comment">// Fully used -> can't connect</span><a name="l00128"></a>00128 }<a name="l00129"></a>00129 <a name="l00130"></a>00130 <span class="comment">// Update the availibility attribute field</span><a name="l00131"></a>00131 <a class="code" href="class_c_chat_bt_service_advertiser.html#0624093ab131c90dd1f624ed8a2b4c1b">iSdpDatabase</a>.UpdateAttributeL( <a class="code" href="class_c_chat_bt_service_advertiser.html#9b1caea877e51f30ee8c88479638dca8">iRecord</a>, <a name="l00132"></a>00132 KSdpAttrIdServiceAvailability, <a name="l00133"></a>00133 state );<a name="l00134"></a>00134 <a name="l00135"></a>00135 <span class="comment">// Mark the record as changed - by increasing its state number (version)</span><a name="l00136"></a>00136 <a class="code" href="class_c_chat_bt_service_advertiser.html#0624093ab131c90dd1f624ed8a2b4c1b">iSdpDatabase</a>.UpdateAttributeL( <a class="code" href="class_c_chat_bt_service_advertiser.html#9b1caea877e51f30ee8c88479638dca8">iRecord</a>, <a name="l00137"></a>00137 KSdpAttrIdServiceRecordState, <a name="l00138"></a>00138 ++<a class="code" href="class_c_chat_bt_service_advertiser.html#81266616ac61b523dcd21924946af588">iRecordState</a> );<a name="l00139"></a>00139 }</pre></div><p> </td> </tr></table><a class="anchor" name="520c20f428c758a9e0f537bcae9ded62"></a><!-- doxytag: member="CChatBtServiceAdvertiser::BuildProtocolDescriptionL" ref="520c20f428c758a9e0f537bcae9ded62" args="(CSdpAttrValueDES *aProtocolDescriptor, TInt aPort)=0" --><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">virtual void CChatBtServiceAdvertiser::BuildProtocolDescriptionL </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">CSdpAttrValueDES * </td> <td class="mdname" nowrap> <em>aProtocolDescriptor</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>TInt </td> <td class="mdname" nowrap> <em>aPort</em></td> </tr> <tr> <td class="md"></td> <td class="md">) </td> <td class="md" colspan="2"><code> [protected, pure virtual]</code></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>BuildProtocolDescriptionL Builds the protocol description <dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>aProtocolDescriptor</em> </td><td>the protocol descriptor </td></tr> <tr><td valign="top"></td><td valign="top"><em>aPort</em> </td><td>the service port </td></tr> </table></dl><p>Implemented in <a class="el" href="class_c_chat_service_advertiser.html#3c62960780073fe48ef0ce32a2f60daf">CChatServiceAdvertiser</a>.<p>Referenced by <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html#l00075">StartAdvertisingL()</a>. </td> </tr></table><a class="anchor" name="ccfd2143a5c8480b6ce482aa1e568645"></a><!-- doxytag: member="CChatBtServiceAdvertiser::ServiceClass" ref="ccfd2143a5c8480b6ce482aa1e568645" args="()=0" --><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">virtual TInt CChatBtServiceAdvertiser::ServiceClass </td> <td class="md" valign="top">( </td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap><code> [protected, pure virtual]</code></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>ServiceClass <dl compact><dt><b>Returns:</b></dt><dd>the service class </dd></dl><p>Implemented in <a class="el" href="class_c_chat_service_advertiser.html#a17f3a19af58ae99d6611b72b786603d">CChatServiceAdvertiser</a>.<p>Referenced by <a class="el" href="_chat_bt_service_advertiser_8cpp-source.html#l00075">StartAdvertisingL()</a>. </td> </tr></table><a class="anchor" name="114dc69577dad056af5477ccd2352d2d"></a><!-- doxytag: member="CChatBtServiceAdvertiser::ServiceName" ref="114dc69577dad056af5477ccd2352d2d" args="()=0" --><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">virtual const TDesC& CChatBtServiceAdvertiser::ServiceName </td> <td class="md" valign="top">( </td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap><code> [protected, pure virtual]</code></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -