throw new GenerationException(
"Class " + pageClass.getFullyQualifiedName() + " is annotated with @Page, so it must be a subtype " +
"of Widget.");
}
Page annotation = pageClass.getAnnotation(Page.class);
String pageName = annotation.path().equals("") ? pageClass.getName() : annotation.path();
MetaClass prevPageWithThisName = pageNames.put(pageName, pageClass);
if (prevPageWithThisName != null) {
throw new GenerationException(
"Page names must be unique, but " + prevPageWithThisName + " and " + pageClass +