| 30 #define REQUEST_H |
30 #define REQUEST_H |
| 31 |
31 |
| 32 #include "../public/nsapi.h" |
32 #include "../public/nsapi.h" |
| 33 #include "../util/object.h" |
33 #include "../util/object.h" |
| 34 |
34 |
| |
35 #include "location.h" |
| |
36 |
| 35 #include <cx/map.h> |
37 #include <cx/map.h> |
| 36 |
38 |
| 37 #ifdef __cplusplus |
39 #ifdef __cplusplus |
| 38 extern "C" { |
40 extern "C" { |
| 39 #endif |
41 #endif |
| 40 |
42 |
| 41 typedef struct NSAPIRequest NSAPIRequest; |
43 typedef struct NSAPIRequest NSAPIRequest; |
| 42 |
44 |
| 43 struct NSAPIRequest { |
45 struct NSAPIRequest { |
| 44 Request rq; |
46 Request rq; |
| 45 RequestStage phase; |
47 RequestStage phase; |
| 46 VirtualServer *vs; |
48 VirtualServer *vs; |
| 47 char *host; |
49 char *host; |
| 48 uint16_t port; |
50 uint16_t port; |
| 49 NSAPIContext context; |
51 NSAPIContext context; |
| 50 void *jvm_context; |
52 WSLocationConfig *location; |
| 51 CxMap *resources; |
53 void *jvm_context; |
| 52 WSBool finished; |
54 CxMap *resources; |
| |
55 WSBool finished; |
| 53 }; |
56 }; |
| 54 |
57 |
| 55 /* macros for context access */ |
58 /* macros for context access */ |
| 56 #define NCX_OI(rq) rq->context.objset_index |
59 #define NCX_OI(rq) rq->context.objset_index |
| 57 #define NCX_DI(rq) rq->context.dtable_index |
60 #define NCX_DI(rq) rq->context.dtable_index |