]> err.no Git - sope/blob - sope-appserver/mod_ngobjweb/ngobjweb_module.c
INSTALL_ROOT_DIR patch
[sope] / sope-appserver / mod_ngobjweb / ngobjweb_module.c
1 /*
2   Copyright (C) 2000-2003 SKYRIX Software AG
3
4   This file is part of OGo
5
6   OGo is free software; you can redistribute it and/or modify it under
7   the terms of the GNU Lesser General Public License as published by the
8   Free Software Foundation; either version 2, or (at your option) any
9   later version.
10
11   OGo is distributed in the hope that it will be useful, but WITHOUT ANY
12   WARRANTY; without even the implied warranty of MERCHANTABILITY or
13   FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public
14   License for more details.
15
16   You should have received a copy of the GNU Lesser General Public
17   License along with OGo; see the file COPYING.  If not, write to the
18   Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
19   02111-1307, USA.
20 */
21 // $Id$
22
23 #include "common.h"
24
25 static command_rec ngobjweb_cmds[] = {
26   {
27     "SetSNSPort",
28     ngobjweb_set_sns_port,
29     NULL,
30     OR_FILEINFO,
31     TAKE1,
32     "the path of the Unix domain address to use (eg /tmp/.snsd)"
33   },
34   {
35     "SetAppPort",
36     ngobjweb_set_app_port,
37     NULL,
38     OR_FILEINFO,
39     TAKE1,
40     "the path of the Unix domain address to use (eg /tmp/.snsd)"
41   },
42   {
43     "SetAppPrefix",
44     ngobjweb_set_app_prefix,
45     NULL,
46     OR_FILEINFO,
47     TAKE1,
48     "any prefix that is before the app name (eg /MyDir with /MyDir/MyApp.woa)"
49   },
50   {
51     "SNSUseHTTP",
52     ngobjweb_set_use_http,
53     NULL,
54     OR_FILEINFO,
55     0,
56     "use HTTP protocol to query snsd (on,off) ?"
57   },
58   { NULL }
59 };
60
61 #ifdef AP_VERSION_1
62 static handler_rec ngobjweb_handlers[] = {
63   { "ngobjweb-adaptor", ngobjweb_handler },
64   { NULL }
65 };
66
67 static void ngobjweb_init(server_rec *_server, pool *_pool) {
68 }
69
70 module ngobjweb_module = {
71   STANDARD_MODULE_STUFF,
72   ngobjweb_init,              /* initializer */
73   ngobjweb_create_dir_config, /* dir config creater */
74   ngobjweb_merge_dir_configs, /* dir merger --- default is to override */
75   NULL,                       /* server config */
76   NULL,                       /* merge server config */
77   ngobjweb_cmds,              /* command table */
78   ngobjweb_handlers,          /* handlers */
79   NULL,                       /* filename translation */ 
80   NULL,                       /* check_user_id */
81   NULL,                       /* check auth */
82   NULL,                       /* check access */
83   NULL,                       /* type_checker */
84   NULL,                       /* fixups */
85   NULL,                       /* logger */
86   NULL                        /* header parser */
87 };
88 #else
89 static void ngobjweb_register_hooks(apr_pool_t *p) {
90   ap_hook_handler(ngobjweb_handler, NULL, NULL, APR_HOOK_LAST);
91 }
92
93 module AP_MODULE_DECLARE_DATA ngobjweb_module = {
94   STANDARD20_MODULE_STUFF,
95   ngobjweb_create_dir_config,  /* create per-directory config structures */
96   ngobjweb_merge_dir_configs,  /* merge per-directory config structures  */
97   NULL,                        /* create per-server config structures    */
98   NULL,                        /* merge per-server config structures     */
99   ngobjweb_cmds,               /* command handlers */
100   ngobjweb_register_hooks      /* register hooks */
101 };
102 #endif
103