/** * Get the collection of files from the project that are relevant for the * validator with the given class name. * * @param files The files relevant for the class name. * @param resource The resource to look for files in. * @param validatorClassName The name of the validator class. */ protected void getFiles(Collection files, IContainer resource, String validatorClassName) { try { IResource [] resourceArray = resource.members(false); for (int i=0; i<resourceArray.length; i++) { if (ValidatorManager.getManager().isApplicableTo(validatorClassName, resourceArray[i])) { if (resourceArray[i] instanceof IFile) files.add(resourceArray[i]); } if (resourceArray[i].getType() == IResource.FOLDER) getFiles(files,(IContainer)resourceArray[i], validatorClassName) ; } } catch (Exception e) {} }
/** * Get the collection of files from the project that are relevant for the * validator with the given class name. * * @param files The files relevant for the class name. * @param resource The resource to look for files in. * @param validatorClassName The name of the validator class. */ protected void getFiles(Collection files, IContainer resource, String validatorClassName) { try { IResource [] resourceArray = resource.members(false); for (int i=0; i<resourceArray.length; i++) { if (ValidatorManager.getManager().isApplicableTo(validatorClassName, resourceArray[i])) { if (resourceArray[i] instanceof IFile) { files.add(resourceArray[i]); } } if (resourceArray[i].getType() == IResource.FOLDER) getFiles(files,(IContainer)resourceArray[i], validatorClassName) ; } } catch (Exception e) {} }