Open Ethernet Networking (OpEN) API Guide and Reference Manual  3.6.0.3
openapi_dhcp_server.h
Go to the documentation of this file.
1 
9 /*********************************************************************
10 *
11 * Copyright 2018 Broadcom.
12 *
13 * Licensed under the Apache License, Version 2.0 (the "License");
14 * you may not use this file except in compliance with the License.
15 * You may obtain a copy of the License at
16 *
17 * http://www.apache.org/licenses/LICENSE-2.0
18 *
19 * Unless required by applicable law or agreed to in writing, software
20 * distributed under the License is distributed on an "AS IS" BASIS,
21 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
22 * See the License for the specific language governing permissions and
23 * limitations under the License.
24 *
25 **********************************************************************
26 *
27 * @filename openapi_dhcp_server.h
28 *
29 * @purpose DHCP Server API
30 *
31 * @component OpEN
32 *
33 * @note This code must not include any ICOS header files.
34 *
35 * @create 7/6/2018
36 *
37 * @end
38 *
39 **********************************************************************/
40 #ifndef OPENAPI_DHCP_SERVER_H_INCLUDED
41 #define OPENAPI_DHCP_SERVER_H_INCLUDED
42 
43 #include "openapi_common.h"
44 
46 typedef enum
47 {
52 
54 typedef enum
55 {
62 
63 #define OPEN_DHCP_SERVER_POOL_NAME_MAXLEN 32
64 #define OPEN_DHCP_SERVER_CLIENT_ID_MAXLEN 256
67 typedef struct
68 {
69  char name[OPEN_DHCP_SERVER_POOL_NAME_MAXLEN];
71 
73 typedef struct
74 {
75  char clientid[OPEN_DHCP_SERVER_CLIENT_ID_MAXLEN];
77 
79 typedef enum
80 {
96 
97 /*****************************************************************/
120  open_inet_addr_t *ipaddr,
121  uint32_t *mask,
122  open_buffdesc *hwaddr,
125  uint32_t *remaining);
126 
127 /*****************************************************************/
143  uint32_t *poolIndex,
144  OPEN_DHCP_SERVER_POOL_NAME_t *poolName);
145 
146 /*****************************************************************/
163  uint32_t *poolIndex,
164  OPEN_DHCP_SERVER_POOL_NAME_t *poolName);
165 
166 
167 /*****************************************************************/
185 
186 
187 /*****************************************************************/
206  uint32_t *leaseIndex,
207  open_inet_addr_t *ipaddr,
209 
210 /*****************************************************************/
230  uint32_t *leaseIndex,
231  open_inet_addr_t *ipaddr,
233 
234 /*****************************************************************/
249  OPEN_DHCPS_STAT_ID_t id, uint32_t *val);
250 
251 #endif /* OPENAPI_DHCP_SERVER_H_INCLUDED */
252 
open_error_t openapiDhcpServerPoolEntryNextGet(openapiClientHandle_t *client_handle, uint32_t *poolIndex, OPEN_DHCP_SERVER_POOL_NAME_t *poolName)
Get the next DHCP Server Pool Entry.
open_error_t openapiDhcpServerStatGet(openapiClientHandle_t *client_handle, OPEN_DHCPS_STAT_ID_t id, uint32_t *val)
Get the specified DHCP Server statistic.
OPEN_DHCP_SERVER_POOL_TYPE_t
Pool types.
OPEN_DHCPS_STAT_ID_t
DHCP Server Statistic IDs.
open_error_t
OPEN uses these enumerators to indicate the error codes.
open_error_t openapiDhcpServerPoolEntryFirstGet(openapiClientHandle_t *client_handle, uint32_t *poolIndex, OPEN_DHCP_SERVER_POOL_NAME_t *poolName)
Get the first DHCP Server Pool Entry.
Request messages received.
Release messages received.
open_error_t openapiDhcpServerLeaseEntryNextGet(openapiClientHandle_t *client_handle, OPEN_DHCP_SERVER_POOL_NAME_t *poolName, uint32_t *leaseIndex, open_inet_addr_t *ipaddr, OPEN_DHCP_SERVER_LEASE_STATE_t *state)
Get the next DHCP Server Lease Entry.
Must be last (bounds checking).
Inform messages received.
open_error_t openapiDhcpServerLeaseEntryFirstGet(openapiClientHandle_t *client_handle, OPEN_DHCP_SERVER_POOL_NAME_t *poolName, uint32_t *leaseIndex, open_inet_addr_t *ipaddr, OPEN_DHCP_SERVER_LEASE_STATE_t *state)
Get the first DHCP Server Lease Entry.
open_error_t openapiDhcpServerPoolTypeGet(openapiClientHandle_t *client_handle, OPEN_DHCP_SERVER_POOL_NAME_t *poolName, OPEN_DHCP_SERVER_POOL_TYPE_t *type)
Get the DHCP Server Pool Type.
Discover messages received.
open_error_t openapiDhcpServerLeaseDataGet(openapiClientHandle_t *client_handle, open_inet_addr_t *ipaddr, uint32_t *mask, open_buffdesc *hwaddr, OPEN_DHCP_SERVER_CLIENT_ID_t *clientId, OPEN_DHCP_SERVER_POOL_NAME_t *poolName, uint32_t *remaining)
Get the DHCP Server Lease Data.
OPEN_DHCP_SERVER_LEASE_STATE_t
DHCP server lease states.
Decline messages received.