KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > jdt > internal > ui > refactoring > reorg > RenameEnumConstWizard


1 /*******************************************************************************
2  * Copyright (c) 2000, 2005 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11 package org.eclipse.jdt.internal.ui.refactoring.reorg;
12
13 import org.eclipse.jdt.internal.ui.IJavaHelpContextIds;
14 import org.eclipse.jdt.internal.ui.JavaPluginImages;
15 import org.eclipse.jdt.internal.ui.refactoring.RefactoringMessages;
16
17 import org.eclipse.ltk.core.refactoring.Refactoring;
18 import org.eclipse.ltk.core.refactoring.RefactoringStatus;
19
20 public final class RenameEnumConstWizard extends RenameRefactoringWizard {
21
22     public RenameEnumConstWizard(Refactoring refactoring) {
23         super(refactoring, RefactoringMessages.RenameEnumConstWizard_defaultPageTitle, RefactoringMessages.RenameEnumConstWizard_inputPage_description, JavaPluginImages.DESC_WIZBAN_REFACTOR_FIELD, IJavaHelpContextIds.RENAME_FIELD_WIZARD_PAGE);
24     }
25
26     protected RenameInputWizardPage createInputPage(String JavaDoc message, String JavaDoc initialSetting) {
27         return new RenameInputWizardPage(message, IJavaHelpContextIds.RENAME_FIELD_WIZARD_PAGE, true, initialSetting) {
28
29             protected RefactoringStatus validateTextField(String JavaDoc text) {
30                 return validateNewName(text);
31             }
32         };
33     }
34 }
35
Popular Tags