model.load(in, resourceSet.getLoadOptions());
TranslationUnit trunit = (TranslationUnit) model.getContents().get(0);
BasicDiagnostic bd = new BasicDiagnostic();
IDLJavaValidator idlValidator = new IDLJavaValidator();
idlValidator.validate(trunit, bd, new HashMap<Object,Object>());
new ShowErrors().show(bd);
if (bd.getSeverity() == Diagnostic.ERROR)
System.exit(-1);