commsfwutils/commsbufs/mbufmgrimpl/inc/MBufMemoryManager.h
changeset 0 dfb7c4ff071f
equal deleted inserted replaced
-1:000000000000 0:dfb7c4ff071f
       
     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 // Buffer Manager for Protocols - Memory Allocation
       
    15 // 
       
    16 //
       
    17 
       
    18 /**
       
    19 @file
       
    20 @internalTechnology
       
    21 
       
    22 Buffer Manager for Protocols - Memory Allocation
       
    23 */
       
    24 
       
    25 #ifndef MBUFMEMORYMANAGER_H_
       
    26 #define MBUFMEMORYMANAGER_H_
       
    27 
       
    28 // The allocation or real memory for a CMBufPool
       
    29 NONSHARABLE_CLASS(CMBufMemoryManager) : public CBase
       
    30 	{
       
    31 public:
       
    32 	static CMBufMemoryManager* NewL(TInt aMaxHeapSize);
       
    33 	~CMBufMemoryManager();
       
    34 	
       
    35 	TAny* Alloc(TInt aSize);
       
    36 	void Free(TAny* aPtr);
       
    37 	TInt AllocBytes();
       
    38 
       
    39 private:
       
    40 
       
    41 	CMBufMemoryManager();
       
    42 	void ConstructL(TInt aMaxHeapSize);
       
    43 
       
    44 	RHeap* iHeap;
       
    45 	TUint iLogger;			// alternative to __FLOG_DECLARATION_MEMBER, refer MBuf_Log.h notes
       
    46 
       
    47 	};
       
    48 
       
    49 
       
    50 #endif /*MBUFMEMORYMANAGER_H_*/