diff --git a/wpiutil/src/main/native/cpp/DataLog.cpp b/wpiutil/src/main/native/cpp/DataLog.cpp index 40dab2a1b59..af28dbc81c9 100644 --- a/wpiutil/src/main/native/cpp/DataLog.cpp +++ b/wpiutil/src/main/native/cpp/DataLog.cpp @@ -1205,4 +1205,18 @@ void WPI_DataLog_AppendStringArray(struct WPI_DataLog* datalog, int entry, timestamp); } +void WPI_DataLog_AddSchemaString(struct WPI_DataLog* datalog, int entry, + const char* name, const char* type, + const char* schema, int64_t timestamp) { + reinterpret_cast(datalog)->AddSchema(name, type, schema, timestamp); +} + +void WPI_DataLog_AddSchema(struct WPI_DataLog* datalog, int entry, + const char* name, const char* type, + const uint8_t* schema, size_t schema_len, + int64_t timestamp) { + reinterpret_cast(datalog)->AddSchema( + name, type, std::span{schema, schema_len}, timestamp); +} + } // extern "C" diff --git a/wpiutil/src/main/native/include/wpi/DataLog.h b/wpiutil/src/main/native/include/wpi/DataLog.h index 2f79a3a17b1..35aea0b71b0 100644 --- a/wpiutil/src/main/native/include/wpi/DataLog.h +++ b/wpiutil/src/main/native/include/wpi/DataLog.h @@ -1373,6 +1373,15 @@ void WPI_DataLog_AppendStringArray(struct WPI_DataLog* datalog, int entry, const WPI_DataLog_String* arr, size_t len, int64_t timestamp); +void WPI_DataLog_AddSchemaString(struct WPI_DataLog* datalog, int entry, + const char* name, const char* type, + const char* schema, int64_t timestamp); + +void WPI_DataLog_AddSchema(struct WPI_DataLog* datalog, int entry, + const char* name, const char* type, + const uint8_t* schema, size_t schema_len, + int64_t timestamp); + #ifdef __cplusplus } // extern "C" #endif // __cplusplus