-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathparser.h
40 lines (33 loc) · 1.08 KB
/
parser.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#define SITE_CONTENT_START "Tagesübersicht"
#define SITE_TITLE_START "<span class=\"bold\">"
#define SITE_TABLE_START "<div class=\"container-fluid splGroupWrapper\">"
#define SITE_MEAL_LINE "splMeal"
#define SITE_TOPIC_LINE "splGroup"
#define SITE_TOPIC_LINE_FULL "<span class=\"bold\">"
#define SITE_TABLE_END "<div id=\"legende\">"
#define SITE_AMPEL "/ampel"
#define SITE_PRICES_NEXT_LINE "col-xs-6 col-md-3 text-right"
#define SITE_PRICES_LINE "€"
#define SITE_PRICES_PARSING "€ %[0-9,]/%[0-9,]/%[0-9,]"
#define MAX_MALLOC_PRICES_STRING 9
#define MEAL_GRUEN "gruen"
#define MEAL_ORANGE "gelb"
#define MEAL_ROT "rot"
#define NUM_MEAL_GRUEN 1
#define NUM_MEAL_ORANGE 2
#define NUM_MEAL_ROT 3
struct mealTopic {
char * description;
struct mealTopic * nextTopic;
struct mealListItem * mealList;
long positionInFile;
};
struct mealListItem {
struct mealListItem * nextItem;
int color;
char * description;
char * priceStudent;
char * priceWorker;
char * priceForeigner;
};
int parsePlan(char * mensaURL, int pNextDay, int pColored, int pPrices[3]);