Symbian3/PDK/Source/GUID-0DA6722B-0700-5612-884A-F3B7733E5252.dita
changeset 1 25a17d01db0c
child 3 46218c8b8afa
equal deleted inserted replaced
0:89d6a7a84779 1:25a17d01db0c
       
     1 <?xml version="1.0" encoding="utf-8"?>
       
     2 <!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
       
     3 <!-- This component and the accompanying materials are made available under the terms of the License 
       
     4 "Eclipse Public License v1.0" which accompanies this distribution, 
       
     5 and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
       
     6 <!-- Initial Contributors:
       
     7     Nokia Corporation - initial contribution.
       
     8 Contributors: 
       
     9 -->
       
    10 <!DOCTYPE task
       
    11   PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
       
    12 <task id="GUID-0DA6722B-0700-5612-884A-F3B7733E5252" xml:lang="en"><title>Voice
       
    13 Line Status Tutorial</title><shortdesc>This tutorial describes how to get the voice line status with the
       
    14 telephony API for applications. </shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody>
       
    15 
       
    16 
       
    17 <context id="GUID-BAC8D4B3-FAB2-4EE9-B20F-41810AEBD84E"><p>The <xref href="GUID-97D402C8-B4B7-385A-92B3-D3FCC0CA575A.dita"><apiname>CTelephony</apiname></xref> functions provide a detailed
       
    18  information on the voice line status. The detailed call information provides
       
    19  the information about: </p><ul>
       
    20 <li><p>call status  </p></li>
       
    21 <li><p> date of the call  </p></li>
       
    22 <li><p> time of the call  </p></li>
       
    23 <li><p> duration of the call  </p></li>
       
    24 <li><p>destination number  </p></li>
       
    25 <li><p>caller identification  </p></li>
       
    26 <li><p>dynamic call capabilities  </p></li>
       
    27 </ul></context>
       
    28 <steps id="GUID-F9E13043-8D2A-57BC-B9C0-ADD51F3AA449">
       
    29 <step id="GUID-7BA25A70-5F62-5668-8A64-D5F90FD72504"><cmd>create a new instance
       
    30 of <xref href="GUID-97D402C8-B4B7-385A-92B3-D3FCC0CA575A.dita"><apiname>CTelephony</apiname></xref>  </cmd>
       
    31 </step>
       
    32 <step id="GUID-382DD7F5-8555-5B06-9596-08D1C4684714"><cmd>use <xref href="GUID-97D402C8-B4B7-385A-92B3-D3FCC0CA575A.dita"><apiname>CTelephony::GetLineStatus()</apiname></xref> to
       
    33 get the simple voice line status</cmd>
       
    34 </step>
       
    35 <step id="GUID-2B2692FB-88FF-5F40-8FC0-A30D7146C757"><cmd>use <xref href="GUID-97D402C8-B4B7-385A-92B3-D3FCC0CA575A.dita"><apiname>CTelephony::GetCallStatus()</apiname></xref> to
       
    36 get the status of any voice call owned by the client application </cmd>
       
    37 </step>
       
    38 <step id="GUID-C46FB87F-B7FB-5347-9199-D27CA9634E6F"><cmd>use <xref href="GUID-97D402C8-B4B7-385A-92B3-D3FCC0CA575A.dita"><apiname>CTelephony::GetCallInfo()</apiname></xref> to
       
    39 get the detailed call information about the call </cmd>
       
    40 <info>pass the following parameters for the required information </info>
       
    41 <stepxmp><table id="GUID-9FDDE4F7-130C-55C9-8205-CF8C96575665">
       
    42 <tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
       
    43 <thead>
       
    44 <row>
       
    45 <entry>Parameter</entry>
       
    46 <entry>Function</entry>
       
    47 </row>
       
    48 </thead>
       
    49 <tbody>
       
    50 <row>
       
    51 <entry><p>TCallStatus </p> </entry>
       
    52 <entry><p>To get the status of a call like idle, on-hold, dialling and ringing </p> </entry>
       
    53 </row>
       
    54 <row>
       
    55 <entry><p>TDateTime </p> </entry>
       
    56 <entry><p>To get the data and time of a call </p> </entry>
       
    57 </row>
       
    58 <row>
       
    59 <entry><p>TTimeIntervalSeconds </p> </entry>
       
    60 <entry><p>To get the duration of a call </p> </entry>
       
    61 </row>
       
    62 <row>
       
    63 <entry><p>TTelAddress </p> </entry>
       
    64 <entry><p>To get the destination number </p> </entry>
       
    65 </row>
       
    66 <row>
       
    67 <entry><p>TPhoneNetworkSecurity </p> </entry>
       
    68 <entry><p>To get the ciphering information from the network </p> </entry>
       
    69 </row>
       
    70 <row>
       
    71 <entry><p>TCallRemoteIdentityStatus </p> </entry>
       
    72 <entry><p>To determine if the remote caller status is available </p> </entry>
       
    73 </row>
       
    74 <row>
       
    75 <entry><p>TCallDirection </p> </entry>
       
    76 <entry><p>To determine the call direction </p> </entry>
       
    77 </row>
       
    78 </tbody>
       
    79 </tgroup>
       
    80 </table> </stepxmp>
       
    81 </step>
       
    82 <step id="GUID-0604B8F5-98CA-57B1-98D9-2B91708CF29C"><cmd>use <xref href="GUID-97D402C8-B4B7-385A-92B3-D3FCC0CA575A.dita"><apiname>GetCallDynamicCaps()</apiname></xref> to
       
    83 get the dynamic capability information about the call.</cmd>
       
    84 </step>
       
    85 </steps>
       
    86 <example id="GUID-6F8987BC-703D-549F-85F7-11BDB3EAC319"><title>Voice call
       
    87 information example</title> <p>The example code describes the steps to get
       
    88 the detailed call information. </p> <codeblock id="GUID-5B4EF60C-66A0-5862-9E72-6759532AC776" xml:space="preserve">CTelephony* telephony = CTelephony::NewLC();
       
    89 
       
    90 CTelephony::TCallInfoV1 callInfoV1;
       
    91 CTelephony::TCallInfoV1Pckg callInfoV1Pckg( callInfoV1 );
       
    92 
       
    93 CTelephony::TCallSelectionV1 callSelectionV1;
       
    94 CTelephony::TCallSelectionV1Pckg callSelectionV1Pckg( callSelectionV1 );
       
    95 
       
    96 CTelephony::TRemotePartyInfoV1 remotePartyInfoV1;
       
    97 CTelephony::TRemotePartyInfoV1Pckg remotePartyInfoV1Pckg( remotePartyInfoV1  );
       
    98 
       
    99 callSelectionV1.iLine = CTelephony::EVoiceLine;
       
   100 callSelectionV1.iSelect = CTelephony::EActiveCall;
       
   101 
       
   102 telephony-&gt;GetCallInfo( callSelectionV1Pckg, callInfoV1Pckg, remotePartyInfoV1Pckg );
       
   103 
       
   104 CleanupStack::PopAndDestroy( telephony );</codeblock> </example>
       
   105 <postreq id="GUID-3A6FA503-E4A8-5013-A155-E8F80844281B"><p>The example code
       
   106 to get the dynamic call capability information </p> <codeblock id="GUID-53DB7E1D-B6FA-5497-9140-28EB10EF242C" xml:space="preserve">CTelephony::TCallCapsV1 callCapsV1;
       
   107 CTelephony::TCallCapsV1Pckg callCapsV1Pckg( callCapsV1 );
       
   108 
       
   109 telephony-&gt;GetCallDynamicCaps( callId, callCapsV1Pckg );
       
   110 TUint32 caps = callCapsV1.iControlCaps;
       
   111 if( caps &amp; CTelephony::KCapsHold )
       
   112    {} // The call represented by 'callId' can be put on hold</codeblock> </postreq>
       
   113 </taskbody></task>