https://github.com/appium/java-client/issues/52 is almost finished.