2 * Copyright (c) 2000-2006 Apple Computer, Inc. All rights reserved.
4 * @APPLE_LICENSE_HEADER_START@
6 * This file contains Original Code and/or Modifications of Original Code
7 * as defined in and that are subject to the Apple Public Source License
8 * Version 2.0 (the 'License'). You may not use this file except in
9 * compliance with the License. Please obtain a copy of the License at
10 * http://www.opensource.apple.com/apsl/ and read it before using this
13 * The Original Code and all software distributed under the License are
14 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
15 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
16 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
18 * Please see the License for the specific language governing rights and
19 * limitations under the License.
21 * @APPLE_LICENSE_HEADER_END@
25 * Modification History
27 * June 1, 2001 Allan Nathanson <ajn@apple.com>
28 * - public API conversion
30 * March 24, 2000 Allan Nathanson <ajn@apple.com>
34 #ifndef _S_CONFIGD_SERVER_H
35 #define _S_CONFIGD_SERVER_H
37 #include <sys/cdefs.h>
38 #include <mach/mach.h>
39 #include <CoreFoundation/CoreFoundation.h>
43 void configdCallback (CFMachPortRef port
,
48 boolean_t
server_active (mach_port_t
*service_port
);
50 void server_init (mach_port_t service_port
,
51 Boolean enableRestart
);
53 int server_shutdown (void);
55 void server_loop (void);
57 kern_return_t
_snapshot (mach_port_t server
,
60 kern_return_t
_configopen (mach_port_t server
,
62 mach_msg_type_number_t nameLen
,
64 mach_msg_type_number_t optionsLen
,
65 mach_port_t
*newServer
,
67 audit_token_t audit_token
);
69 kern_return_t
_configclose (mach_port_t server
,
72 kern_return_t
_configlock (mach_port_t server
,
75 kern_return_t
_configunlock (mach_port_t server
,
78 kern_return_t
_configlist (mach_port_t server
,
80 mach_msg_type_number_t keyLen
,
82 xmlDataOut_t
*listRef
,
83 mach_msg_type_number_t
*listLen
,
86 kern_return_t
_configadd (mach_port_t server
,
88 mach_msg_type_number_t keyLen
,
90 mach_msg_type_number_t dataLen
,
94 kern_return_t
_configadd_s (mach_port_t server
,
96 mach_msg_type_number_t keyLen
,
98 mach_msg_type_number_t dataLen
,
102 kern_return_t
_configget (mach_port_t server
,
104 mach_msg_type_number_t keyLen
,
105 xmlDataOut_t
*dataRef
,
106 mach_msg_type_number_t
*dataLen
,
110 kern_return_t
_configset (mach_port_t server
,
112 mach_msg_type_number_t keyLen
,
114 mach_msg_type_number_t dataLen
,
118 kern_return_t
_configremove (mach_port_t server
,
120 mach_msg_type_number_t keyLen
,
123 kern_return_t
_configtouch (mach_port_t server
,
125 mach_msg_type_number_t keyLen
,
128 kern_return_t
_confignotify (mach_port_t server
,
130 mach_msg_type_number_t keyLen
,
133 kern_return_t
_configget_m (mach_port_t server
,
135 mach_msg_type_number_t keysLen
,
136 xmlData_t patternsRef
,
137 mach_msg_type_number_t patternsLen
,
138 xmlDataOut_t
*dataRef
,
139 mach_msg_type_number_t
*dataLen
,
142 kern_return_t
_configset_m (mach_port_t server
,
144 mach_msg_type_number_t dataLen
,
146 mach_msg_type_number_t removeLen
,
148 mach_msg_type_number_t notifyLen
,
151 kern_return_t
_notifyadd (mach_port_t server
,
153 mach_msg_type_number_t keyLen
,
157 kern_return_t
_notifyremove (mach_port_t server
,
159 mach_msg_type_number_t keyLen
,
163 kern_return_t
_notifychanges (mach_port_t server
,
164 xmlDataOut_t
*listRef
,
165 mach_msg_type_number_t
*listLen
,
168 kern_return_t
_notifyviaport (mach_port_t server
,
173 kern_return_t
_notifyviafd (mach_port_t server
,
175 mach_msg_type_number_t pathLen
,
179 kern_return_t _notifyviasignal
185 kern_return_t
_notifycancel (mach_port_t server
,
188 kern_return_t
_notifyset (mach_port_t server
,
190 mach_msg_type_number_t keysLen
,
191 xmlData_t patternsRef
,
192 mach_msg_type_number_t patternsLen
,
197 #endif /* !_S_CONFIGD_SERVER_H */