|
RDK Documentation (Open Sourced RDK Components)
|
Go to the documentation of this file.
71 #ifndef DEVICE_IP_INTERFACE_H_
72 #define DEVICE_IP_INTERFACE_H_
78 #include "hostIf_tr69ReqHandler.h"
79 #include "hostIf_utils.h"
80 #include "hostIf_updateHandler.h"
83 #define IP_STATUS_LENGTH 24
84 #define ALIAS_LENGTH 70
85 #define NAME_LENGTH 70
86 #define LL_LENGTH 1024
87 #define ROUTER_LENGTH 256
88 #define TYPE_LENGTH 24
103 char status[IP_STATUS_LENGTH];
104 char alias[ALIAS_LENGTH];
105 char name[NAME_LENGTH];
106 unsigned int lastChange;
107 char lowerLayers[LL_LENGTH];
108 char router[ROUTER_LENGTH];
110 unsigned int maxMTUSize;
111 char type[TYPE_LENGTH];
113 unsigned int iPv4AddressNumberOfEntries;
115 unsigned int iPv6AddressNumberOfEntries;
116 unsigned int iPv6PrefixNumberOfEntries;
141 eIPIPv4AddressNumberOfEntries,
143 eIPIPv6AddressNumberOfEntries,
144 #endif // IPV6_SUPPORT
226 static GHashTable *ifHash;
230 char nameOfInterface[IF_NAMESIZE];
235 void refreshInterfaceName ();
237 unsigned int getIPAddressNumberOfEntries (sa_family_t address_family);
238 int set_Interface_Reset (
unsigned int value);
239 int set_Interface_Enable (
int value);
240 int set_Interface_Mtu (
unsigned int value);
243 bool bCalledIPv4Enable;
244 bool bCalledIPv6Enable;
248 bool bCalledMaxMTUSize;
250 bool bCalledLoopback;
251 bool bCalledIPv4AddressNumberOfEntries;
253 unsigned int backupIPv4AddressNumberOfEntries;
254 unsigned int backupMaxMTUSize;
258 bool backupIPv4Enable;
259 bool backupIPv6Enable;
262 char backupType[_BUF_LEN_16];
263 char backupName[_BUF_LEN_16];
264 char backupStatus[_BUF_LEN_16];
271 static GList* getAllInstances();
272 static void closeAllInstances();
277 static void getActiveFlags (
char* nameOfInterface,
struct ifreq& ifr);
278 static bool isLoopback (
char* nameOfInterface);
279 static bool isEnabled (
char* nameOfInterface);
280 static int getMTU (
char* nameOfInterface);
282 void getInterfaceOperationalState (
char* operationalState);
285 unsigned int getIPv6PrefixNumberOfEntries ();
293 int get_Interface_IPv6Enable(
HOSTIF_MsgData_t *stMsgData,
bool *pChanged = NULL);
int get_Interface_Router(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
This function gets the Router instance that is associated with an IP Interface entry....
int get_Interface_Enable(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
This function gets the status to enabled or disabled of an IP Interface. It provides the values such ...
int get_Interface_LastChange(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
This function gets the last change of status time of the interface. It provides the accumulated time ...
int set_Interface_MaxMTUSize(HOSTIF_MsgData_t *stMsgData)
This function sets the size of maximum transmission unit (MTU), i.e. the largest allowed size of an I...
int get_Interface_Name(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
This function gets the IP Interface Name.It provides the textual name of the interface as assigned by...
int get_Interface_Reset(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
Get IP Interface Reset status.
int get_Interface_Type(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
This function gets the IP Interface Type. It provides the IP interface type. Possible values are Norm...
int get_Interface_Alias(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
This function gets the instance handle for an IP Interface. It provides a non-volatile handle used to...
int get_Interface_IPv4AddressNumberOfEntries(HOSTIF_MsgData_t *stMsgData)
Get the IP Interface IPv4AddressNumberOfEntries.
unsigned int getIPv4AddressNumberOfEntries()
int set_Interface_IPv4Enable(HOSTIF_MsgData_t *stMsgData)
Attach/Detach an IP interface to/from the IPv4 stack.
int get_Interface_LowerLayers(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
Get IP Interface LowerLayers.
int get_Interface_IPv4Enable(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
This function gets the status of the IPv4 stack attachment for an IP interface. It indicates whether ...
EDeviceIPInterfaceMembers
It contains the members variables of the EDeviceIPInterfaceMembers enum.
int set_Interface_Loopback(HOSTIF_MsgData_t *stMsgData)
This function sets the IP interface LoopBack flag to 'true' or 'false'. Currently not implemented.
It contains the members variables of the Device_IP_Interface structure.
int get_Interface_Status(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
This function gets the IP interface Status. It provides the current operational state of the Interfac...
int set_Interface_Router(HOSTIF_MsgData_t *stMsgData)
This function sets the router instance that is associated with an IP Interface entry....
int get_Interface_ULAEnable(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
This function gets the status 'enabled' or 'disabled' of ULA(Unique local address) generation for an ...
int set_Interface_Alias(HOSTIF_MsgData_t *stMsgData)
This function sets a non-volatile handle used to reference this IP interface instance....
This class provides the hostIf IP interface for getting IP interface information.
int set_Interface_AutoIPEnable(HOSTIF_MsgData_t *stMsgData)
This function sets the Auto-IP on an IP Interface status 'enable' or 'disable'. It sets 'true' for en...
int set_Interface_LowerLayers(HOSTIF_MsgData_t *stMsgData)
This function sets the IP Interface LowerLayers. Given a comma-separated list (maximum length 1024) o...
int get_Interface_MaxMTUSize(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
This function gets the IP Interface MaxMTUSize. It provides the maximum transmission unit (MTU),...
struct Device_IP_Interface IPInterface
It contains the members variables of the Device_IP_Interface structure.
hostIf_IPInterface(int dev_id)
Class Constructor of the class hostIf_IPInterface.
int get_Interface_Loopback(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
This function gets the IP interface loopback. It indicates whether or not the IP interface is a loopb...
int get_Interface_AutoIPEnable(HOSTIF_MsgData_t *stMsgData, bool *pChanged=NULL)
Get the status (enabled/disabled) of Auto-IP on an IP Interface.
unsigned int getIPv6AddressNumberOfEntries()
int set_Interface_ULAEnable(HOSTIF_MsgData_t *stMsgData)
This function sets the status 'enabled' or 'disabled' of ULA(Unique Local Address) generation for an ...