/** * Answer all the registered validators as they were defined by the extension points. That is * answer the validators as if the user has never applied any customizations. * * @return Answer an empty array if there are no validators. */ public static Validator[] getDefaultValidators() throws InvocationTargetException { Map<String, Validator> extVals = ExtensionValidators.instance().getMapV2(); TreeSet<Validator> sorted = new TreeSet<Validator>(); for (Validator v : extVals.values()) sorted.add(v); IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot(); GlobalConfiguration gc = new GlobalConfiguration(root); gc.resetToDefault(); for (ValidatorMetaData vmd : gc.getValidators()) { Validator v = Validator.create(vmd, gc, null); v.setBuildValidation(vmd.isBuildValidation()); v.setManualValidation(vmd.isManualValidation()); sorted.add(v); } Validator[] val = new Validator[sorted.size()]; sorted.toArray(val); return val; }