private IFileModificationValidator loadUIValidator() { IExtensionPoint extension = Platform.getExtensionRegistry().getExtensionPoint(ID, DEFAULT_FILE_MODIFICATION_VALIDATOR_EXTENSION); if (extension != null) { IExtension[] extensions = extension.getExtensions(); if (extensions.length > 0) { IConfigurationElement[] configElements = extensions[0].getConfigurationElements(); if (configElements.length > 0) { try { Object o = configElements[0].createExecutableExtension("class"); //$NON-NLS-1$ if (o instanceof IFileModificationValidator) { return (IFileModificationValidator)o; } } catch (CoreException e) { SVNProviderPlugin.log(e.getStatus().getSeverity(), e.getMessage(), e); } } } } return null; }
/** * This is the old-style (Eclipse 3.1-) file modification validator API. * * {@inheritDoc} */ @Override public IFileModificationValidator getFileModificationValidator() { synchronized (modificationValidatorLock) { if (modificationValidatorLegacy == null) { modificationValidatorLegacy = new TFSFileModificationValidatorLegacy(modificationValidator); } return modificationValidatorLegacy; } }
public IFileModificationValidator getFileModificationValidator() { return new SVNFileModificationValidator(); }