cellular/telephonysettings/inc/MCallDiverting.h
changeset 46 2fa1fa551b0b
parent 42 35488577e233
child 48 78df25012fda
equal deleted inserted replaced
42:35488577e233 46:2fa1fa551b0b
     1 /*
       
     2 * Copyright (c) 2002-2006 Nokia Corporation and/or its subsidiary(-ies). 
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description: Declaration of MCallDiverting interface class.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef     MCALLDIVERTING_H
       
    20 #define     MCALLDIVERTING_H
       
    21 
       
    22 /**
       
    23  *  MCallDiverting class is virtual interface class for divert 
       
    24  *  functionality.
       
    25  *
       
    26  *  @lib phonesettings
       
    27  *  @since S60 v5.1
       
    28  */
       
    29 class MCallDiverting
       
    30     {
       
    31     public:
       
    32         /**
       
    33          * Sets observer which informs when request is completed
       
    34          */
       
    35         virtual void SetRequestObserver( MPsetRequestObserver* aObs ) = 0;
       
    36     
       
    37         /**
       
    38         * Sets diverting to the network.
       
    39         * 
       
    40         * @param aDivert New divert settings.
       
    41         * @param aBsc List of basic service groups .
       
    42         */
       
    43         virtual void SetDivertingL( const TCallDivertSetting& aDivert,  
       
    44                                     TBasicServiceGroups aBsc ) = 0;
       
    45         /**
       
    46         * Checks the diverting status from network.
       
    47         * 
       
    48         * @param aServiceGroup Service group indication.
       
    49         * @param aCondition Diverting conditions.
       
    50         * @param aBsc List of basic service groups.
       
    51         */
       
    52         virtual void GetDivertingStatusL( 
       
    53                                     const TServiceGroup aServiceGroup, 
       
    54                                     const TCallDivertingCondition aCondition, 
       
    55                                     TBasicServiceGroups aBsc ) = 0;
       
    56         /**
       
    57         * Cancels current request.
       
    58         * 
       
    59         * @return Returns error code.
       
    60         */
       
    61         virtual TInt CancelCurrentRequest() = 0;
       
    62         
       
    63         /**
       
    64         *  Reads used divert numbers (0-3) from central repository
       
    65         *  and fills array with them.
       
    66         *
       
    67         *  @param aType used line.
       
    68         *  @param aArray array of divert number.
       
    69         *  @return amount of numbers.
       
    70         */
       
    71         virtual TInt GetNumbersFromSharedDataL( 
       
    72                                     TInt aType, 
       
    73                                     CDesC16ArrayFlat& aArray ) = 0;
       
    74         /**
       
    75         * Sets new default number the the default numbers list, 
       
    76         * erases the oldest one.
       
    77         * 
       
    78         * @param aNumber phone number. 
       
    79         * @return Returns error code.
       
    80         */
       
    81         virtual TInt SetNewDefaultNumberL( TDes& aNumber ) = 0;
       
    82         
       
    83         /**
       
    84         *  Gets the default time for CF No Reply.
       
    85         *  No error checking for return values which should be
       
    86         *  5-30, in steps of 5.
       
    87         *
       
    88         * @return Returns the current timer value.
       
    89         */
       
    90         virtual TInt GetTimerValueL() = 0;
       
    91         
       
    92         /*
       
    93         *  Sets the default time for CF No Reply.
       
    94         *  No error checking to parameters, which should be on range 5-30,
       
    95         *  using steps of 5.
       
    96         *
       
    97         *  @param aIndex New value for timer.
       
    98         *  @return Returns error code.
       
    99         */
       
   100         virtual TInt SetTimerValueL( const TInt& aValue ) = 0;
       
   101         
       
   102         /**
       
   103         * Swaps the most recently used number to first in shared data file.
       
   104         *
       
   105         * @param  aLocation Used number's location (1-3) in shared data.
       
   106         */
       
   107         virtual void SwapDefaultNumberL( const TInt& aLocation ) = 0;
       
   108         
       
   109         /**
       
   110         * Saves a single value to central repository. Make sure that repository
       
   111         * is open before calling this function.
       
   112         */
       
   113         virtual TInt SaveKey( TUint32 aKeyId, const TDesC& aKeyValue ) = 0;
       
   114         
       
   115         /*
       
   116         * Virtual destructor. 
       
   117         */ 
       
   118         virtual ~MCallDiverting() {};
       
   119     };
       
   120 
       
   121 #endif // MPCALLDIVERTING_H