673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
|
*
* It will be freed automatically when the object is deallocated.
*
* @param size The size of the memory to allocate
* @return A pointer to the allocated memory. May return NULL if the specified
* size is 0.
*/
- (nullable void *)allocMemoryWithSize: (size_t)size;
/*!
* @brief Allocates memory for the specified number of items and stores it in
* the object's memory pool.
*
* It will be freed automatically when the object is deallocated.
*
* @param size The size of each item to allocate
* @param count The number of items to allocate
* @return A pointer to the allocated memory. May return NULL if the specified
* size or count is 0.
*/
- (nullable void *)allocMemoryWithSize: (size_t)size
count: (size_t)count;
/*!
* @brief Resizes memory in the object's memory pool to the specified size.
*
* If the pointer is NULL, this is equivalent to allocating memory.
* If the size is 0, this is equivalent to freeing memory.
*
|
|
|
|
|
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
|
*
* It will be freed automatically when the object is deallocated.
*
* @param size The size of the memory to allocate
* @return A pointer to the allocated memory. May return NULL if the specified
* size is 0.
*/
- (void *)allocMemoryWithSize: (size_t)size;
/*!
* @brief Allocates memory for the specified number of items and stores it in
* the object's memory pool.
*
* It will be freed automatically when the object is deallocated.
*
* @param size The size of each item to allocate
* @param count The number of items to allocate
* @return A pointer to the allocated memory. May return NULL if the specified
* size or count is 0.
*/
- (void *)allocMemoryWithSize: (size_t)size
count: (size_t)count;
/*!
* @brief Resizes memory in the object's memory pool to the specified size.
*
* If the pointer is NULL, this is equivalent to allocating memory.
* If the size is 0, this is equivalent to freeing memory.
*
|