I wanted to check whether the device is online or offline before starting specific scenarios. Is there any way to do using appium-java