This interface is a TECHNICAL PREVIEW, it may change.
ToiNetIpDevice is used to get generic information about the network device and to set some generic parameters. Changes take effect after ToiNetConfigurationSession::apply().
import "ToiNetIpDevice.idl";
Public Member Functions | |
| string | getMacAddress () |
| ToiNetIpDeviceInterfaceInfo | getInfo (in TToiInterfaceId interfaceId) raises (TToiInvalidArgumentException) |
| ToiNetIpDeviceDhcpStatus | getDhcpStatus (in TToiInterfaceId interfaceId) raises (TToiInvalidArgumentException, TToiInvalidPreconditionException) |
| void | setEnabled (in TToiInterfaceId interfaceId, in boolean enable) raises (TToiInvalidArgumentException, TToiInvalidPreconditionException) |
| void | setAcquisition (in TToiInterfaceId interfaceId, in TToiAddressAcquisition acquisition) raises (TToiInvalidArgumentException, TToiInvalidPreconditionException) |
| void | setStaticAddress (in TToiInterfaceId interfaceId, in string ip, in string netmask) raises (TToiInvalidArgumentException, TToiInvalidPreconditionException) |
Public Attributes | |
| const TToiInterfaceId | DEFAULT_INTERFACE = 0 |
TToiAddressAcquisition | |
| const TToiAddressAcquisition | ADDRESS_ACQUISITION_STATIC = 0 |
| const TToiAddressAcquisition | ADDRESS_ACQUISITION_DHCP = 1 |
Public Types | |
| typedef long | TToiInterfaceId |
| typedef long | TToiAddressAcquisition |
| typedef long ToiNetIpDevice::TToiAddressAcquisition |
The IP address acquisition method.
| typedef long ToiNetIpDevice::TToiInterfaceId |
Network interface identifier type.
| ToiNetIpDeviceDhcpStatus ToiNetIpDevice::getDhcpStatus | ( | in TToiInterfaceId | interfaceId | ) | raises (TToiInvalidArgumentException, TToiInvalidPreconditionException) |
Returns DHCP status.
| interfaceId | Interface identifier. |
| dhcpStatus | DHCP status. |
| TToiInvalidArgumentException | Raised if interface identifier is invalid. |
| TToiInvalidPreconditionException | Raised if IP acquisition method is not DHCP. |
| ToiNetIpDeviceInterfaceInfo ToiNetIpDevice::getInfo | ( | in TToiInterfaceId | interfaceId | ) | raises (TToiInvalidArgumentException) |
Returns network interface info.
| interfaceId | Interface identifier. |
| info | Interface info. |
| TToiInvalidArgumentException | Raised if interface identifier is invalid. |
| string ToiNetIpDevice::getMacAddress | ( | ) |
Returns network device mac address.
| mac | Device mac address. |
| void ToiNetIpDevice::setAcquisition | ( | in TToiInterfaceId | interfaceId, |
| in TToiAddressAcquisition | acquisition | ||
| ) | raises (TToiInvalidArgumentException, TToiInvalidPreconditionException) |
Sets the IP address acquisition method for network interface.
| interfaceId | Interface identifier. |
| acquisition | IP address acquisition method. |
| TToiInvalidArgumentException | Raised if interface identifier is invalid. |
| TToiInvalidPreconditionException | Raised if configuration is not in session mode. |
| void ToiNetIpDevice::setEnabled | ( | in TToiInterfaceId | interfaceId, |
| in boolean | enable | ||
| ) | raises (TToiInvalidArgumentException, TToiInvalidPreconditionException) |
Enables/disables network interface.
| interfaceId | Interface identifier. |
| enable | Enable/disable flag. |
| TToiInvalidArgumentException | Raised if interface identifier is invalid. |
| TToiInvalidPreconditionException | Raised if configuration is not in session mode. |
| void ToiNetIpDevice::setStaticAddress | ( | in TToiInterfaceId | interfaceId, |
| in string | ip, | ||
| in string | netmask | ||
| ) | raises (TToiInvalidArgumentException, TToiInvalidPreconditionException) |
Sets static IP address and netmask for network interface.
| interfaceId | Interface identifier. |
| ip | IP address. |
| netmask | Netmask. |
| TToiInvalidArgumentException | Raised if interface identifier, IP address or netmask are invalid. |
| TToiInvalidPreconditionException | Raised if IP acquisition method is not static or if configuration is not in session mode. |
The IP address acquisition method is DHCP.
This constant can also be accessed from toi.consts.ToiNetIpDevice.ADDRESS_ACQUISITION_DHCP.
The IP address acquisition method is static.
This constant can also be accessed from toi.consts.ToiNetIpDevice.ADDRESS_ACQUISITION_STATIC.
Default interface identifier.
This constant can also be accessed from toi.consts.ToiNetIpDevice.DEFAULT_INTERFACE.