Get IP Address or MAC Address of iOS Device or iOS Simulator

Put this method into your class & you can obtain the IP address of current device. To obtain MAC address, put following code.