OceanDirectLighthouseC++ 3.1.3
OceanDirect Lighthouse C++/C API
Ipv4AddressAPI.h
Go to the documentation of this file.
1#ifndef IPV4ADDRESSAPI_H
2#define IPV4ADDRESSAPI_H
3/*****************************************************
4 * @file Ipv4AddressAPI.h
5 * @date March 2021
6 * @author Ocean Insight, Inc.
7 *
8 * This is an interface to OceanDirect that allows
9 * the user to query and set IPv4 address parameters
10 */
11 /************************************************************************
12 *
13 * OCEAN INSIGHT CONFIDENTIAL
14 * __________________
15 *
16 * [2018] - [2020] Ocean Insight Incorporated
17 * All Rights Reserved.
18 *
19 * NOTICE: All information contained herein is, and remains
20 * the property of Ocean Insight Incorporated and its suppliers,
21 * if any. The intellectual and technical concepts contained
22 * herein are proprietary to Ocean Insight Incorporated
23 * and its suppliers and may be covered by U.S. and Foreign Patents,
24 * patents in process, and are protected by trade secret or copyright law.
25 * Dissemination of this information or reproduction of this material
26 * is strictly forbidden unless prior written permission is obtained
27 * from Ocean Insight Incorporated.
28 *
29 **************************************************************************/
30
31
32#include "api/DllDecl.h"
33
38namespace oceandirect {
39 namespace api {
40
41 class DLL_DECL Ipv4AddressAPI {
42 public:
43 virtual ~Ipv4AddressAPI();
45
46 static void shutdown();
47
63 virtual bool isDHCPEnabled(long deviceID, int *errorCode, unsigned char ifNum);
64
78 virtual void setDHCPEnable(long deviceID, int *errorCode, unsigned char ifNum, unsigned char enabled);
79
95 virtual int getNumberOfIpAddresses(long deviceID, int *errorCode, unsigned char ifNum);
96
118 virtual void readIpAddress(long deviceID, int *errorCode, unsigned char ifNum, unsigned char addressIndex,
119 unsigned char *ipAddress, int ipAddressLength, unsigned int *netmask);
120
138 virtual void addStaticIpAddress(long deviceID, int* errorCode, unsigned char ifNum,
139 unsigned char *ipAddress, int ipAddressLength, unsigned int netmask);
140
154 virtual void deleteStaticIpAddress(long deviceID, int* errorCode, unsigned char ifNum, unsigned char addressIndex);
155
156
157 /*
158 TODO: Add the following functions
159 -get/set ipv4 default gateway
160 */
176 virtual void setDefaultGatewayIpAddress(long deviceID, int* errorCode, unsigned char ifNum, unsigned char* ipAddress, int ipAddressLength);
177
193 virtual void getDefaultGatewayIpAddress(long deviceID, int* errorCode, unsigned char ifNum, unsigned char* outIpAddress, int ipAddressLength);
194
195 protected:
198 };
199 }
200}
201#endif /* IPV4ADDRESSAPI_H */
Definition Ipv4AddressAPI.h:41
virtual void deleteStaticIpAddress(long deviceID, int *errorCode, unsigned char ifNum, unsigned char addressIndex)
virtual void setDHCPEnable(long deviceID, int *errorCode, unsigned char ifNum, unsigned char enabled)
static Ipv4AddressAPI * instance
Definition Ipv4AddressAPI.h:197
virtual void addStaticIpAddress(long deviceID, int *errorCode, unsigned char ifNum, unsigned char *ipAddress, int ipAddressLength, unsigned int netmask)
virtual int getNumberOfIpAddresses(long deviceID, int *errorCode, unsigned char ifNum)
virtual void getDefaultGatewayIpAddress(long deviceID, int *errorCode, unsigned char ifNum, unsigned char *outIpAddress, int ipAddressLength)
static Ipv4AddressAPI * getInstance()
virtual void readIpAddress(long deviceID, int *errorCode, unsigned char ifNum, unsigned char addressIndex, unsigned char *ipAddress, int ipAddressLength, unsigned int *netmask)
virtual bool isDHCPEnabled(long deviceID, int *errorCode, unsigned char ifNum)
virtual void setDefaultGatewayIpAddress(long deviceID, int *errorCode, unsigned char ifNum, unsigned char *ipAddress, int ipAddressLength)
This is an interface to OceanDirect that allows the user to connect to devices over USB and other bus...
Definition OceanDirectAPI.h:147