blob: 0dad793ec23077af2d8eb56496090d3175d0fb80 [file] [log] [blame]
anjana_sreekumar@infosys.com991c2062020-01-08 11:42:57 +05301 /*
2 * Copyright 2019-present Infosys Limited
3 *
4 * SPDX-License-Identifier: Apache-2.0
5 */
6/******************************************************************************
7 * sessionContextManager.cpp
8 * This is an auto generated file.
9 * Please do not edit this file.
10 * All edits to be made through template source file
11 * <TOP-DIR/scripts/SMCodeGen/templates/ctxtManagerTmpls/blockPoolManager.cpp.tt>
12 ******************************************************************************/
13
14#include "memPoolManager.h"
15#include "contextManager/dataBlocks.h"
16#include "contextManager/sessionContextManager.h"
17
18using namespace cmn::memPool;
19
20namespace mme
21{
22 /******************************************************************************
23 * Constructor
24 ******************************************************************************/
25 SessionContextManager::SessionContextManager(int numOfBlocks):poolManager_m(numOfBlocks)
26 {
27 }
28
29 /******************************************************************************
30 * Destructor
31 ******************************************************************************/
32 SessionContextManager::~SessionContextManager()
33 {
34 }
35
36 /******************************************************************************
37 * Allocate SessionContext data block
38 ******************************************************************************/
39 SessionContext* SessionContextManager::allocateSessionContext()
40 {
41 SessionContext* SessionContext_p = poolManager_m.allocate();
42 return SessionContext_p;
43 }
44
45 /******************************************************************************
46 * Deallocate a SessionContext data block
47 ******************************************************************************/
48 void SessionContextManager::deallocateSessionContext(SessionContext* SessionContextp )
49 {
50 poolManager_m.free( SessionContextp );
51 }
52}