Memory Handler Base Class for Memory Handler Base Class. This class`s methods can called only from MemHandle.(Cannot call this class directory.)
More...
#include <MemHandleBase.h>
|
| MemHandleBase (PoolId id, size_t size_for_check) |
|
| MemHandleBase (uint8_t id, size_t size_for_check) |
|
| MemHandleBase (const MemHandleBase &mh) |
|
MemHandleBase & | operator= (const MemHandleBase &mh) |
|
err_t | allocSeg (PoolId id, size_t size_for_check) |
|
err_t | allocSeg (uint8_t id, size_t size_for_check) |
|
void | freeSeg () |
|
bool | isAvail () const |
|
bool | isNull () const |
|
bool | isSame (const MemHandleBase &mh) |
|
PoolId | getPoolId () const |
|
NumSeg | getSegNo () const |
|
uint8_t | getFlags () const |
|
PoolAddr | getAddr () const |
|
PoolSize | getSize () const |
|
SegRefCnt | getRefCnt () const |
|
Memory Handler Base Class for Memory Handler Base Class. This class`s methods can called only from MemHandle.(Cannot call this class directory.)
◆ allocSeg()
err_t allocSeg |
( |
PoolId |
id, |
|
|
size_t |
size_for_check |
|
) |
| |
The allocator from a pool area for MemHandle.
- Parameters
-
[in] | id | The pool id that MemHandle be allocated. |
[in] | size_for_check | The size the user wants.(for only size check.) |
- Returns
- ERR_OK : success
-
ERR_DATA_SIZE : error, size is over segment size
-
ERR_MEM_EMPTY : error, there are no segments available
◆ freeSeg()
The free from a pool area for MemHandle.
- Returns
- void (If this handler did not allocate, this method do nothing.)
The documentation for this class was generated from the following file: