chore: format internal header files

This commit is contained in:
Jef Roosens 2023-02-02 16:14:26 +01:00 committed by Chewing_Bever
parent 53eb5c1784
commit 8668148e96
Signed by: Jef Roosens
GPG key ID: B75D4F293C7052DB
4 changed files with 38 additions and 14 deletions

View file

@ -1,9 +1,9 @@
#ifndef VIETER_JOB_QUEUE
#define VIETER_JOB_QUEUE
#include <stdint.h>
#include <stdbool.h>
#include "vieter_cron.h"
#include <stdbool.h>
#include <stdint.h>
/*
* The order of these do not imply that they happen in this order. New states
@ -12,21 +12,29 @@
* other things.
*/
typedef enum vieter_job_state {
vieter_job_queued = 0,
vieter_job_dispatched = 1,
vieter_job_finished = 2
vieter_job_state_queued = 0,
vieter_job_state_ready = 1,
vieter_job_state_build_finished = 2
} vieter_job_state;
// This macro should be kept in sync with the above enum
#define VIETER_JOB_STATES 3
typedef struct vieter_job {
int id;
uint64_t next_scheduled_time;
vieter_cron_expression *ce;
bool single;
vieter_job_state state;
uint64_t state_transition_times[VIETER_JOB_STATES];
int id;
uint64_t next_scheduled_time;
vieter_cron_expression *ce;
bool single;
vieter_job_state state;
uint64_t state_transition_times[VIETER_JOB_STATES];
bool dispatched;
void *build_config;
} vieter_job;
typedef struct vieter_job_queue vieter_job_queue;
vieter_job_queue *vieter_job_queue_init();
void vieter_job_queue_insert(int id);
#endif