A quick way to solve this is to cast your driver reference. In your Android-specific code sections, if you know the driver object type will be an AndroidDriver, you can cast the driver reference from the AppiumDriver type to an AndroidDriver type. Be sure that you actually are working on an AndroidDriver in the Android-specific sections, however. If you're wrong, you will run into ClassCastExceptions, which means you should really double-check your code!