WPILibC++ 2025.2.1
Loading...
Searching...
No Matches
wpi::StructDescriptorDatabase Class Reference

Database of raw struct dynamic descriptors. More...

#include <wpi/struct/DynamicStruct.h>

Public Member Functions

const StructDescriptorAdd (std::string_view name, std::string_view schema, std::string *err)
 Adds a structure schema to the database.
 
const StructDescriptorFind (std::string_view name) const
 Finds a structure in the database by name.
 

Detailed Description

Database of raw struct dynamic descriptors.

Member Function Documentation

◆ Add()

const StructDescriptor * wpi::StructDescriptorDatabase::Add ( std::string_view name,
std::string_view schema,
std::string * err )

Adds a structure schema to the database.

If the struct references other structs that have not yet been added, it will not be valid until those structs are also added.

Parameters
[in]namestructure name
[in]schemastructure schema
[out]errdetailed error, if nullptr is returned
Returns
Added struct, or nullptr on error

◆ Find()

const StructDescriptor * wpi::StructDescriptorDatabase::Find ( std::string_view name) const

Finds a structure in the database by name.

Parameters
namestructure name
Returns
struct descriptor, or nullptr if not found

The documentation for this class was generated from the following file: