code: @Route(method = HttpMethod.GET, uri = "i18n/bundles/{file<.+>}.properties")
      public Result getBundleResource(@PathParameter("file") String file,
                                      @HttpParameter(HeaderNames.IF_NONE_MATCH) String ifNoneMatch) {
  
          // Extract the locale from file
          if (Strings.isNullOrEmpty(file)) {
              return notFound().as(MimeTypes.TEXT);
          }
  
          Locale locale = InternationalizationService.DEFAULT_LOCALE;
          if (file.contains("_")) {
              // We got a locale
              locale = Locale.forLanguageTag(file.substring(file.indexOf('_') + 1).replace("_", "-"));
          }
  
          // Check if we have received a etag
          String etag = service.etag(locale);
          if (ifNoneMatch != null && ifNoneMatch.equals(etag)) {
              return new Result(Status.NOT_MODIFIED);
          }
  
          Collection<ResourceBundle> bundles = service.bundles(locale);
  
          // Do we have this locale
          if (bundles.isEmpty()) {
              // No, return not found
              return notFound().as(MimeTypes.TEXT);
          } else {
              StringBuilder builder = new StringBuilder();
              for (ResourceBundle bundle : bundles) {
                  for (String key : bundle.keySet()) {
                      builder.append(key).append("=").append(bundle.getString(key)).append("\n");
                  }
              }
              return ok(builder.toString()).as(MimeTypes.TEXT).with(HeaderNames.ETAG, etag);
          }
      }
docs: Gets the internationalized message as a Java resource bundle (property file).
  
  @param file        the name of the file indicating the requested locale
  @param ifNoneMatch the received ETAG if any
  @return the result containing the messages as properties.