// Path: itl/src/main/java/org/arabeyes/itl/prayertime/Dms.java
// @SuppressWarnings("WeakerAccess")
// public class Dms implements Comparable<Dms> {
//     private final int deg;
//     private final int min;
//     private final double sec;
// 
//     /**
//      * All numbers should be either positive or negative. Mixed sign has no meaning.
//      *
//      * @param deg degree
//      * @param min -60 <= minute <= 60
//      * @param sec -60 <= second <= 60
//      * @throws IllegalArgumentException if sign is not consistent or exceeds the range
//      */
//     public Dms(int deg, int min, double sec) {
//         if (min > 60 || sec > 60.0 ||
//                 (deg > 0 && (min < 0 || sec < 0)) ||
//                 (deg < 0 && (min > 0 || sec > 0)))
//             throw new IllegalArgumentException(String.format("deg=%s, min=%s, sec=%s", deg, min, sec));
//         this.deg = deg;
//         this.min = min;
//         this.sec = sec;
//     }
// 
//     public static Dms fromDecimal(double decimal) {
//         return PrayerModule.decimal2Dms(decimal);
//     }
// 
//     public int getDegree() {
//         return deg;
//     }
// 
//     public int getMinute() {
//         return min;
//     }
// 
//     public double getSecond() {
//         return sec;
//     }
// 
//     public double toDecimal() {
//         return PrayerModule.dms2Decimal(deg, min, sec, ' ');
//     }
// 
//     /**
//      * Returns string representation in d°m′s.sss...″ format.
//      */
//     @Override
//     public String toString() {
//         String sign = "";
//         if (deg < 0 || min < 0 || sec < 0.0)
//             sign = "-";
//         return sign + abs(deg) + '°' + abs(min) + '′' + abs(sec) + '″';
//     }
// 
//     /**
//      * Returns string representation in d°m′s.sss...″ format.
//      *
//      * @param secFormat used for positive/negative prefix/suffix of DMS and decimal format of
//      *                  second
//      */
//     public String toString(DecimalFormat secFormat) {
//         String pre = deg < 0 || min < 0 || sec < 0.0 ? secFormat.getNegativePrefix() :
//                 secFormat.getPositivePrefix();
//         String post = deg < 0 || min < 0 || sec < 0.0 ? secFormat.getNegativeSuffix() :
//                 secFormat.getPositiveSuffix();
//         return pre + abs(deg) + '°' + abs(min) + '′' + secFormat.format(abs(sec)) + '″' + post;
//     }
// 
//     @Override
//     public boolean equals(Object o) {
//         if (this == o) return true;
//         if (o == null || getClass() != o.getClass()) return false;
// 
//         Dms dms = (Dms) o;
//         return deg == dms.deg && min == dms.min && Double.compare(dms.sec, sec) == 0;
//     }
// 
//     @Override
//     public int hashCode() {
//         int result = deg;
//         result = 31 * result + min;
//         long temp = Double.doubleToLongBits(sec);
//         result = 31 * result + (int) (temp ^ (temp >>> 32));
//         return result;
//     }
// 
//     /**
//      * See {@link Comparable#compareTo(Object)}
//      *
//      * @throws ClassCastException if different class
//      */
//     @Override
//     public int compareTo(Dms dms) {
//         if (getClass() != dms.getClass())
//             throw new ClassCastException("Can't compare with instance of " + dms.getClass());
// 
//         if (deg != dms.deg) return deg - dms.deg;
//         if (min != dms.min) return min - dms.min;
//         return Double.compare(sec, dms.sec);
//     }
// }


import org.arabeyes.itl.prayertime.Dms;
import java.util.Calendar;
import java.util.Date;
import java.util.GregorianCalendar;
import java.util.TimeZone;
        location.latitude = latitude;
        location.longitude = longitude;
        location.altitude = altitude;
        return this;
    }

    public Prayer setDate(GregorianCalendar cal) {
        this.date = new DefsModule.date_t().set(cal.get(Calendar.DAY_OF_MONTH),
                cal.get(Calendar.MONTH) + 1, cal.get(Calendar.YEAR));
        this.location.timezone = cal.get(Calendar.ZONE_OFFSET) / (1000.0 * 60 * 60);
        this.location.daylight = (int) Math.round(cal.get(Calendar.DST_OFFSET) / (1000.0 * 60 * 60));
        return this;
    }

    public Prayer setDate(Date date, TimeZone timeZone) {
        GregorianCalendar cal = new GregorianCalendar(timeZone);
        cal.setTime(date);
        return setDate(cal);
    }

    public PrayerTimes getPrayerTimes() {
        requireMethods();
        requireDate();
        requireLocation();

        PrayerTimes result = new PrayerTimes();
        PrayerModule.get_prayer_times(date, location, result);
        return result;
    }

// Path: itl/src/main/java/org/arabeyes/itl/prayertime/Dms.java
// @SuppressWarnings("WeakerAccess")
// public class Dms implements Comparable<Dms> {
//     private final int deg;
//     private final int min;
//     private final double sec;
// 
//     /**
//      * All numbers should be either positive or negative. Mixed sign has no meaning.
//      *
//      * @param deg degree
//      * @param min -60 <= minute <= 60
//      * @param sec -60 <= second <= 60
//      * @throws IllegalArgumentException if sign is not consistent or exceeds the range
//      */
//     public Dms(int deg, int min, double sec) {
//         if (min > 60 || sec > 60.0 ||
//                 (deg > 0 && (min < 0 || sec < 0)) ||
//                 (deg < 0 && (min > 0 || sec > 0)))
//             throw new IllegalArgumentException(String.format("deg=%s, min=%s, sec=%s", deg, min, sec));
//         this.deg = deg;
//         this.min = min;
//         this.sec = sec;
//     }
// 
//     public static Dms fromDecimal(double decimal) {
//         return PrayerModule.decimal2Dms(decimal);
//     }
// 
//     public int getDegree() {
//         return deg;
//     }
// 
//     public int getMinute() {
//         return min;
//     }
// 
//     public double getSecond() {
//         return sec;
//     }
// 
//     public double toDecimal() {
//         return PrayerModule.dms2Decimal(deg, min, sec, ' ');
//     }
// 
//     /**
//      * Returns string representation in d°m′s.sss...″ format.
//      */
//     @Override
//     public String toString() {
//         String sign = "";
//         if (deg < 0 || min < 0 || sec < 0.0)
//             sign = "-";
//         return sign + abs(deg) + '°' + abs(min) + '′' + abs(sec) + '″';
//     }
// 
//     /**
//      * Returns string representation in d°m′s.sss...″ format.
//      *
//      * @param secFormat used for positive/negative prefix/suffix of DMS and decimal format of
//      *                  second
//      */
//     public String toString(DecimalFormat secFormat) {
//         String pre = deg < 0 || min < 0 || sec < 0.0 ? secFormat.getNegativePrefix() :
//                 secFormat.getPositivePrefix();
//         String post = deg < 0 || min < 0 || sec < 0.0 ? secFormat.getNegativeSuffix() :
//                 secFormat.getPositiveSuffix();
//         return pre + abs(deg) + '°' + abs(min) + '′' + secFormat.format(abs(sec)) + '″' + post;
//     }
// 
//     @Override
//     public boolean equals(Object o) {
//         if (this == o) return true;
//         if (o == null || getClass() != o.getClass()) return false;
// 
//         Dms dms = (Dms) o;
//         return deg == dms.deg && min == dms.min && Double.compare(dms.sec, sec) == 0;
//     }
// 
//     @Override
//     public int hashCode() {
//         int result = deg;
//         result = 31 * result + min;
//         long temp = Double.doubleToLongBits(sec);
//         result = 31 * result + (int) (temp ^ (temp >>> 32));
//         return result;
//     }
// 
//     /**
//      * See {@link Comparable#compareTo(Object)}
//      *
//      * @throws ClassCastException if different class
//      */
//     @Override
//     public int compareTo(Dms dms) {
//         if (getClass() != dms.getClass())
//             throw new ClassCastException("Can't compare with instance of " + dms.getClass());
// 
//         if (deg != dms.deg) return deg - dms.deg;
//         if (min != dms.min) return min - dms.min;
//         return Double.compare(sec, dms.sec);
//     }
// }


// Path: itl/src/main/java/org/arabeyes/itl/newmethod/Prayer.java
import org.arabeyes.itl.prayertime.Dms;
import java.util.Calendar;
import java.util.Date;
import java.util.GregorianCalendar;
import java.util.TimeZone;

        location.latitude = latitude;
        location.longitude = longitude;
        location.altitude = altitude;
        return this;
    }

    public Prayer setDate(GregorianCalendar cal) {
        this.date = new DefsModule.date_t().set(cal.get(Calendar.DAY_OF_MONTH),
                cal.get(Calendar.MONTH) + 1, cal.get(Calendar.YEAR));
        this.location.timezone = cal.get(Calendar.ZONE_OFFSET) / (1000.0 * 60 * 60);
        this.location.daylight = (int) Math.round(cal.get(Calendar.DST_OFFSET) / (1000.0 * 60 * 60));
        return this;
    }

    public Prayer setDate(Date date, TimeZone timeZone) {
        GregorianCalendar cal = new GregorianCalendar(timeZone);
        cal.setTime(date);
        return setDate(cal);
    }

    public PrayerTimes getPrayerTimes() {
        requireMethods();
        requireDate();
        requireLocation();

        PrayerTimes result = new PrayerTimes();
        PrayerModule.get_prayer_times(date, location, result);
        return result;
    }

    public Dms getQiblaDirection() {