ImagePrint/ImagePrintUI/imageprinteng/inc/settingsconverter.h
branchGCC_SURGE
changeset 25 59ea2209bb67
parent 23 08cc4cc059d4
parent 15 a92d00fca574
equal deleted inserted replaced
23:08cc4cc059d4 25:59ea2209bb67
     1 /*
       
     2 * Copyright (c) 2004-2007 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:  
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef SETTINGSCONVERTER_H
       
    20 #define SETTINGSCONVERTER_H
       
    21 
       
    22 #include <e32std.h>
       
    23 
       
    24 class CTIntCapability;
       
    25 class CListCapability;
       
    26 class CFloatCapability;
       
    27 class TPrintCapability;
       
    28 class CRealFactory;
       
    29 
       
    30 /**
       
    31  *
       
    32  *  Utility class for converting capabilities to correct format
       
    33  *
       
    34  */
       
    35 class SettingsConverter
       
    36     {
       
    37     public:
       
    38 
       
    39         /**
       
    40          *  Converts TCapability to CTIntCapability
       
    41          *
       
    42          *  @param aCapability      Capability coming from the engine
       
    43          *  @param aIndexOnList     Capability's index on the list box
       
    44          *  @param aCapabUid        Capability's UID
       
    45          *  @return Initialized CTIntCapability instance
       
    46          */
       
    47         static CTIntCapability* AddTIntCapabilityLC(
       
    48             TPrintCapability& aCapability, TInt aIndexOnList, TInt aCapabUid );
       
    49 
       
    50         /**
       
    51          *  Converts TCapability to CListCapability
       
    52          *
       
    53          *  @param aCapability      Capability coming from the engine
       
    54          *  @param aIndexOnList     Capability's index on the list box
       
    55          *  @param aCapabUid        Capability's UID
       
    56          *  @return Initialized CListCapability instance
       
    57          */
       
    58         static CListCapability* AddListCapabilityLC(
       
    59             TPrintCapability& aCapability, TInt aIndexOnList, TInt aCapabUid,
       
    60                     CRealFactory* aFactory );
       
    61 
       
    62         /**
       
    63          *  Converts TCapability to CFloatCapability
       
    64          *
       
    65          *  @param aCapability      Capability coming from the engine
       
    66          *  @param aIndexOnList     Capability's index on the list box
       
    67          *  @param aCapabUid        Capability's UID
       
    68          *  @return Initialized CFloatCapability instance
       
    69          */
       
    70         static CFloatCapability* AddFloatCapabilityLC(
       
    71             TPrintCapability& aCapability, TInt aIndexOnList, TInt aCapabUid );
       
    72 
       
    73     private:
       
    74 
       
    75         /**
       
    76          *  Creates text string from the enumeration ID
       
    77          *
       
    78          *  @param aId      Enumeration Id
       
    79          *  @return buffer containing the string
       
    80          */
       
    81         static HBufC* TextStringLC( TInt aId );
       
    82     };
       
    83 
       
    84 #endif  //  SETTINGSCONVERTER_H
       
    85 
       
    86 //  End of File