appfw/apparchitecture/inc/ApSidChecker.h
changeset 0 2e3d3ce01487
equal deleted inserted replaced
-1:000000000000 0:2e3d3ce01487
       
     1 // Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 // apsidchecker.h
       
    15 //
       
    16 
       
    17 #ifndef __APSIDCHECKER_H__
       
    18 #define __APSIDCHECKER_H__
       
    19 
       
    20 #include <e32base.h>
       
    21 #include <e32hashtab.h>
       
    22 class TDriveUnit;
       
    23 
       
    24 /** Sid checker.
       
    25 
       
    26 This is a plugin interface for checking whether a Sid should be
       
    27 included in apparc server's list of registered applications.
       
    28 
       
    29 An instance of the CAppSidChecker is used to verify that an application
       
    30 may be included in application list.
       
    31 There should be one implementation of this
       
    32 interface for each application type (native, java midlet, ...)
       
    33 
       
    34 @publishedPartner */
       
    35 class CAppSidChecker : public CBase
       
    36 	{
       
    37 public:
       
    38 	// Wraps ECom object instantiation
       
    39 	static CAppSidChecker* CheckerForAppType(TUid aAppTypeUid);
       
    40 	IMPORT_C virtual ~CAppSidChecker();
       
    41 public:
       
    42 	IMPORT_C virtual TBool AppRegisteredAt(const TUid& aSid, TDriveUnit aDrive) = 0;
       
    43 	IMPORT_C virtual void SetRescanCallBackL(const TCallBack &aCallback);
       
    44 private: // Reserved. Do not override!
       
    45 	IMPORT_C virtual void reserved1();
       
    46 	IMPORT_C virtual void reserved2();
       
    47 	IMPORT_C virtual void reserved3();
       
    48 private:
       
    49 	/** ECOM identifier */
       
    50 	TUid iDtor_ID_Key;
       
    51 	TInt iSpare[3];
       
    52 	};
       
    53 
       
    54 #ifndef SYMBIAN_ENABLE_SPLIT_HEADERS
       
    55 
       
    56 /** Sid checker map
       
    57  
       
    58  This Maps application type uids to Instances of the CAppSidChecker interface,
       
    59  loading them if neccessary.
       
    60  
       
    61  @internalComponent */
       
    62  NONSHARABLE_CLASS(RSidCheckerMap) : public RHashMap<TUint,CAppSidChecker*>
       
    63  	{
       
    64  public:	
       
    65  	RSidCheckerMap( TCallBack aRescanCallBack );
       
    66  	
       
    67  	CAppSidChecker& FindSidCheckerL(TUid aAppType);
       
    68  	void Close(); //lint !e1511 Member hides non-virtual member
       
    69  private:
       
    70  	TCallBack iRescanCallBack;
       
    71  	};
       
    72 
       
    73 #endif //SYMBIAN_ENABLE_SPLIT_HEADERS
       
    74 
       
    75 #endif	// __APSIDCHECKER_H__
       
    76