make project functions const where appropriate

Signed-off-by: Folling <mail@folling.io>
This commit is contained in:
Folling 2024-01-30 09:34:13 +01:00 committed by Folling
parent 9ff3d1720f
commit 0ace4243cf
No known key found for this signature in database

View file

@ -89,7 +89,7 @@ IKA_API char const * ikarus_project_get_path(IkarusProject const * project, Ikar
/// \param entities_out_size The size of the buffer. /// \param entities_out_size The size of the buffer.
/// \param error_out \see errors.h /// \param error_out \see errors.h
IKA_API void ikarus_project_get_entities( IKA_API void ikarus_project_get_entities(
IkarusProject * project, IkarusProject const * project,
struct IkarusEntity ** entities_out, struct IkarusEntity ** entities_out,
size_t entities_out_size, size_t entities_out_size,
IkarusErrorData * error_out IkarusErrorData * error_out
@ -101,7 +101,7 @@ IKA_API void ikarus_project_get_entities(
/// \pre \li Must exist. /// \pre \li Must exist.
/// \param error_out \see errors.h /// \param error_out \see errors.h
/// \return The number of entities or undefined if an error occurs. /// \return The number of entities or undefined if an error occurs.
IKA_API size_t ikarus_project_get_entity_count(IkarusProject * project, IkarusErrorData * error_out); IKA_API size_t ikarus_project_get_entity_count(IkarusProject const * project, IkarusErrorData * error_out);
/// \brief Gets the blueprints of a project. /// \brief Gets the blueprints of a project.
/// \param project The project to get the blueprints of. /// \param project The project to get the blueprints of.
@ -112,7 +112,7 @@ IKA_API size_t ikarus_project_get_entity_count(IkarusProject * project, IkarusEr
/// \param blueprints_out_size The size of the buffer. /// \param blueprints_out_size The size of the buffer.
/// \param error_out \see errors.h /// \param error_out \see errors.h
IKA_API void ikarus_project_get_blueprints( IKA_API void ikarus_project_get_blueprints(
IkarusProject * project, IkarusProject const * project,
struct IkarusBlueprint ** blueprints_out, struct IkarusBlueprint ** blueprints_out,
size_t blueprints_out_size, size_t blueprints_out_size,
IkarusErrorData * error_out IkarusErrorData * error_out
@ -135,11 +135,7 @@ IKA_API size_t ikarus_project_get_blueprint_count(IkarusProject const * project,
/// \pre \li Must not be empty. /// \pre \li Must not be empty.
/// \param error_out \see errors.h /// \param error_out \see errors.h
/// \return The entity with the given name or null if none was found. /// \return The entity with the given name or null if none was found.
IKA_API struct IkarusEntity* get_entity_by_name( IKA_API struct IkarusEntity * get_entity_by_name(IkarusProject const * project, char const * name, IkarusErrorData * error_out);
IkarusProject const * project,
char const * name,
IkarusErrorData * error_out
);
/// \brief Finds a property by a given name. /// \brief Finds a property by a given name.
/// \param project The project to search. /// \param project The project to search.