photosgallery/viewframework/dataprovider/inc/glxmedialistmulmodelprovider.h
changeset 0 4e91876724a2
child 1 9ba538e329bd
equal deleted inserted replaced
-1:000000000000 0:4e91876724a2
       
     1 /*
       
     2 * Copyright (c) 2008-2009 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:    Implementation class for Medialist Access for Data
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 
       
    21 #ifndef _GLXMEDIALISTMULMODELPROVIDER_H_
       
    22 #define _GLXMEDIALISTMULMODELPROVIDER_H_
       
    23 
       
    24 #include <e32base.h>                        // Container Base Class
       
    25 #include <mul/imulwidget.h>
       
    26 
       
    27 // Forward declarations
       
    28 class CAlfEnv;                              // This is the UI Accelerator Toolkit environment object
       
    29 class MGlxMediaList;                        // Interface for reading lists of media items
       
    30 class TGlxMulBindingSetFactory;             // Create binding set
       
    31 class CGlxMediaListMulModelProviderImpl;    // Actual implemntation for providign the data to the clients is done here
       
    32 
       
    33 /**
       
    34 * CGlxMediaListMulModelProvider is the provider class which provides data for 
       
    35 * list view, grid view. 
       
    36 * This doesnt have any implementaiton.
       
    37 * This actual implementaion is provided in CGlxMediaListMulModelProviderImpl
       
    38 */
       
    39 NONSHARABLE_CLASS( CGlxMediaListMulModelProvider ) : public CBase
       
    40     {
       
    41 public:
       
    42 	/**
       
    43 	* The client uses this API to create the provider
       
    44 	* @param aEnv The Alf Environment
       
    45 	* @param aWidget The widget being used by client for which the model has to be set
       
    46 	* @param aMediaList The instance of medialist which provides data for the model
       
    47 	* @param aFactory The instance of the bindingset factory 
       
    48 	* @param aDefaultTemplate The template that is being used for the widget.
       
    49 	*/
       
    50     IMPORT_C static CGlxMediaListMulModelProvider* NewL( CAlfEnv& aEnv, 
       
    51 											Alf::IMulWidget& aWidget, 
       
    52 											MGlxMediaList& aMediaList, 
       
    53 											const TGlxMulBindingSetFactory& aFactory, 
       
    54 											Alf::mulwidget::TLogicalTemplate aDefaultTemplate,
       
    55 											TInt aDataWindowSize );
       
    56     /**
       
    57 	* Destructor
       
    58 	*/            
       
    59     IMPORT_C ~CGlxMediaListMulModelProvider();
       
    60 
       
    61 private:
       
    62     CGlxMediaListMulModelProvider();
       
    63     
       
    64     /** ConstructL
       
    65 	* @param aEnv Env variable of ALF
       
    66  	* @param aWidget Alf Widget type
       
    67  	* @param aMediaList medialist from which attributes to be fetched
       
    68  	* @param aDefaultTemplate Template that will be set to model
       
    69  	*/
       
    70     void ConstructL(CAlfEnv& aEnv, 
       
    71 					Alf::IMulWidget& aWidget, 
       
    72 					MGlxMediaList& aMediaList,
       
    73 					const TGlxMulBindingSetFactory& aFactory, 
       
    74 					Alf::mulwidget::TLogicalTemplate aDefaultTemplate,
       
    75 					TInt aDataWindowSize );
       
    76 
       
    77 	// The implementaion APIs of CGlxMediaListMulModelProviderImpl 
       
    78 	// have to be called: owns
       
    79     CGlxMediaListMulModelProviderImpl* iImpl;
       
    80     };
       
    81     
       
    82 #endif // _GLXMEDIALISTMULMODELPROVIDER_H_
       
    83