protected void loadInferenceSemantics(final ModeldocFactory factory,
ModelDocumentation root, String plugin, String pkg,
String name, File file) throws IOException, SemanticHandlerException {
// create a TemplateFile for this template file
final TemplateFile templateFile = factory.createTemplateFile();
templateFile.setPlugin(plugin);
templateFile.setPackage(pkg);
templateFile.setName(name);
root.getReferences().add(templateFile);
BasicJavadocParser parser = new BasicJavadocParser(getSemanticTagHandlers());
parser.findJavadocTagsInTextFile(file, this, factory, root, new IJavadocReferenceCreator() {
public JavaElement createReference(String[] lines, int line) {
Template ref = createTemplate(factory, line, lines);
if (ref != null) {
templateFile.getTemplates().add(ref);
}
return ref;
}
});