@RequestMapping(value = "/{appName}/{fileName}/{newVersion}/diff/{oldVersion}", method = RequestMethod.GET)
public String diff(@PathVariable("appName") String appName, @PathVariable("fileName") String fileName,
@PathVariable("newVersion") int newVersion, @PathVariable("oldVersion") int oldVersion,
Model model) {
checkArgument(newVersion > oldVersion, "newVersion must larger than oldVersion");
HtmlView htmlView = fileService.diff(appName, fileName, newVersion, oldVersion);
model.addAttribute("appName", appName);
model.addAttribute("fileName", fileName);
model.addAttribute("newVersion", newVersion);
model.addAttribute("oldVersion", oldVersion);
model.addAttribute("newHtml", htmlView.getNewHtml());
model.addAttribute("oldHtml", htmlView.getOldHtml());
return "diff";
}