Get Ip and Mac address

Get IP and MAC address of a device using JAVA code, along with class type of IP address.