code: private File createTempFile(byte[] content) {
  
          try {
              File file = File.createTempFile("ocms-moduleresource-", ".dat");
              file.deleteOnExit();
              try (FileOutputStream output = new FileOutputStream(file)) {
                  output.write(content);
              }
              return file;
          } catch (Exception e) {
              throw new RuntimeException(e);
          }
      }
docs: Creates a temp file to store the given content.<p>
  
  @param content the content to store in the temp file
  
  @return the created temp file