Rewrote header. Don't know if this is even used/supported.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@32750 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -1,59 +1,46 @@
|
|||||||
/*******************************************************************************
|
/*
|
||||||
/
|
* Copyright 2009, Haiku, Inc. All rights reserved.
|
||||||
/ File: net_settings.h
|
* Distributed under the terms of the MIT License.
|
||||||
/
|
*/
|
||||||
/ Description: Network preferences settings.
|
|
||||||
/
|
|
||||||
/ Copyright 1993-98, Be Incorporated, All Rights Reserved.
|
|
||||||
/
|
|
||||||
*******************************************************************************/
|
|
||||||
|
|
||||||
#ifndef _NET_SETTINGS_H
|
#ifndef _NET_SETTINGS_H
|
||||||
#define _NET_SETTINGS_H
|
#define _NET_SETTINGS_H
|
||||||
|
|
||||||
#include <BeBuild.h>
|
|
||||||
#include <SupportDefs.h>
|
#include <SupportDefs.h>
|
||||||
|
|
||||||
#if __cplusplus
|
#if __cplusplus
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif /* __cplusplus */
|
#endif /* __cplusplus */
|
||||||
|
|
||||||
/*
|
|
||||||
* Private types
|
/* private types */
|
||||||
*/
|
|
||||||
typedef struct _ns_entry {
|
typedef struct _ns_entry {
|
||||||
const char *key;
|
const char* key;
|
||||||
const char *value;
|
const char* value;
|
||||||
} _ns_entry_t;
|
} _ns_entry_t;
|
||||||
|
|
||||||
typedef struct _ns_section {
|
typedef struct _ns_section {
|
||||||
const char *heading;
|
const char* heading;
|
||||||
unsigned nentries;
|
unsigned nentries;
|
||||||
_ns_entry_t *entries;
|
_ns_entry_t* entries;
|
||||||
} _ns_section_t;
|
} _ns_section_t;
|
||||||
|
|
||||||
|
|
||||||
/*
|
/* public type (data members are private) */
|
||||||
* Public type, but the data members are private
|
|
||||||
*/
|
|
||||||
typedef struct _net_settings {
|
typedef struct _net_settings {
|
||||||
int _dirty;
|
int _dirty;
|
||||||
unsigned _nsections;
|
unsigned _nsections;
|
||||||
_ns_section_t *_sections;
|
_ns_section_t* _sections;
|
||||||
char _fname[64];
|
char _fname[64];
|
||||||
} net_settings;
|
} net_settings;
|
||||||
|
|
||||||
/*
|
/* finding and setting network preferences */
|
||||||
* For finding and setting network preferences
|
extern char* find_net_setting(net_settings* ncw, const char* heading,
|
||||||
*/
|
const char* name, char* value, unsigned nbytes);
|
||||||
extern
|
|
||||||
char *find_net_setting(net_settings *ncw,
|
extern status_t set_net_setting(net_settings* ncw, const char* heading,
|
||||||
const char *heading, const char *name, char *value,
|
const char* name, const char* value);
|
||||||
unsigned nbytes);
|
|
||||||
extern
|
|
||||||
status_t set_net_setting(net_settings *ncw,
|
|
||||||
const char *heading, const char *name,
|
|
||||||
const char *value);
|
|
||||||
|
|
||||||
#if __cplusplus
|
#if __cplusplus
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user