internal EFRefactoringOperation( EFNormalizableItem objectToRename, string newName, EFRenameContributorInput contributorInput, IServiceProvider serviceProvider) : base(serviceProvider) { Debug.Assert(contributorInput != null, "contributorInput != null"); _contributorInput = contributorInput; _newName = newName; _objectToRename = objectToRename; }
private static void RefactorRenameElementInDesignerOnly(EFNormalizableItem namedObject, string newName, bool showPreview) { Debug.Assert(namedObject != null, "namedObject != null"); Debug.Assert(newName != null, "namedObject != newName"); var input = new EFRenameContributorInput(namedObject, newName, namedObject.Name.Value); var refactoringOperation = new EFRefactoringOperation( namedObject, newName, input, new ServiceProviderHelper(PackageManager.Package.GetService(typeof(IServiceProvider)) as IServiceProvider)); refactoringOperation.HasPreviewWindow = showPreview; refactoringOperation.DoOperation(); }