private static int roundToPrecision(final int degE6, final long factor) {
        return (int) ((Math.abs(degE6) * factor + 500000L) / 1000000L);
    }
Get the fractional part of the longitude seconds scaled up by 1000 (DMS format).
main/src/main/java/cgeo/geocaching/location/Geopoint.java