public AbstractBuild<?, ?> getBuild(final AbstractProject<?,?> project, final int buildNumber)
throws BuildNotFoundException {
AbstractBuild<?, ?> build = findBuild(project, buildNumber);
if (build == null) {
throw new BuildNotFoundException("Build " + project.getName() + " #" + buildNumber + " could not be found.");
}
return build;
}