ost::StackPager(3)
πΈ ost::StackPager(3) β Library Functions Manual πΈ
okay bestie, pull up a chair, we're doing a whole manual page and it's lowkey a fun one. this is from the Library Functions Manual, it's ost::StackPager(3), and it's giving organized-teen-with-a-label-maker energy. let's GO π
β¨ NAME β¨
ost::StackPager β the StackPager provides a repository to stash and retrieve working data in last-in-first-out order. it's a stack, bestie. last one in is the first one out. iconic behavior honestly π
π¦ SYNOPSIS π¦
#include <misc.h>
Inherits ost::MemPager. yes queen, it's a mempager underneath, we'll get to why that slays in a sec β¨
π Public Member Functions π
StackPager(size_t pagesize)β Create a lifo pager as a mempager.void * push(const void *object, size_t size)β Push an arbitrary object onto the stack.void * push(const char *string)β Push a string onto the stack.void * pull(void)β Retrieve next object from stack.void purge(void)β Purge the stack of all objects and memory allocations.
π§ Additional Inherited Members
(that's it, that's the section β the inherited goodies live over in the parent, ost::MemPager, iykyk π)
π Detailed Description π
The StackPager provides a repository to stash and retrieve working data in last-in-first-out order. no cap.
the way that it uses a mempager to support its operation means you can store arbitrary sized objects with no fixed limit β which is honestly the moment, fr fr π
Author
David Sugar dyfet@ostel.com
last in first out object pager. periodt. π
π Constructor & Destructor Documentation π
ost::StackPager::StackPager(size_t pagesize)
Create a lifo pager as a mempager.
Parameters
- pagesize for memory allocation
π Member Function Documentation π
void* ost::StackPager::pull(void)
Retrieve next object from stack.
Returns
- object.
void ost::StackPager::purge(void)
Purge the stack of all objects and memory allocations.
bestie this one nukes everything β all the objects and the memory allocations. full reset, no survivors, main character energy π
void* ost::StackPager::push(const char *string)
Push a string onto the stack.
Returns
- stack memory location.
Parameters
- string pointer.
void* ost::StackPager::push(const void *object, size_t size)
Push an arbitrary object onto the stack.
Returns
- stack memory location.
Parameters
- object pointer to data
- size of data.
πΈ Author πΈ
Generated automatically by Doxygen for GNU CommonC++ from the source code.
and that's the whole vibe check, bestie β this page was brought to you by GNU CommonC++, dated Sun Dec 27 2020. mwah, slay, go build something cute π«Άβ¨π
π¦ where this page comes from
- ubuntu jammy: libcommoncpp2-doc 1.8.1-10
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms