phoneclientserver/dialutils/inc/dialutilsimpl.h
changeset 51 12bc758d6a02
parent 48 78df25012fda
child 53 25b8d29b7c59
equal deleted inserted replaced
48:78df25012fda 51:12bc758d6a02
     1 /*
       
     2 * Copyright (c) 2004-2005 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:  Provides implementation for DialUtils.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef DIALUTILSIMPL_H
       
    20 #define DIALUTILSIMPL_H
       
    21 
       
    22 //  INCLUDES
       
    23 #include    <e32std.h>
       
    24 #include    <dialutils.h> 
       
    25 
       
    26 
       
    27 // FORWARD DECLARATIONS
       
    28 class RSharedDataClient;
       
    29 class CRepository;
       
    30 
       
    31 
       
    32 // CONSTANTS
       
    33 
       
    34 // The prefix text.
       
    35 typedef TBuf<10> TDiUtPrefixText;
       
    36 
       
    37 
       
    38 // CLASS DECLARATION
       
    39 
       
    40 /**
       
    41 *  DialUtils implementation.
       
    42 *  
       
    43 *  @lib DialUtils.lib
       
    44 *  @since 2.6
       
    45 */
       
    46 class CDialUtilsImpl
       
    47 :   public CDialUtilsApi
       
    48     {
       
    49     public:  // Constructors and destructor
       
    50 
       
    51         /**
       
    52         * Two-phased constructor.
       
    53         * @return an instance of DialUtilsImpl.
       
    54         */
       
    55         static CDialUtilsImpl* NewL();
       
    56         
       
    57         /**
       
    58         * Destructor.
       
    59         */
       
    60         virtual ~CDialUtilsImpl();
       
    61 
       
    62 
       
    63     public:  // New functions
       
    64 
       
    65         /**
       
    66         * Check and modify the phone number.
       
    67         * 
       
    68         * @see CDialUtilsApi::CheckNumber.
       
    69         */
       
    70         TInt CheckNumber( HBufC& aPhoneNumber );
       
    71 
       
    72 
       
    73    
       
    74     private:
       
    75 
       
    76         /**
       
    77         * C++ default constructor.
       
    78         */
       
    79         CDialUtilsImpl();
       
    80 
       
    81         /**
       
    82         * By default Symbian 2nd phase constructor is private.
       
    83         */
       
    84         void ConstructL();
       
    85 
       
    86         /**
       
    87         * Combine the given texts if needed.
       
    88         * 
       
    89         * @param aPhoneNumber The number to be modified.
       
    90         * @param aPrefixText The prefixText to be added 
       
    91         *                    to aPhoneNumber if needed.
       
    92         */
       
    93         TInt CombineTexts(
       
    94             TPtr aPhoneNumber,
       
    95             const TDiUtPrefixText& aPrefixText ) const;
       
    96 
       
    97 
       
    98     private:    // Data
       
    99 
       
   100         // The shared data client.
       
   101         RSharedDataClient*              iSharedDataClient;
       
   102 
       
   103         // The central repository.
       
   104         CRepository*                    iRepository;
       
   105     };
       
   106 
       
   107 #endif  // DIALUTILSIMPL_H
       
   108 
       
   109 // End of file