phonebookui/Phonebook2/UIControls/inc/MPbk2UIField.h
changeset 0 e686773b3f54
equal deleted inserted replaced
-1:000000000000 0:e686773b3f54
       
     1 /*
       
     2 * Copyright (c) 2005-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:  Phonebook 2 contact editor dialog UI field.
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef MPBK2UIFIELD_H_
       
    19 #define MPBK2UIFIELD_H_
       
    20 
       
    21 // INCLUDE FILES
       
    22 #include <e32def.h>
       
    23 #include <e32std.h>
       
    24 #include <TPbk2IconId.h>
       
    25 #include "Pbk2UIFieldProperty.hrh"
       
    26 
       
    27 // FORWARD DECLARATIONS
       
    28 
       
    29 /**
       
    30  * Phonebook 2 UI field interface.
       
    31  *
       
    32  */
       
    33 class MPbk2UIField
       
    34     {
       
    35     public: // Interface
       
    36 
       
    37     	/**
       
    38          * Destructor
       
    39          *
       
    40          */
       
    41     	virtual ~MPbk2UIField(){};
       
    42     	
       
    43         /**
       
    44          * Returns the multiplicity information
       
    45          *
       
    46          * @return  Multiplicity property which tells that can
       
    47          *          there be several fields of this type in the contact.
       
    48          */
       
    49         virtual TPbk2FieldMultiplicity Multiplicity() const = 0;
       
    50 
       
    51         /**
       
    52          * Returns the maximum length of the field.
       
    53          *
       
    54          * @return  Static maximum length of the field. Note, that the
       
    55          *          contact store can have it's own limits.
       
    56          */
       
    57         virtual TInt MaxLength() const = 0;
       
    58 
       
    59         /**
       
    60          * Returns the editing mode for the field editor.
       
    61          *
       
    62          * @return  Field editing mode..
       
    63          */
       
    64         virtual TPbk2FieldEditMode EditMode() const = 0;
       
    65 
       
    66         /**
       
    67          * Returns the default character case for the field editor.
       
    68          *
       
    69          * @return  Default character case.
       
    70          */
       
    71         virtual TPbk2FieldDefaultCase DefaultCase() const = 0;
       
    72 
       
    73         /**
       
    74          * Returns the icon id for the field.
       
    75          *
       
    76          * @return  Icon id.
       
    77          */
       
    78         virtual const TPbk2IconId& IconId() const = 0;
       
    79 
       
    80         /**
       
    81          * Returns the type of the field editor.
       
    82          *
       
    83          * @return  Type of the field editor (text, date, number etc.).
       
    84          */
       
    85         virtual TPbk2FieldCtrlTypeExt CtrlType() const = 0;
       
    86 
       
    87         /**
       
    88          * Returns the field property flags defined in
       
    89          * Pbk2UIFieldProperty.hrh.
       
    90          *
       
    91          * @return  Field property flags.
       
    92          */
       
    93         virtual TUint Flags() const = 0;
       
    94         
       
    95         /**
       
    96          * Returns the field property order defined in
       
    97          * Pbk2UIFieldProperty.hrh.
       
    98          *
       
    99          * @return  Field property order.
       
   100          */
       
   101         virtual TPbk2FieldOrder Order() const = 0;
       
   102 
       
   103         /**
       
   104          * Returns the default label that should be used if the store
       
   105          * doesn't define a label.
       
   106          *
       
   107          * @return  Default label.
       
   108          */
       
   109         virtual const TDesC& DefaultLabel() const = 0;
       
   110 
       
   111         /**
       
   112          * Returns an extension point for this interface or NULL.
       
   113          *
       
   114          * @param aExtensionUid     Extension UID.
       
   115          * @return  Extension point.
       
   116          */
       
   117         virtual TAny* FieldExtension(
       
   118                 TUid /*aExtensionUid*/ )
       
   119             {
       
   120             return NULL;
       
   121             }
       
   122     };
       
   123 
       
   124 #endif /*MPBK2UIFIELD_H_*/
       
   125 
       
   126 // End of File