1
0
mirror of https://gitlab.com/klmp200/LO41.git synced 2024-11-23 17:23:21 +00:00
LO41/Resident/Resident.h

34 lines
797 B
C
Raw Normal View History

//
// Created by Antoine Bartuccio on 06/06/2018.
//
#ifndef LO41_RESIDENT_H
#define LO41_RESIDENT_H
#include "../Objects.h"
typedef struct o_Resident {
PRIVATE int id;
PRIVATE int thread_number;
PRIVATE int apartment_floor;
PRIVATE int destination;
PRIVATE int position;
PRIVATE char* name;
2018-06-21 14:15:33 +00:00
PRIVATE void* passenger;
2018-06-10 23:58:52 +00:00
PUBLIC void * (*runnable)(void * void_this);
PUBLIC char * (*get_name)(_THIS(Resident));
PUBLIC int (*get_id)(_THIS(Resident));
PUBLIC int (*get_apartment_floor)(_THIS(Resident));
2018-06-20 20:06:45 +00:00
PUBLIC int (*get_destination)(_THIS(Resident));
PUBLIC void (*set_thread_number)(_THIS(Resident), int data);
DESTRUCTOR(Resident);
} Resident;
FRIENDLY(name, Building)
2018-06-10 15:57:39 +00:00
Resident *_init_Resident(int id, char * name, int apartment_floor, int destination);
#endif //LO41_RESIDENT_H