SoNodekitCatalog(3)

πŸ“¦ version 2.5.0, in fedora 43, fedora 44

πŸ’– SoNodekitCatalog πŸ’– β€” the SoNodekitCatalog(3) manual page, but make it make sense

okay so bestie, real talk: this page is a big one, and we're doing it in two parts. part one starts right now, so grab your iced coffee and let's get into it ✨


🌸 NAME 🌸

SoNodekitCatalog β€” The SoNodekitCatalog class is a container for nodekit layouts. that's it, that's the whole vibe, it holds layouts πŸ’…


✨ SYNOPSIS ✨

first things first, you gotta let the compiler know you want in:

#include <Inventor/nodekits/SoNodekitCatalog.h>

🫢 Public Member Functions

ngl there are so many of these, and every single one is here, no skips, no cuts, the whole roster:

SoNodekitCatalog (void)
~SoNodekitCatalog ()
int getNumEntries (void) const
int getPartNumber (const SbName &name) const
const SbName & getName (int part) const
SoType getType (int part) const
SoType getType (const SbName &name) const
SoType getDefaultType (int part) const
SoType getDefaultType (const SbName &name) const
SbBool isNullByDefault (int part) const
SbBool isNullByDefault (const SbName &name) const
SbBool isLeaf (int part) const
SbBool isLeaf (const SbName &name) const
const SbName & getParentName (int part) const
const SbName & getParentName (const SbName &name) const
int getParentPartNumber (int part) const
int getParentPartNumber (const SbName &name) const
const SbName & getRightSiblingName (int part) const
const SbName & getRightSiblingName (const SbName &name) const
int getRightSiblingPartNumber (int part) const
int getRightSiblingPartNumber (const SbName &name) const
SbBool isList (int part) const
SbBool isList (const SbName &name) const
SoType getListContainerType (int part) const
SoType getListContainerType (const SbName &name) const
const SoTypeList & getListItemTypes (int part) const
const SoTypeList & getListItemTypes (const SbName &name) const
SbBool isPublic (int part) const
SbBool isPublic (const SbName &name) const
SoNodekitCatalog * clone (SoType type) const
SbBool addEntry (const SbName &name, SoType type, SoType defaulttype,
    SbBool isdefaultnull, const SbName &parent, const SbName
    &rightsibling, SbBool islist, SoType listcontainertype, SoType
    listitemtype, SbBool ispublic)
void addListItemType (int part, SoType type)
void addListItemType (const SbName &name, SoType type)
void narrowTypes (const SbName &name, SoType newtype, SoType
    newdefaulttype)
void setNullByDefault (const SbName &name, SbBool nullbydefault)
SbBool recursiveSearch (int part, const SbName &name, SoTypeList
    *checked) const
void printCheck (void) const

notice how basically every query comes in two flavours β€” one that takes an int part and one that takes a const SbName &name? that's not a coincidence bestie, that's the whole design, iykyk πŸ¦‹

🧚 Static Public Member Functions

just the one, and it's giving class-init energy:

static void initClass (void)

πŸ“– Detailed Description πŸ“–

SoNodekitCatalog is a container for nodekit layouts. periodt.

Nodekits keep all their hierarchical layout info and their part info tucked away inside instances of this class. like, that's the whole job. the catalog is the blueprint πŸ‘‘

See also: SoNodeKit, SoBaseKit


πŸŽ€ Constructor & Destructor Documentation πŸŽ€

SoNodekitCatalog::SoNodekitCatalog (void )

the constructor πŸ’–

Referenced by clone(), and recursiveSearch().

SoNodekitCatalog::~SoNodekitCatalog ()

the destructor. it cleans up after itself, as one does 🌸


okay so that's the top of the page, and there is so much more coming β€” the member function breakdowns are literally right there, don't you dare scroll away 🫢

πŸ’… Member Function Documentation πŸ’…

okay bestie, this is the part where we go function by function through the whole catalog API. it's a lot, but every single one of these is a little key to a little door in the nodekit catalog, and you're gonna know them all. let's go πŸ’–


void SoNodekitCatalog::initClass(void) [static]

Initialization of static variables. that's the whole job. she just wakes the static stuff up. ✨


int SoNodekitCatalog::getNumEntries(void) const

Returns the total number of entries in the catalog. like, how many parts live in here total. πŸŽ€

  • references: n/a
  • she's referenced by: addEntry(), SoBaseKit::createFieldList(), getDefaultType(), getListContainerType(), getListItemTypes(), getName(), getParentName(), getParentPartNumber(), getRightSiblingName(), getRightSiblingPartNumber(), getType(), isLeaf(), isList(), isPublic(), printCheck(), SoBaseKit::printSubDiagram(), SoBaseKit::printTable(), and recursiveSearch().

int SoNodekitCatalog::getPartNumber(const SbName & name) const

Hands you the part number in the catalog that matches name. If there's no part with that name, you get back SO_CATALOG_NAME_NOT_FOUND. no part, no number, no cap. πŸ¦‹

  • references: getPartNumber() (yes, herself, she's self-referential like that πŸ’€)
  • she's referenced by: addEntry(), SoBaseKit::countMyFields(), SoBaseKit::forceChildDrivenWriteRefs(), getDefaultType(), getListContainerType(), getListItemTypes(), getParentName(), getParentPartNumber(), getParentPartNumber(), getPartNumber(), getRightSiblingName(), getRightSiblingPartNumber(), getRightSiblingPartNumber(), getType(), isLeaf(), isList(), isNullByDefault(), isPublic(), narrowTypes(), SoBaseKit::printSubDiagram(), and setNullByDefault().

(not getParentPartNumber() and getRightSiblingPartNumber() each showing up twice β€” she's popular, it's giving main character energy πŸ‘‘)


const SbName & SoNodekitCatalog::getName(int part) const

Give her a part number, she gives you the name of that part. simple transaction. πŸ’…

  • references: getNumEntries()
  • she's referenced by: SoBaseKit::createFieldList(), SoBaseKit::getPartString(), SoBaseKit::printSubDiagram(), SoBaseKit::printTable(), recursiveSearch(), SoInteractionKit::setAnySurrogatePath(), and SoBaseKit::setPart().

SoType SoNodekitCatalog::getType(int part) const

Give her a part number, she gives you the type. πŸ”₯

  • references: getNumEntries()
  • she's referenced by: getType(), SoBaseKit::printSubDiagram(), SoBaseKit::printTable(), recursiveSearch(), and SoBaseKit::setPart().

SoType SoNodekitCatalog::getType(const SbName & name) const

Give her a name instead and she gives you the type. same energy, different lookup. ✨

  • references: getPartNumber(), and getType()

SoType SoNodekitCatalog::getDefaultType(int part) const

Given a part number, returns the default type of that part. what she is when nobody's told her otherwise. πŸŽ€

  • references: getNumEntries()
  • she's referenced by: getDefaultType(), and SoBaseKit::printTable().

SoType SoNodekitCatalog::getDefaultType(const SbName & name) const

Given a name, returns the default type of that part. πŸ’œ

  • references: getDefaultType(), and getPartNumber()

SbBool SoNodekitCatalog::isNullByDefault(int part) const

Returns TRUE if the part is empty by default, otherwise FALSE. yes queen, sometimes nothing is the whole personality. 🫢

  • references: n/a
  • she's referenced by: SoBaseKit::createDefaultParts(), isNullByDefault(), and SoBaseKit::setDefaultOnNonWritingFields().

SbBool SoNodekitCatalog::isNullByDefault(const SbName & name) const

Returns TRUE if the part name is empty by default, otherwise FALSE. 🌸

  • references: getPartNumber(), and isNullByDefault()

SbBool SoNodekitCatalog::isLeaf(int part) const

Returns TRUE if the part is not a parent for any other parts in the nodekit catalog. a leaf. no kids, just vibes. πŸ“

  • references: getNumEntries()
  • she's referenced by: SoBaseKit::createPathToAnyPart(), SoBaseKit::getAnyPart(), SoBaseKit::getPartString(), isLeaf(), SoBaseKit::readInstance(), SoInteractionKit::setAnySurrogatePath(), SoBaseKit::setDefaultOnNonWritingFields(), and SoInteractionKit::setDefaultOnNonWritingFields().

SbBool SoNodekitCatalog::isLeaf(const SbName & name) const

Returns TRUE if the part name is not a parent for any other parts in the nodekit catalog. 🌈

  • references: getPartNumber(), and isLeaf()

const SbName & SoNodekitCatalog::getParentName(int part) const

Returns the name of the parent of the part. If that part doesn't have a parent, you get back the empty string. orphan behavior, honestly relatable 😭

  • references: getNumEntries()
  • she's referenced by: getParentName(), and SoBaseKit::printSubDiagram().

const SbName & SoNodekitCatalog::getParentName(const SbName & name) const

Returns the name of the parent of the part. If name doesn't have a parent, the empty string is returned. πŸ’–

  • references: getParentName(), and getPartNumber()

int SoNodekitCatalog::getParentPartNumber(int part) const

Returns the part number of the given part's parent. If the part doesn't have a parent, you get SO_CATALOG_NAME_NOT_FOUND. πŸ¦‹

  • references: getNumEntries(), and getPartNumber()
  • she's referenced by: getParentPartNumber(), SoInteractionKit::setAnySurrogatePath(), and SoBaseKit::setPart().

int SoNodekitCatalog::getParentPartNumber(const SbName & name) const

Returns the part number of the given part's parent. If name doesn't have a parent, SO_CATALOG_NAME_NOT_FOUND is returned. πŸ’œ

  • references: getParentPartNumber(), and getPartNumber()

const SbName & SoNodekitCatalog::getRightSiblingName(int part) const

Returns the name of the right sibling of the part. If the part doesn't have a right sibling, you get the empty string. only child moment πŸ™ˆ

  • references: getNumEntries()
  • she's referenced by: getRightSiblingName()

const SbName & SoNodekitCatalog::getRightSiblingName(const SbName & name) const

Returns the name of the sibling of the part. If name doesn't have a right sibling, the empty string is returned. 🌸

  • references: getPartNumber(), and getRightSiblingName()

int SoNodekitCatalog::getRightSiblingPartNumber(int part) const

Returns the part number of the given part's sibling. Returns SO_CATALOG_NAME_NOT_FOUND if the part doesn't have a right sibling. πŸŽ€

  • references: getNumEntries(), and getPartNumber()
  • she's referenced by: getRightSiblingPartNumber()

int SoNodekitCatalog::getRightSiblingPartNumber(const SbName & name) const

Returns the part number of the given part's right sibling. Returns SO_CATALOG_NAME_NOT_FOUND if the part doesn't have a right sibling. ✨

  • references: getPartNumber(), and getRightSiblingPartNumber()

SbBool SoNodekitCatalog::isList(int part) const

Returns TRUE if the given part is a list container. πŸ”₯

  • references: getNumEntries()
  • she's referenced by: isList(), and SoBaseKit::printTable().

SbBool SoNodekitCatalog::isList(const SbName & name) const

Returns TRUE if the given part is a list container. same question, name flavor. πŸ’…

  • references: getPartNumber(), and isList()

SoType SoNodekitCatalog::getListContainerType(int part) const

Returns the type of the list container (SoGroup, SoSeparator, SoSwitch, etc) that the part is. πŸ¦‹

  • references: getNumEntries()
  • she's referenced by: getListContainerType()

SoType SoNodekitCatalog::getListContainerType(const SbName & name) const

Returns the type of the list container (SoGroup, SoSeparator, SoSwitch, etc) that the named part is. 🌈

  • references: getListContainerType(), and getPartNumber()

const SoTypeList & SoNodekitCatalog::getListItemTypes(int part) const

Returns the list of node types that are allowed to be children of the list container part. the guest list, basically. πŸ‘‘

  • references: getNumEntries()
  • she's referenced by: getListItemTypes(), and SoBaseKit::printTable().

const SoTypeList & SoNodekitCatalog::getListItemTypes(const SbName & name) const

Returns the list of node types that are allowed to be children of the named list container part. πŸŽ€

  • references: getListItemTypes(), and getPartNumber()

SbBool SoNodekitCatalog::isPublic(int part) const

Returns TRUE if the part is visible and publicly available for queries and modifications, FALSE if the part is hidden. private account vs public account, we all know the difference πŸ’œ

  • references: getNumEntries()
  • she's referenced by: SoBaseKit::createPathToAnyPart(), SoBaseKit::getAnyPart(), isPublic(), SoBaseKit::printTable(), SoBaseKit::setAnyPart(), and SoInteractionKit::setAnySurrogatePath().

SbBool SoNodekitCatalog::isPublic(const SbName & name) const

Returns TRUE if the part is visible and publicly available for queries and modifications, FALSE if it's hidden. 🌸

  • references: getPartNumber(), and isPublic()

SoNodekitCatalog * SoNodekitCatalog::clone(SoType type) const

Returns a clone of this catalog. type will be used to set the type and defaulttype values of the toplevel this entry. copy-paste but make it official ✨

  • references: SbList< Type >::append(), and SoNodekitCatalog()

SbBool SoNodekitCatalog::addEntry(...)

SbBool SoNodekitCatalog::addEntry (const SbName & name, SoType type, SoType defaulttype, SbBool isdefaultnull, const SbName & parentname, const SbName & rightsiblingname, SbBool islist, SoType listcontainertype, SoType listitemtype, SbBool ispublic)

Adds a new entry to the catalog. Returns TRUE if the add was ok. so many params but she handles them all, no problem. πŸ’…

  • references: SoTypeList::append(), SoType::badType(), getNumEntries(), getPartNumber(), SbName::getString(), and SoDebugError::postInfo()

void SoNodekitCatalog::addListItemType(int part, SoType type)

Adds another allowable type for the given part. part must of course be a list container item. obviously. πŸ™ˆ

  • references: addListItemType()
  • she's referenced by: addListItemType(), and addListItemType().

void SoNodekitCatalog::addListItemType(const SbName & name, SoType type)

Adds another allowable type for the name part. The part must of course be a list container. πŸ¦‹

  • references: addListItemType(), SbName::getString(), and SoDebugError::post()

void SoNodekitCatalog::narrowTypes(const SbName & name, SoType newtype, SoType newdefaulttype)

Sets the type and default type of a part to be subtypes of the old types. Useful for "narrowing" the specification of a nodekit which inherits the catalog of a more generic nodekit superclass. glow-up but for type declarations πŸ’–

  • references: getPartNumber(), and SoType::isDerivedFrom()

void SoNodekitCatalog::setNullByDefault(const SbName & name, SbBool nullbydefault)

Changes whether or not the part with the given name is created by default. πŸŽ€

  • references: getPartNumber()

SbBool SoNodekitCatalog::recursiveSearch(int part, const SbName & name, SoTypeList * checked) const

Recursively searches the part number in the catalog for the name part. πŸ”

The checked SoTypeList is just used as a placeholder to remember which nodekit class catalogs have already been scanned (or are being scanned) during the recursion. You should normally just pass in an empty list.

bestie listen: don't get cute with that checked list. empty list, every time, unless you genuinely know what you're doing. 🫢
  • references: SoTypeList::append(), SoType::createInstance(), SoTypeList::find(), getName(), SoBaseKit::getNodekitCatalog(), getNumEntries(), getType(), SoType::isDerivedFrom(), recursiveSearch(), SoBase::ref(), SoNodekitCatalog(), and SoBase::unref()
  • she's referenced by: recursiveSearch()

void SoNodekitCatalog::printCheck(void) const

Lists all catalog parts, which is useful for debugging. she ate that, honestly πŸ”₯

  • references: SoType::badType(), SbPList::getLength(), SoType::getName(), getNumEntries(), and SbName::getString()

🌟 Author 🌟

Generated automatically by Doxygen for Coin from the source code. not a human author, just the machine doing its little thing, and we respect the machine's hustle πŸ€–πŸ’–


okay bestie that's the whole page!! this was Coin Version 2.5.0, page SoNodekitCatalog(3), and you made it all the way to the end which means you now know every single function in this catalog. iconic behavior. go build something cute with your nodekits πŸ’…πŸŽ€βœ¨

πŸ“¦ where this page comes from