/** * <p>Determines a country-specific weekend as non-business days. </p> * * @param country locale with country information * @return HolidayModel * @see Weekmodel#weekend() */ /*[deutsch] * <p>Bestimmt ein länderspezifisches Wochenende als arbeitsfreie Tage. </p> * * @param country locale with country information * @return HolidayModel * @see Weekmodel#weekend() */ static HolidayModel ofWeekend(Locale country) { return date -> date.matches(Weekmodel.of(country).weekend()); }
/** * <p>Does this date fall on a week-end in given country? </p> * * @param country country setting with two-letter ISO-3166-code * @return {@code true} if in given country this date is on weekend * else {@code false} * @see Weekmodel#weekend() */ /*[deutsch] * <p>Liegt das Datum im angegebenen Land an einem Wochenende? </p> * * @param country country setting with two-letter ISO-3166-code * @return {@code true} if in given country this date is on weekend * else {@code false} * @see Weekmodel#weekend() */ public boolean isWeekend(Locale country) { return this.matches(Weekmodel.of(country).weekend()); }