Adaptive Framework  0.9.0
All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
afw_command_local_server.h
Go to the documentation of this file.
1 // See the 'COPYING' file in the project root for licensing information.
2 /*
3  * Interface afw_server implementation for afw_command_local
4  *
5  * Copyright (c) 2010-2023 Clemson University
6  *
7  */
8 
9 #ifndef __AFW_COMMAND_LOCAL_SERVER_H__
10 #define __AFW_COMMAND_LOCAL_SERVER_H__
11 
12 #include "afw_interface.h"
13 #include "afw_command_internal.h"
15 
29 
30 typedef enum {
31  afw_command_local_server_mode_action,
32  afw_command_local_server_mode_action_direct,
33  afw_command_local_server_mode_evaluate,
34  afw_command_local_server_mode_evaluate_direct, // default
35  afw_command_local_server_mode_http_like
36 } afw_command_local_server_mode_t;
37 
38 
39 
40 
44 typedef struct
46  afw_server_t pub;
47  afw_command_self_t *command_self;
48  const afw_request_handler_t *director;
49 
50  apr_array_header_t *input_buffer;
51  const afw_content_type_t *content_type;
52 
53  const afw_utf8_t *evaluate_function_id;
54 
55  FILE *fd_input;
56  FILE *fd_output;
57 
58  afw_boolean_t fatal_error;
59  afw_boolean_t eof;
60 
61  afw_command_local_server_mode_t mode;
62 
63  const afw_object_t *request_properties;
64 
65  union {
66  const afw_object_t *properties_array[4];
67  struct {
68  const afw_object_t *this_request_properties;
69  const afw_object_t *multi_request_mode_properties;
70  const afw_object_t *multi_request_properties;
71  const afw_object_t *should_be_NULL;
72  };
73  };
74 
75 
77 
78 
79 
82  afw_command_self_t *command_self);
83 
84 
86 afw_command_local_server_write_result(
88  const char *format, ...);
89 
90 
92 afw_command_local_server_write_error(
94  const afw_error_t *error,
95  afw_xctx_t *xctx);
96 
97 
99 afw_command_local_server_write_end(
101 
102 
103 
104 AFW_END_DECLARES
105 
106 #endif /* __AFW_COMMAND_LOCAL_SERVER_H__ */
107 
Adaptive Framework declare helpers for afw_command_.
#define AFW_COMMAND_DECLARE_INTERNAL(type)
Declare an internal function for /src/afw_command/ source*.h files.
Adaptive Framework afw command internal header.
#define AFW_BEGIN_DECLARES
Interfaceafw_interface header.
afw_command_local_server_create(afw_command_self_t *command_self)
struct afw_command_local_server_self_s afw_command_local_server_self_t
Self typedef for afw_command_local implementation of afw_server.
_Bool afw_boolean_t
Definition: afw_common.h:373
Self typedef for afw_command_local implementation of afw_server.
Self typedef for afw_command self.
Interface afw_content_type public struct.
Adaptive Framework Error.
Definition: afw_error.h:65
Interface afw_object public struct.
Interface afw_request_handler public struct.
Interface afw_server public struct.
NFC normalized UTF-8 string.
Definition: afw_common.h:545
Interface afw_xctx public struct.