@Override public ISchedulingRule computeCommitRule() { IResourceRuleFactory factory= ResourcesPlugin.getWorkspace().getRuleFactory(); return factory.modifyRule(fFile); }
/** * Obtains the scheduling rule from the appropriate factory for a modify operation. */ @Override public ISchedulingRule modifyRule(IResource resource) { if (resource.getType() == IResource.ROOT) return root; return factoryFor(resource).modifyRule(resource); }
protected ISchedulingRule getSchedulingRule() { if (this.elementsToProcess != null && this.elementsToProcess.length == 1) { IResource resource = this.elementsToProcess[0].getResource(); if (resource != null) return ResourcesPlugin.getWorkspace().getRuleFactory().modifyRule(resource); } return super.getSchedulingRule(); } /**
protected ISchedulingRule getSchedulingRule() { if (this.elementsToProcess != null && this.elementsToProcess.length == 1) { IResource resource = this.elementsToProcess[0].getResource(); if (resource != null) return ResourcesPlugin.getWorkspace().getRuleFactory().modifyRule(resource); } return super.getSchedulingRule(); } /**
@Override protected ISchedulingRule getSchedulingRule() { if (this.elementsToProcess != null && this.elementsToProcess.length == 1) { IResource resource = this.elementsToProcess[0].getResource(); if (resource != null) return ResourcesPlugin.getWorkspace().getRuleFactory().modifyRule(resource); } return super.getSchedulingRule(); } /**
protected ISchedulingRule getSchedulingRule() { if (this.canChangeResources) { IResourceRuleFactory ruleFactory = ResourcesPlugin.getWorkspace().getRuleFactory(); return new MultiRule(new ISchedulingRule[] { // use project modification rule as this is needed to create the .classpath file if it doesn't exist yet, or to update project references ruleFactory.modifyRule(this.project.getProject()), // and external project modification rule in case the external folders are modified ruleFactory.modifyRule(JavaModelManager.getExternalManager().getExternalFoldersProject()) }); } return super.getSchedulingRule(); }
protected ISchedulingRule getSchedulingRule() { if (this.canChangeResources) { IResourceRuleFactory ruleFactory = ResourcesPlugin.getWorkspace().getRuleFactory(); return new MultiRule(new ISchedulingRule[] { // use project modification rule as this is needed to create the .classpath file if it doesn't exist yet, or to update project references ruleFactory.modifyRule(this.project.getProject()), // and external project modification rule in case the external folders are modified ruleFactory.modifyRule(JavaModelManager.getExternalManager().getExternalFoldersProject()) }); } return super.getSchedulingRule(); }
@Override protected ISchedulingRule getSchedulingRule() { if (this.canChangeResources) { IResourceRuleFactory ruleFactory = ResourcesPlugin.getWorkspace().getRuleFactory(); return new MultiRule(new ISchedulingRule[] { // use project modification rule as this is needed to create the .classpath file if it doesn't exist yet, or to update project references ruleFactory.modifyRule(this.project.getProject()), // and external project modification rule in case the external folders are modified ruleFactory.modifyRule(JavaModelManager.getExternalManager().getExternalFoldersProject()) }); } return super.getSchedulingRule(); }
private void run(ReplaceOperation operation, IResource resource) throws InvocationTargetException, InterruptedException { IResourceRuleFactory ruleFactory = ResourcesPlugin.getWorkspace().getRuleFactory(); ISchedulingRule rule= ruleFactory.modifyRule(resource); PlatformUI.getWorkbench().getProgressService().runInUI(this, operation, rule); }
protected ISchedulingRule getSchedulingRule() { IResource resource = getCompilationUnit().getResource(); IWorkspace workspace = resource.getWorkspace(); return workspace.getRuleFactory().modifyRule(resource); } /**
protected ISchedulingRule getSchedulingRule() { IResource resource = getCompilationUnit().getResource(); IWorkspace workspace = resource.getWorkspace(); return workspace.getRuleFactory().modifyRule(resource); } /**
@Override protected ISchedulingRule getSchedulingRule() { IResource resource = getCompilationUnit().getResource(); IWorkspace workspace = resource.getWorkspace(); return workspace.getRuleFactory().modifyRule(resource); } /**
protected ISchedulingRule getSchedulingRule() { IResource resource = getCompilationUnit().getResource(); IWorkspace workspace = resource.getWorkspace(); return workspace.getRuleFactory().modifyRule(resource); } /**
protected ISchedulingRule getSchedulingRule() { IResource resource = getCompilationUnit().getResource(); IWorkspace workspace = resource.getWorkspace(); return workspace.getRuleFactory().modifyRule(resource); } /**
protected ISchedulingRule getSchedulingRule() { IResource resource = getElementToProcess().getResource(); if (resource == null) return null; IWorkspace workspace = resource.getWorkspace(); if (resource.exists()) { return workspace.getRuleFactory().modifyRule(resource); } else { return workspace.getRuleFactory().createRule(resource); } } /**
@Override protected ISchedulingRule getSchedulingRule() { IResource resource = getElementToProcess().getResource(); if (resource == null) return null; IWorkspace workspace = resource.getWorkspace(); if (resource.exists()) { return workspace.getRuleFactory().modifyRule(resource); } else { return workspace.getRuleFactory().createRule(resource); } } /**
@Override protected ISchedulingRule getSchedulingRule() { IResource resource = getCompilationUnit().getResource(); IWorkspace workspace = resource.getWorkspace(); if (resource.exists()) { return workspace.getRuleFactory().modifyRule(resource); } else { return workspace.getRuleFactory().createRule(resource); } } /**
protected ISchedulingRule getSchedulingRule() { IResource resource = getCompilationUnit().getResource(); IWorkspace workspace = resource.getWorkspace(); if (resource.exists()) { return workspace.getRuleFactory().modifyRule(resource); } else { return workspace.getRuleFactory().createRule(resource); } } /**
protected ISchedulingRule getSchedulingRule() { IResource resource = getCompilationUnit().getResource(); IWorkspace workspace = resource.getWorkspace(); if (resource.exists()) { return workspace.getRuleFactory().modifyRule(resource); } else { return workspace.getRuleFactory().createRule(resource); } } /**
protected ISchedulingRule getSchedulingRule() { IResource resource = getElementToProcess().getResource(); if (resource == null) return null; IWorkspace workspace = resource.getWorkspace(); if (resource.exists()) { return workspace.getRuleFactory().modifyRule(resource); } else { return workspace.getRuleFactory().createRule(resource); } } /**