private static Formats getMacFormats() {
    var cf = Native.load("CoreFoundation", CF.class);
    var localeRef = cf.CFLocaleCopyCurrent();
    try {
      var date = getMacFormat(cf, localeRef, CF.kCFDateFormatterShortStyle, CF.kCFDateFormatterNoStyle);
      var timeShort = getMacFormat(cf, localeRef, CF.kCFDateFormatterNoStyle, CF.kCFDateFormatterShortStyle);
      var timeMedium = getMacFormat(cf, localeRef, CF.kCFDateFormatterNoStyle, CF.kCFDateFormatterMediumStyle);
      var dateTime = getMacFormat(cf, localeRef, CF.kCFDateFormatterShortStyle, CF.kCFDateFormatterShortStyle);
      var localeId = getMacString(cf, cf.CFLocaleGetIdentifier(localeRef));
      if (LOG.isTraceEnabled()) LOG.trace("id=" + localeId);
      var locale = getLocaleById(localeId);
      return makeFormats(date, timeShort, timeMedium, dateTime, locale);
    }
    finally {
      cf.CFRelease(localeRef);
    }
  }
private static Formats getMacFormats()