SBPLIST(3iv)
π SbPList(3IV) π
okay bestie, we're in the SbPList(3IV) manual page and it's giving pointer wrangler energy, so let's get into it π«Ά
β¨ NAME β¨
SbPList β a list of generic void * pointers. that's it. that's the whole vibe. a little roster of mystery pointers, living their best lives.
πΈ INHERITS FROM πΈ
SbPList
no cap, it just inherits from itself. iconic behavior honestly. π
π¦ SYNOPSIS π¦
first things first, you gotta pull it in:
#include <Inventor/SbPList.h>
and here's the whole method roster, exactly as written, no edits, no notes:
Methods from class SbPList:
SbPList()
SbPList(const SbPList &pl)
SbPList(int initSize)
~SbPList()
void append(void * ptr)
int find(const void *ptr) const
void insert(void *ptr, int addBefore)
void remove(int which)
int getLength() const
void truncate(int start)
void copy(const SbPList &pl)
SbPList & operator =(const SbPList &pl)
void *& operator [](int i) const
int operator ==(const SbPList &pl) const
int operator !=(const SbPList &pl) const
π DESCRIPTION π
so like, this class manages a dynamic list of generic void * pointers. and the way that it lets you do random access, insertion, and removal?? obsessed. it's a whole flexible situation. π
π METHODS π
the constructors + destructor era β¨
SbPList()
SbPList(const SbPList &pl)
SbPList(int initSize)
~SbPList()
okay so these are your constructors and your destructor, the whole life cycle. πΌ
initSizesets an initial size for the list, and ngl that's genuinely useful as an optimization if you can estimate how long the list is gonna be before you even construct it. foresight queen. π- and if you hand it another
SbPList, it gives you back a copy of that list. twin. matching. π«Ά
the rest of the squad π§
void append(void * ptr)β adds the given pointer to the end of the list. go to the back of the line bestie, respectfully. πΆββοΈint find(const void *ptr) constβ hunts down the given pointer and returns its index in the list. and if it's not there? returns-1. she's not ghosting you, she's just not in this list. πvoid insert(void *ptr, int addBefore)β inserts the given pointer into the list before the pointer with the given index. cutting the line, but make it legal. πvoid remove(int which)β removes the pointer with the given index. bye bye, we hardly knew ye. πint getLength() constβ returns the number of pointers in the list. the headcount. the census. πvoid truncate(int start)β removes all pointers after the one with the given index, inclusive. so like, that pointer atstart? gone too. everything after it? also gone. it's a chop, not a trim. βοΈvoid copy(const SbPList &pl)β copies a list. straightforward, no drama, we love a simple queen. πSbPList & operator =(const SbPList &pl)β the assignment operator; it copies the list into this list. you are what you absorb or whatever. β¨void *& operator [](int i) constβ returns the pointer with the given index. random access unlocked, bestie. πint operator ==(const SbPList &pl) constint operator !=(const SbPList &pl) const
β the equality and inequality operators. are they the same? are they not?? find out. π
π pro tip from your girl:truncate(int start)is inclusive, meaning the pointer atstartgets removed too. read it twice, screenshot it, tattoo it. iykyk. π
and that's the whole page bestie!! this was SbPList(3IV) from the SbPList(3IV)() manual, section 3IV, source/version SbPList(3IV)() β literally all of it, slay. go forth and manage your void * pointers responsibly. πβ¨π¦πΈππ«Άππβπ
π¦ where this page comes from
- debian bookworm: inventor-doc 2.1.5-10+dfsg-2 Β· LGPL-2.0-or-later
- debian trixie: inventor-doc 2.1.6+ds-2 Β· LGPL-2.0-or-later
- ubuntu jammy: inventor-doc 2.1.5-10-24
- ubuntu noble: inventor-doc 2.1.5-10+dfsg-2.1build2 Β· LGPL-2.0-or-later
- ubuntu questing: inventor-doc 2.1.6+ds-2
- ubuntu resolute: inventor-doc 2.1.6.1+ds-1 Β· LGPL-2.0-or-later
- ubuntu stonking: inventor-doc 2.1.6.1+ds-1 Β· LGPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms