12 #ifndef OSURS_OPTIMIZE_H_
13 #define OSURS_OPTIMIZE_H_
81 int space_available(
unsigned int res_arr[],
int res_count,
int segment_count,
82 unsigned int seat_count,
unsigned int new_res);
98 int res_ids[],
int segment_count,
99 int seat_ids[],
int seat_count);
void seat_add_reservation(Seat *seat, int res_id)
Adds a new reservation to the seat.
Definition: optimize.c:22
SeatCollection * optimize_reservation(unsigned int res_arr[], int res_arr_count, int res_ids[], int segment_count, int seat_ids[], int seat_count)
Optimize the reservations.
Definition: optimize.c:73
int space_available(unsigned int res_arr[], int res_count, int segment_count, unsigned int seat_count, unsigned int new_res)
Check if there is enough space available.
Definition: optimize.c:55
void delete_seat_collection(SeatCollection *collection)
Delete a seat collection.
Definition: optimize.c:47
SeatCollection * new_seat_collection(int seat_count, int seat_ids[])
Create a new seat collection.
Definition: optimize.c:35
void delete_seat(Seat *seat)
Delete a seat.
Definition: optimize.c:28
Seat * new_seat(int seat_id)
Create a new seat.
Definition: optimize.c:13
A seat collection.
Definition: types.h:190
A seat.
Definition: types.h:178