]> git.saurik.com Git - apple/mdnsresponder.git/blob - ServiceRegistration/config-parse.h
mDNSResponder-1310.40.42.tar.gz
[apple/mdnsresponder.git] / ServiceRegistration / config-parse.h
1 /* -*- Mode: C; tab-width: 4; c-file-style: "bsd"; c-basic-offset: 4; fill-column: 108 -*-
2 *
3 * Copyright (c) 2002-2004 Apple Computer, Inc. All rights reserved.
4 * Copyright (c) 2018 Apple Computer, Inc. All rights reserved.
5 *
6 * Licensed under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
9 *
10 * http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
17 *
18 */
19
20 #ifndef __CONFIG_PARSE_H
21 #define __CONFIG_PARSE_H
22
23 // Structure of a configuration file verb
24 typedef struct {
25 char *name;
26 int min_hunks, max_hunks;
27 bool (*handler)(void *context, const char *config_file_name, char **hunks, int num_hunks, int lineno);
28 } config_file_verb_t;
29
30 // Provided by RelayParse.c
31 bool config_parse(void *context, const char *config_file_name, config_file_verb_t *verbs, int num_verbs);
32
33 #endif // __CONFIG_PARSE_H