Mercurial > mplayer.hg
annotate asxparser.h @ 26525:042e31cf3c25
Make OBJS depend on the recurse target instead of just the all target.
This fixes 'make mplayer' and 'make mencoder'.
author | diego |
---|---|
date | Mon, 28 Apr 2008 11:22:25 +0000 |
parents | 4129c8cfa742 |
children | 0f1b5b68af32 |
rev | line source |
---|---|
26029 | 1 #ifndef MPLAYER_ASXPARSER_H |
2 #define MPLAYER_ASXPARSER_H | |
4043
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
3 |
25607
9d0b189ce1b2
Fix illegal identifiers: Names starting with __ or _ and uppercase are reserved
diego
parents:
25553
diff
changeset
|
4 typedef struct ASX_Parser_t ASX_Parser_t; |
4043
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
5 |
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
6 typedef struct { |
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
7 char* buffer; |
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
8 int line; |
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
9 } ASX_LineSave_t; |
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
10 |
25607
9d0b189ce1b2
Fix illegal identifiers: Names starting with __ or _ and uppercase are reserved
diego
parents:
25553
diff
changeset
|
11 struct ASX_Parser_t { |
4043
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
12 int line; // Curent line |
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
13 ASX_LineSave_t *ret_stack; |
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
14 int ret_stack_size; |
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
15 char* last_body; |
4309 | 16 int deep; |
4043
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
17 }; |
25590564842f
tree-based playlist parser code by Alban Bedel <albeu@free.fr>
arpi
parents:
diff
changeset
|
18 |
8170 | 19 ASX_Parser_t* |
20 asx_parser_new(void); | |
21 | |
22 void | |
23 asx_parser_free(ASX_Parser_t* parser); | |
24 | |
25 /* | |
26 * Return -1 on error, 0 when nothing is found, 1 on sucess | |
27 */ | |
28 int | |
29 asx_get_element(ASX_Parser_t* parser,char** _buffer, | |
30 char** _element,char** _body,char*** _attribs); | |
31 | |
32 int | |
33 asx_parse_attribs(ASX_Parser_t* parser,char* buffer,char*** _attribs); | |
34 | |
35 /////// Attribs utils | |
36 | |
37 char* | |
19104
2ec2301183cd
marks several read-only string parameters which aren't modified inside the called function as const. Patch by Stefan Huehner, stefan AT huehner-org
reynaldo
parents:
19053
diff
changeset
|
38 asx_get_attrib(const char* attrib,char** attribs); |
8170 | 39 |
40 int | |
19053
75327b24e06f
marks several string parameters as const, as they are not modified inside the function, Patch by Stefan Huehner, stefan AT huehner-org
reynaldo
parents:
8170
diff
changeset
|
41 asx_attrib_to_enum(const char* val,char** valid_vals); |
8170 | 42 |
23609 | 43 #define asx_free_attribs(a) asx_list_free(&a,free) |
8170 | 44 |
45 ////// List utils | |
46 | |
47 typedef void (*ASX_FreeFunc)(void* arg); | |
48 | |
49 void | |
50 asx_list_free(void* list_ptr,ASX_FreeFunc free_func); | |
25553
6ac1ece1f9fe
Add multiple inclusion guards to all header files that lack them.
diego
parents:
23609
diff
changeset
|
51 |
26029 | 52 #endif /* MPLAYER_ASXPARSER_H */ |