sysstatemgmt/systemstatemgr/inc/ssmconditionalcallback.h
changeset 0 4e1aa6a622a0
equal deleted inserted replaced
-1:000000000000 0:4e1aa6a622a0
       
     1 // Copyright (c) 2007-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 //
       
    15 
       
    16 #ifndef __SSMCONDITIONALCALLBACK_H__
       
    17 #define __SSMCONDITIONALCALLBACK_H__
       
    18 
       
    19 #include <e32def.h>
       
    20 #include <barsc2.h>
       
    21 
       
    22 /**
       
    23 Callback used by CSsmCommandListResourceReader when a decision needs to be made
       
    24 on whether to include a command in a command list or not.
       
    25 
       
    26 @publishedPartner
       
    27 @released
       
    28 */
       
    29 class MSsmConditionalCallback
       
    30 	{
       
    31 public:
       
    32 	/**
       
    33 	 * Called by CSsmCommandListResourceReader to determine if a command should be added to a command list.
       
    34 	 *
       
    35 	 * Both the resource ID for the condition information and the resource file are provided.
       
    36 	 * This allows the conditional information at the resource ID to reference other resources
       
    37 	 * in the same resource file.
       
    38 	 * 
       
    39 	 * @param aResourceFile The resource file which contains the conditional information.
       
    40 	 * @param aResourceId The resource ID containing the conditional information.
       
    41 	 *  
       
    42 	 * @return ETrue if the command should be added to the list, EFalse if the command should not be added to the command list.
       
    43 	 * 
       
    44 	 * @publishedPartner
       
    45 	 * @released
       
    46 	 */
       
    47 	virtual TBool ConditionalCommandAllowedL(CResourceFile& aResourceFile, TInt aResourceId) = 0;
       
    48 	};
       
    49 
       
    50 #endif