object: add a type for storing, parsing, and stringifying date/time values

This commit is contained in:
2025-09-22 10:44:56 +01:00
parent 2fcadf7f39
commit 16b68b6fba
4 changed files with 556 additions and 0 deletions

17
object/datetime.h Normal file
View File

@@ -0,0 +1,17 @@
#ifndef _BLUELIB_DATETIME_H_
#define _BLUELIB_DATETIME_H_
#include "object.h"
struct b_datetime {
struct b_object dt_base;
unsigned int dt_year, dt_month, dt_day;
unsigned short dt_hour, dt_min, dt_sec;
unsigned int dt_msec;
bool dt_has_date, dt_has_time, dt_localtime;
unsigned short dt_zone_offset_hour, dt_zone_offset_minute;
bool dt_zone_offset_negative;
};
#endif