Symbian3/PDK/Source/GUID-A18BC63B-38CB-520E-89FF-955D18CC8B54.dita
author Dominic Pinkman <Dominic.Pinkman@Nokia.com>
Fri, 22 Jan 2010 18:26:19 +0000
changeset 1 25a17d01db0c
child 3 46218c8b8afa
permissions -rw-r--r--
Addition of the PDK content and example code for Documentation_content according to Feature bug 1607 and bug 1608

<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
<!-- This component and the accompanying materials are made available under the terms of the License 
"Eclipse Public License v1.0" which accompanies this distribution, 
and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
<!-- Initial Contributors:
    Nokia Corporation - initial contribution.
Contributors: 
-->
<!DOCTYPE task
  PUBLIC "-//OASIS//DTD DITA Task//EN" "task.dtd">
<task xml:lang="en" id="GUID-A18BC63B-38CB-520E-89FF-955D18CC8B54"><title>Next Incoming Call Settings Tutorial</title><shortdesc>This tutorial describes how to get and set the next incoming call type. </shortdesc><prolog><metadata><keywords/></metadata></prolog><taskbody> <context><p>The GSM has a Single Numbering Scheme. A subscriber has one directory MSISDN number for all type of call like voice, Fax and data. The network does not detect the type of inbound calls. The subscriber to select the bearer service to use for the inbound calls. </p> </context> <steps id="GUID-A1607FE8-B039-5665-B4F8-CCDB80979079"> <step id="GUID-868D849C-D5B3-5D41-9B6A-41633B72F385"><cmd>Get the current setting using <xref href="GUID-AA81AFA4-6FAC-3B0D-A082-BE0AEC58CCA8.dita"><apiname>RMobilePhone::GetIncomingCallType()</apiname></xref>. </cmd> <info>The possible types of settings are described in the <xref href="GUID-AA81AFA4-6FAC-3B0D-A082-BE0AEC58CCA8.dita"><apiname>RMobilePhone::TMobilePhoneIncomingCallType</apiname></xref> enum. Settings are encapsulated in a packaged call parameters <xref href="GUID-AA81AFA4-6FAC-3B0D-A082-BE0AEC58CCA8.dita"><apiname>RMobileCall::TMobileDataCallParamsV1</apiname></xref> object or a subclass. </info> </step> <step id="GUID-AEA014A0-A03D-5971-B462-4393394FD483"><cmd>Set the next incoming call type using <xref href="GUID-AA81AFA4-6FAC-3B0D-A082-BE0AEC58CCA8.dita"><apiname>RMobilePhone::SetIncomingCallType()</apiname></xref>  </cmd> </step> <step id="GUID-96692F2A-6764-5620-96BF-00FECE7536D1"><cmd>Use <xref href="GUID-AA81AFA4-6FAC-3B0D-A082-BE0AEC58CCA8.dita"><apiname>RMobilePhone::NotifyIncomingCallTypeChange()</apiname></xref> to get the notification of any changes to the next incoming call type. </cmd> </step> </steps> <example><title>Next incoming call example</title> <p>The following code gets the current incoming call type setting, and checks if it is voice. </p> <p>The code assumes <codeph>iMobilePhone</codeph> is an <xref href="GUID-AA81AFA4-6FAC-3B0D-A082-BE0AEC58CCA8.dita"><apiname>RMobilePhone</apiname></xref> object. </p> <codeblock id="GUID-E563B17A-F353-568D-AC01-F3C1B122AC10" xml:space="preserve">RMobilePhone::TMobilePhoneIncomingCallType callType;
RMobileCall::TMobileDataCallParamsV1 mobileCallParams;
RMobileCall::TMobileDataCallParamsV1Pckg mobileCallParamsPckg(mobileCallParams);
TRequestStatus status;

iMobilePhone.GetIncomingCallType(status, callType, mobileCallParamsPckg);
User::WaitForRequest(status);
User::LeaveIfError(status.Int());

if (callType == RMobilePhone::EIncomingVoice)
    {
     //do something
    }
</codeblock> </example> </taskbody></task>