~shakaran/ubuntu/quantal/connman/bug-pattern-update

« back to all changes in this revision

Viewing changes to include/dhcp.h

  • Committer: Bazaar Package Importer
  • Author(s): Mathieu Trudel
  • Date: 2010-02-12 10:08:03 UTC
  • mfrom: (1.1.8 upstream) (0.1.5 sid)
  • Revision ID: james.westby@ubuntu.com-20100212100803-s8iaj8g1dmgwm2uz
Tags: 0.48+dfsg-2
* Ubuntu/Debian sync upload
* Re-add missing changes from 0.45+dfsg that made it only in Ubuntu:
  - ship development parts in a connman-dev package (Closes: 546616)
    - add debian/connman-dev.install
    - update debian/control
* Update long descriptions for connman and connman-dev
  - update debian/control
* Add missing Depends on libglib2.0-dev, libdbus-1-dev for connman-dev
  - update debian/control
* Don't run bootstrap twice during build.
  - update debian/rules
* Remove old configure option: enable-ppp, with-pppd, enable-novatel,
  enable-huawei and enable-modemmgr are no longer recognized.
  - update debian/rules

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 *
 
3
 *  Connection Manager
 
4
 *
 
5
 *  Copyright (C) 2007-2009  Intel Corporation. All rights reserved.
 
6
 *
 
7
 *  This program is free software; you can redistribute it and/or modify
 
8
 *  it under the terms of the GNU General Public License version 2 as
 
9
 *  published by the Free Software Foundation.
 
10
 *
 
11
 *  This program is distributed in the hope that it will be useful,
 
12
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 
13
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
14
 *  GNU General Public License for more details.
 
15
 *
 
16
 *  You should have received a copy of the GNU General Public License
 
17
 *  along with this program; if not, write to the Free Software
 
18
 *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 
19
 *
 
20
 */
 
21
 
 
22
#ifndef __CONNMAN_DHCP_H
 
23
#define __CONNMAN_DHCP_H
 
24
 
 
25
#ifdef __cplusplus
 
26
extern "C" {
 
27
#endif
 
28
 
 
29
/**
 
30
 * SECTION:dhcp
 
31
 * @title: DHCP premitives
 
32
 * @short_description: Functions for handling DHCP
 
33
 */
 
34
 
 
35
enum connman_dhcp_state {
 
36
        CONNMAN_DHCP_STATE_UNKNOWN  = 0,
 
37
        CONNMAN_DHCP_STATE_IDLE     = 1,
 
38
        CONNMAN_DHCP_STATE_BOUND    = 2,
 
39
        CONNMAN_DHCP_STATE_RENEW    = 3,
 
40
        CONNMAN_DHCP_STATE_FAIL     = 4,
 
41
};
 
42
 
 
43
struct connman_dhcp;
 
44
 
 
45
struct connman_dhcp *connman_dhcp_ref(struct connman_dhcp *dhcp);
 
46
void connman_dhcp_unref(struct connman_dhcp *dhcp);
 
47
 
 
48
int connman_dhcp_get_index(struct connman_dhcp *dhcp);
 
49
char *connman_dhcp_get_interface(struct connman_dhcp *dhcp);
 
50
 
 
51
void connman_dhcp_set_value(struct connman_dhcp *dhcp,
 
52
                                        const char *key, const char *value);
 
53
 
 
54
void connman_dhcp_bound(struct connman_dhcp *dhcp);
 
55
void connman_dhcp_renew(struct connman_dhcp *dhcp);
 
56
void connman_dhcp_fail(struct connman_dhcp *dhcp);
 
57
 
 
58
void *connman_dhcp_get_data(struct connman_dhcp *dhcp);
 
59
void connman_dhcp_set_data(struct connman_dhcp *dhcp, void *data);
 
60
 
 
61
struct connman_dhcp_driver {
 
62
        const char *name;
 
63
        int priority;
 
64
        int (*request) (struct connman_dhcp *dhcp);
 
65
        int (*release) (struct connman_dhcp *dhcp);
 
66
        int (*renew) (struct connman_dhcp *dhcp);
 
67
};
 
68
 
 
69
int connman_dhcp_driver_register(struct connman_dhcp_driver *driver);
 
70
void connman_dhcp_driver_unregister(struct connman_dhcp_driver *driver);
 
71
 
 
72
#ifdef __cplusplus
 
73
}
 
74
#endif
 
75
 
 
76
#endif /* __CONNMAN_DHCP_H */