public static long convertTimeZone(long time,double fromZone,double toZone)
    {
        int MIN_GMT = -12;
        int MAX_GMT = 13;

        if (fromZone < MIN_GMT || fromZone > MAX_GMT) {
            return -1;
        }

        if (toZone < MIN_GMT || toZone > MAX_GMT) {
            return -1;
        }

        double diff = toZone - fromZone;
        return time + (int) (diff * HOUR);
    }