commsfwutils/commsbufs/mbufgobblerlayer/inc/mbufgobblerproviderselector.h
branchRCL_3
changeset 84 486e9e9c45a7
parent 76 576874e13a2c
child 85 7c25be0307fe
equal deleted inserted replaced
76:576874e13a2c 84:486e9e9c45a7
     1 // Copyright (c) 2010 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 // MbufGobbler selector. Used by the Tier Manager to select the access point below
       
    15 //  (management plane)
       
    16 //
       
    17 //
       
    18 //  This is a 3-plane comms layer implementation example, which has been customised to be a test layer which gobbles and releases ESOCK MBUFs.
       
    19 //  The MBuf gobbling functionality can be disabled by undefining the macro SYMBIAN_COMMSFW_MBUF_GOBBLER which is specified in mbufgobblerproviders.mmp.
       
    20 //  When SYMBIAN_COMMSFW_MBUF_GOBBLER is undefined, the source code specified by mbufgobblerproviders.mmp becomes a pass through layer i.e. it passes the data
       
    21 //  through to the layer above or below without altering it. This makes it useful as a starting point for implementing your own layers / providers;
       
    22 //  useful documentation on how to customise your own passthrough layer can be found in ..\docs\MbufGobblerLayer.doc
       
    23 //
       
    24 
       
    25 /**
       
    26  @file
       
    27  @internalComponent
       
    28 */
       
    29 
       
    30 #ifndef MBUFGOBBLERPROVIDERSELECTOR_H
       
    31 #define MBUFGOBBLERPROVIDERSELECTOR_H
       
    32 
       
    33 // INCLUDES
       
    34 #include <e32std.h>
       
    35 #include <e32base.h>
       
    36 
       
    37 #include <comms-infras/simpleselectorbase.h>
       
    38 
       
    39 // CLASS DECLARATION
       
    40 
       
    41 /**
       
    42  *  CMbufGobblerProviderSelector
       
    43  *  
       
    44  *  This is basically copied from other selector examples I culd find. Specifically I have used the
       
    45  *  CBtGenericProviderSelector as a template.
       
    46  * 
       
    47  */
       
    48 class CMbufGobblerProviderSelector : public CBase, private ASimpleSelectorBase
       
    49 	{
       
    50 public:
       
    51 	static ESock::MProviderSelector* NewL(const Meta::SMetaData& aSelectionPreferences);
       
    52 	
       
    53 private:
       
    54 	CMbufGobblerProviderSelector(const Meta::SMetaData& aSelectionPreferences);
       
    55 	~CMbufGobblerProviderSelector();
       
    56 	
       
    57 	// From MProviderSelector
       
    58 	virtual void SelectL(ESock::ISelectionNotify& aSelectionNotify);
       
    59 	virtual void Destroy();
       
    60 	
       
    61 	ESock::CMetaConnectionProviderBase* FindOrCreateProviderL(TUint aAccessPoint);
       
    62 	
       
    63 private:
       
    64 	ESock::TSelectionPrefs iSelectionPreferences;
       
    65 	TUint32 iTier;
       
    66 	};
       
    67 
       
    68 
       
    69 #endif // MBUFGOBBLERPROVIDERSELECTOR_H