Refactory: remove unused classes, imports, fields and methods.
authorincastrix <incastrix>
Wed, 23 Dec 2009 17:47:09 +0000 (17:47 +0000)
committerincastrix <incastrix>
Wed, 23 Dec 2009 17:47:09 +0000 (17:47 +0000)
12 files changed:
net.sourceforge.phpeclipse.ui/src/net/sourceforge/phpdt/ui/CodeGeneration.java
net.sourceforge.phpeclipse.ui/src/net/sourceforge/phpdt/ui/JavaElementImageDescriptor.java
net.sourceforge.phpeclipse.ui/src/net/sourceforge/phpdt/ui/JavaElementLabelProvider.java
net.sourceforge.phpeclipse.ui/src/net/sourceforge/phpdt/ui/JavaElementSorter.java
net.sourceforge.phpeclipse.ui/src/net/sourceforge/phpdt/ui/JavaUI.java
net.sourceforge.phpeclipse.ui/src/net/sourceforge/phpdt/ui/OverrideIndicatorLabelDecorator.java
net.sourceforge.phpeclipse.ui/src/net/sourceforge/phpdt/ui/ProblemsLabelDecorator.java
net.sourceforge.phpeclipse.ui/src/net/sourceforge/phpdt/ui/StandardJavaElementContentProvider.java
net.sourceforge.phpeclipse.ui/src/net/sourceforge/phpdt/ui/text/JavaTextTools.java
net.sourceforge.phpeclipse.ui/src/net/sourceforge/phpdt/ui/wizards/NewClassWizardPage.java
net.sourceforge.phpeclipse.ui/src/net/sourceforge/phpdt/ui/wizards/NewContainerWizardPage.java
net.sourceforge.phpeclipse.ui/src/net/sourceforge/phpdt/ui/wizards/NewTypeWizardPage.java

index 05dacb0..274f574 100644 (file)
@@ -47,12 +47,12 @@ public class CodeGeneration {
         * @throws CoreException
         *             Thrown when the evaluation of the code template fails.
         */
-       public static String getCompilationUnitContent(ICompilationUnit cu,
-                       String typeComment, String typeContent, String lineDelimiter)
-                       throws CoreException {
-               return StubUtility.getCompilationUnitContent(cu, typeComment,
-                               typeContent, lineDelimiter);
-       }
+//     public static String getCompilationUnitContent(ICompilationUnit cu,
+//                     String typeComment, String typeContent, String lineDelimiter)
+//                     throws CoreException {
+//             return StubUtility.getCompilationUnitContent(cu, typeComment,
+//                             typeContent, lineDelimiter);
+//     }
 
        /**
         * Returns the content for a new type comment using the 'type comment' code
@@ -100,11 +100,11 @@ public class CodeGeneration {
         *             Thrown when the evaluation of the code template fails.
         * @since 3.0
         */
-       public static String getFieldComment(ICompilationUnit cu, String typeName,
-                       String fieldName, String lineDelimiter) throws CoreException {
-               return StubUtility.getFieldComment(cu, typeName, fieldName,
-                               lineDelimiter);
-       }
+//     public static String getFieldComment(ICompilationUnit cu, String typeName,
+//                     String fieldName, String lineDelimiter) throws CoreException {
+//             return StubUtility.getFieldComment(cu, typeName, fieldName,
+//                             lineDelimiter);
+//     }
 
        /**
         * Returns the comment for a method or constructor using the comment code
@@ -248,13 +248,13 @@ public class CodeGeneration {
         * @throws CoreException
         *             Thrown when the evaluation of the code template fails.
         */
-       public static String getMethodBodyContent(ICompilationUnit cu,
-                       String declaringTypeName, String methodName, boolean isConstructor,
-                       String bodyStatement, String lineDelimiter) throws CoreException {
-               return StubUtility.getMethodBodyContent(isConstructor, cu
-                               .getJavaProject(), declaringTypeName, methodName,
-                               bodyStatement, lineDelimiter);
-       }
+//     public static String getMethodBodyContent(ICompilationUnit cu,
+//                     String declaringTypeName, String methodName, boolean isConstructor,
+//                     String bodyStatement, String lineDelimiter) throws CoreException {
+//             return StubUtility.getMethodBodyContent(isConstructor, cu
+//                             .getJavaProject(), declaringTypeName, methodName,
+//                             bodyStatement, lineDelimiter);
+//     }
 
        /**
         * Returns the content of body for a getter method using the getter method
@@ -284,12 +284,12 @@ public class CodeGeneration {
         *             Thrown when the evaluation of the code template fails.
         * @since 3.0
         */
-       public static String getGetterMethodBodyContent(ICompilationUnit cu,
-                       String declaringTypeName, String methodName, String fieldName,
-                       String lineDelimiter) throws CoreException {
-               return StubUtility.getGetterMethodBodyContent(cu.getJavaProject(),
-                               declaringTypeName, methodName, fieldName, lineDelimiter);
-       }
+//     public static String getGetterMethodBodyContent(ICompilationUnit cu,
+//                     String declaringTypeName, String methodName, String fieldName,
+//                     String lineDelimiter) throws CoreException {
+//             return StubUtility.getGetterMethodBodyContent(cu.getJavaProject(),
+//                             declaringTypeName, methodName, fieldName, lineDelimiter);
+//     }
 
        /**
         * Returns the content of body for a setter method using the setter method
@@ -322,13 +322,13 @@ public class CodeGeneration {
         *             Thrown when the evaluation of the code template fails.
         * @since 3.0
         */
-       public static String getSetterMethodBodyContent(ICompilationUnit cu,
-                       String declaringTypeName, String methodName, String fieldName,
-                       String paramName, String lineDelimiter) throws CoreException {
-               return StubUtility.getSetterMethodBodyContent(cu.getJavaProject(),
-                               declaringTypeName, methodName, fieldName, paramName,
-                               lineDelimiter);
-       }
+//     public static String getSetterMethodBodyContent(ICompilationUnit cu,
+//                     String declaringTypeName, String methodName, String fieldName,
+//                     String paramName, String lineDelimiter) throws CoreException {
+//             return StubUtility.getSetterMethodBodyContent(cu.getJavaProject(),
+//                             declaringTypeName, methodName, fieldName, paramName,
+//                             lineDelimiter);
+//     }
 
        /**
         * Returns the comment for a getter method using the getter comment
index 73e456a..f7261d0 100644 (file)
@@ -111,9 +111,9 @@ public class JavaElementImageDescriptor extends CompositeImageDescriptor {
         * 
         * @return the current adornments
         */
-       public int getAdronments() {
-               return fFlags;
-       }
+//     public int getAdronments() {
+//             return fFlags;
+//     }
 
        /**
         * Sets the size of the image created by calling <code>createImage()</code>.
@@ -123,11 +123,11 @@ public class JavaElementImageDescriptor extends CompositeImageDescriptor {
         *            <code>createImage()</code>
         * @see ImageDescriptor#createImage()
         */
-       public void setImageSize(Point size) {
-               Assert.isNotNull(size);
-               Assert.isTrue(size.x >= 0 && size.y >= 0);
-               fSize = size;
-       }
+//     public void setImageSize(Point size) {
+//             Assert.isNotNull(size);
+//             Assert.isTrue(size.x >= 0 && size.y >= 0);
+//             fSize = size;
+//     }
 
        /**
         * Returns the size of the image created by calling
index 44eb464..c93397c 100644 (file)
@@ -145,9 +145,9 @@ public class JavaElementLabelProvider extends LabelProvider {
         * @see #SHOW_DEFAULT
         * @since 2.0
         */
-       public JavaElementLabelProvider() {
-               this(SHOW_DEFAULT);
-       }
+//     public JavaElementLabelProvider() {
+//             this(SHOW_DEFAULT);
+//     }
 
        /**
         * Creates a new label provider.
@@ -174,11 +174,11 @@ public class JavaElementLabelProvider extends LabelProvider {
         * @param flags
         *            the options; a bitwise OR of <code>SHOW_* </code> constants
         */
-       public void turnOn(int flags) {
-               fFlags |= flags;
-               updateImageProviderFlags();
-               updateTextProviderFlags();
-       }
+//     public void turnOn(int flags) {
+//             fFlags |= flags;
+//             updateImageProviderFlags();
+//             updateTextProviderFlags();
+//     }
 
        /**
         * Turns off the rendering options specified in the given flags.
@@ -187,11 +187,11 @@ public class JavaElementLabelProvider extends LabelProvider {
         *            the initial options; a bitwise OR of <code>SHOW_* </code>
         *            constants
         */
-       public void turnOff(int flags) {
-               fFlags &= (~flags);
-               updateImageProviderFlags();
-               updateTextProviderFlags();
-       }
+//     public void turnOff(int flags) {
+//             fFlags &= (~flags);
+//             updateImageProviderFlags();
+//             updateTextProviderFlags();
+//     }
 
        private void updateImageProviderFlags() {
                fImageFlags = 0;
index 2d66b7d..f9476e1 100644 (file)
@@ -99,9 +99,9 @@ public class JavaElementSorter extends ViewerSorter {
         *             ViewerSorter#isSorterProperty(Object, String). Method could
         *             be removed, but kept for API compatibility.
         */
-       public boolean isSorterProperty(Object element, Object property) {
-               return true;
-       }
+//     public boolean isSorterProperty(Object element, Object property) {
+//             return true;
+//     }
 
        /*
         * @see ViewerSorter#category
index ae2fecf..e4f597c 100644 (file)
 package net.sourceforge.phpdt.ui;
 
 import net.sourceforge.phpdt.core.IBufferFactory;
-import net.sourceforge.phpdt.core.IJavaElement;
-import net.sourceforge.phpdt.core.IWorkingCopy;
-import net.sourceforge.phpdt.core.JavaCore;
-import net.sourceforge.phpdt.core.JavaModelException;
+//import net.sourceforge.phpdt.core.IJavaElement;
+//import net.sourceforge.phpdt.core.IWorkingCopy;
+//import net.sourceforge.phpdt.core.JavaCore;
+//import net.sourceforge.phpdt.core.JavaModelException;
 import net.sourceforge.phpeclipse.PHPeclipsePlugin;
-import net.sourceforge.phpeclipse.phpeditor.EditorUtility;
-import net.sourceforge.phpeclipse.ui.WebUI;
+//import net.sourceforge.phpeclipse.phpeditor.EditorUtility;
+//import net.sourceforge.phpeclipse.ui.WebUI;
 
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.ISharedImages;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.internal.SharedImages;
-import org.eclipse.ui.texteditor.IDocumentProvider;
+//import org.eclipse.ui.IEditorPart;
+//import org.eclipse.ui.ISharedImages;
+//import org.eclipse.ui.PartInitException;
+//import org.eclipse.ui.internal.SharedImages;
+//import org.eclipse.ui.texteditor.IDocumentProvider;
 
 /**
  * Central access point for the Java UI plug-in (id
@@ -41,7 +41,7 @@ import org.eclipse.ui.texteditor.IDocumentProvider;
  */
 public final class JavaUI {
 
-       private static ISharedImages fgSharedImages = null;
+//     private static ISharedImages fgSharedImages = null;
 
        private JavaUI() {
                // prevent instantiation of JavaUI.
@@ -208,12 +208,12 @@ public final class JavaUI {
         * 
         * @return the shared images manager
         */
-       public static ISharedImages getSharedImages() {
-               if (fgSharedImages == null)
-                       fgSharedImages = new SharedImages();
-
-               return fgSharedImages;
-       }
+//     public static ISharedImages getSharedImages() {
+//             if (fgSharedImages == null)
+//                     fgSharedImages = new SharedImages();
+//
+//             return fgSharedImages;
+//     }
 
        /**
         * Creates a selection dialog that lists all packages of the given Java
@@ -588,10 +588,10 @@ public final class JavaUI {
         *                if this element does not exist or if an exception occurs
         *                while accessing its underlying resource
         */
-       public static IEditorPart openInEditor(IJavaElement element)
-                       throws JavaModelException, PartInitException {
-               return EditorUtility.openInEditor(element);
-       }
+//     public static IEditorPart openInEditor(IJavaElement element)
+//                     throws JavaModelException, PartInitException {
+//             return EditorUtility.openInEditor(element);
+//     }
 
        /**
         * Reveals the source range of the given source reference element in the
@@ -637,9 +637,9 @@ public final class JavaUI {
         * 
         * @return the working copy manager for the Java UI plug-in
         */
-       public static IWorkingCopyManager getWorkingCopyManager() {
-               return WebUI.getDefault().getWorkingCopyManager();
-       }
+//     public static IWorkingCopyManager getWorkingCopyManager() {
+//             return WebUI.getDefault().getWorkingCopyManager();
+//     }
 
        /**
         * Answers the shared working copies currently registered for the Java
@@ -651,9 +651,9 @@ public final class JavaUI {
         * @see net.sourceforge.phpdt.core.JavaCore#getSharedWorkingCopies(net.sourceforge.phpdt.core.IBufferFactory)
         * @since 2.0
         */
-       public static IWorkingCopy[] getSharedWorkingCopies() {
-               return JavaCore.getSharedWorkingCopies(getBufferFactory());
-       }
+//     public static IWorkingCopy[] getSharedWorkingCopies() {
+//             return JavaCore.getSharedWorkingCopies(getBufferFactory());
+//     }
 
        /**
         * Answers the shared working copies that are on the class path of a Java
@@ -704,10 +704,10 @@ public final class JavaUI {
         * @see IDocumentProvider
         * @since 2.0
         */
-       public static IDocumentProvider getDocumentProvider() {
-               return WebUI.getDefault()
-                               .getCompilationUnitDocumentProvider();
-       }
+//     public static IDocumentProvider getDocumentProvider() {
+//             return WebUI.getDefault()
+//                             .getCompilationUnitDocumentProvider();
+//     }
 
        /**
         * Sets the Javadoc location for an archive with the given path.
index 1aed547..8418417 100644 (file)
@@ -51,10 +51,10 @@ public class OverrideIndicatorLabelDecorator implements ILabelDecorator,
         * Creates a decorator. The decorator creates an own image registry to cache
         * images.
         */
-       public OverrideIndicatorLabelDecorator() {
-               this(null);
-               fUseNewRegistry = true;
-       }
+//     public OverrideIndicatorLabelDecorator() {
+//             this(null);
+//             fUseNewRegistry = true;
+//     }
 
        /*
         * Creates decorator with a shared image registry.
index 76017cd..4beed98 100644 (file)
@@ -73,6 +73,10 @@ public class ProblemsLabelDecorator implements ILabelDecorator,
        public static class ProblemsLabelChangedEvent extends
                        LabelProviderChangedEvent {
 
+               /**
+                * 
+                */
+               private static final long serialVersionUID = -7557704732816971319L;
                private boolean fMarkerChange;
 
                /**
@@ -114,10 +118,10 @@ public class ProblemsLabelDecorator implements ILabelDecorator,
        /**
         * Creates a new <code>ProblemsLabelDecorator</code>.
         */
-       public ProblemsLabelDecorator() {
-               this(null);
-               fUseNewRegistry = true;
-       }
+//     public ProblemsLabelDecorator() {
+//             this(null);
+//             fUseNewRegistry = true;
+//     }
 
        /*
         * Creates decorator with a shared image registry.
index 87d461c..5c10738 100644 (file)
@@ -15,7 +15,7 @@ import java.util.List;
 
 import net.sourceforge.phpdt.core.ICompilationUnit;
 import net.sourceforge.phpdt.core.IJavaElement;
-import net.sourceforge.phpdt.core.IJavaElementDelta;
+//import net.sourceforge.phpdt.core.IJavaElementDelta;
 import net.sourceforge.phpdt.core.IJavaModel;
 import net.sourceforge.phpdt.core.IJavaProject;
 import net.sourceforge.phpdt.core.IPackageFragment;
@@ -109,8 +109,8 @@ public class StandardJavaElementContentProvider implements
         * members of compilation units or class files and it does not provide
         * working copy elements.
         */
-       public StandardJavaElementContentProvider() {
-       }
+//     public StandardJavaElementContentProvider() {
+//     }
 
        /**
         * Creates a new <code>StandardJavaElementContentProvider</code>.
@@ -137,9 +137,9 @@ public class StandardJavaElementContentProvider implements
         * @return <code>true</code> if the content provider provides members;
         *         otherwise <code>false</code> is returned
         */
-       public boolean getProvideMembers() {
-               return fProvideMembers;
-       }
+//     public boolean getProvideMembers() {
+//             return fProvideMembers;
+//     }
 
        /**
         * Sets whether the content provider is supposed to return members when
@@ -150,9 +150,9 @@ public class StandardJavaElementContentProvider implements
         *            <code>false</code> compilation units and class files are the
         *            leaves provided by this content provider.
         */
-       public void setProvideMembers(boolean b) {
-               fProvideMembers = b;
-       }
+//     public void setProvideMembers(boolean b) {
+//             fProvideMembers = b;
+//     }
 
        /**
         * Returns whether the provided members are from a working copy or the
@@ -163,9 +163,9 @@ public class StandardJavaElementContentProvider implements
         * 
         * @see #setProvideWorkingCopy(boolean)
         */
-       public boolean getProvideWorkingCopy() {
-               return fProvideWorkingCopy;
-       }
+//     public boolean getProvideWorkingCopy() {
+//             return fProvideWorkingCopy;
+//     }
 
        /**
         * Sets whether the members are provided from a shared working copy that
@@ -176,9 +176,9 @@ public class StandardJavaElementContentProvider implements
         *            copy if one exists in JDT core. If <code>false</code> the
         *            provider always returns original elements.
         */
-       public void setProvideWorkingCopy(boolean b) {
-               fProvideWorkingCopy = b;
-       }
+//     public void setProvideWorkingCopy(boolean b) {
+//             fProvideWorkingCopy = b;
+//     }
 
        /*
         * (non-Javadoc)
@@ -384,17 +384,17 @@ public class StandardJavaElementContentProvider implements
         * Note: This method is for internal use only. Clients should not call this
         * method.
         */
-       protected boolean isClassPathChange(IJavaElementDelta delta) {
-
-               // need to test the flags only for package fragment roots
-               if (delta.getElement().getElementType() != IJavaElement.PACKAGE_FRAGMENT_ROOT)
-                       return false;
-
-               int flags = delta.getFlags();
-               return (delta.getKind() == IJavaElementDelta.CHANGED
-                               && ((flags & IJavaElementDelta.F_ADDED_TO_CLASSPATH) != 0)
-                               || ((flags & IJavaElementDelta.F_REMOVED_FROM_CLASSPATH) != 0) || ((flags & IJavaElementDelta.F_REORDER) != 0));
-       }
+//     protected boolean isClassPathChange(IJavaElementDelta delta) {
+//
+//             // need to test the flags only for package fragment roots
+//             if (delta.getElement().getElementType() != IJavaElement.PACKAGE_FRAGMENT_ROOT)
+//                     return false;
+//
+//             int flags = delta.getFlags();
+//             return (delta.getKind() == IJavaElementDelta.CHANGED
+//                             && ((flags & IJavaElementDelta.F_ADDED_TO_CLASSPATH) != 0)
+//                             || ((flags & IJavaElementDelta.F_REMOVED_FROM_CLASSPATH) != 0) || ((flags & IJavaElementDelta.F_REORDER) != 0));
+//     }
 
        /**
         * Note: This method is for internal use only. Clients should not call this
@@ -414,18 +414,18 @@ public class StandardJavaElementContentProvider implements
         * Note: This method is for internal use only. Clients should not call this
         * method.
         */
-       protected boolean isPackageFragmentEmpty(IJavaElement element)
-                       throws JavaModelException {
-               if (element instanceof IPackageFragment) {
-                       IPackageFragment fragment = (IPackageFragment) element;
-                       if (!(fragment.hasChildren()))
-                               // ||
-                               // fragment.getNonJavaResources().length > 0) &&
-                               // fragment.hasSubpackages())
-                               return true;
-               }
-               return false;
-       }
+//     protected boolean isPackageFragmentEmpty(IJavaElement element)
+//                     throws JavaModelException {
+//             if (element instanceof IPackageFragment) {
+//                     IPackageFragment fragment = (IPackageFragment) element;
+//                     if (!(fragment.hasChildren()))
+//                             // ||
+//                             // fragment.getNonJavaResources().length > 0) &&
+//                             // fragment.hasSubpackages())
+//                             return true;
+//             }
+//             return false;
+//     }
 
        /**
         * Note: This method is for internal use only. Clients should not call this
@@ -499,13 +499,13 @@ public class StandardJavaElementContentProvider implements
         * Note: This method is for internal use only. Clients should not call this
         * method.
         */
-       protected static Object[] concatenate(Object[] a1, Object[] a2) {
-               int a1Len = a1.length;
-               int a2Len = a2.length;
-               Object[] res = new Object[a1Len + a2Len];
-               System.arraycopy(a1, 0, res, 0, a1Len);
-               System.arraycopy(a2, 0, res, a1Len, a2Len);
-               return res;
-       }
+//     protected static Object[] concatenate(Object[] a1, Object[] a2) {
+//             int a1Len = a1.length;
+//             int a2Len = a2.length;
+//             Object[] res = new Object[a1Len + a2Len];
+//             System.arraycopy(a1, 0, res, 0, a1Len);
+//             System.arraycopy(a2, 0, res, a1Len, a2Len);
+//             return res;
+//     }
 
 }
index 7506a59..4431f9d 100644 (file)
@@ -25,9 +25,9 @@ import org.eclipse.jface.preference.IPreferenceStore;
 import org.eclipse.jface.text.IDocument;
 import org.eclipse.jface.text.IDocumentExtension3;
 import org.eclipse.jface.text.IDocumentPartitioner;
-import org.eclipse.jface.text.rules.DefaultPartitioner;
+//import org.eclipse.jface.text.rules.DefaultPartitioner;
 import org.eclipse.jface.text.rules.FastPartitioner;
-import org.eclipse.jface.text.rules.RuleBasedScanner;
+//import org.eclipse.jface.text.rules.RuleBasedScanner;
 import org.eclipse.jface.util.IPropertyChangeListener;
 import org.eclipse.jface.util.PropertyChangeEvent;
 
@@ -298,9 +298,9 @@ public class JavaTextTools implements IPHPPartitions {
         * 
         * @return a Java source code scanner
         */
-       public RuleBasedScanner getCodeScanner() {
-               return fCodeScanner;
-       }
+//     public RuleBasedScanner getCodeScanner() {
+//             return fCodeScanner;
+//     }
 
        /**
         * Returns a scanner which is configured to scan Java multiline comments.
@@ -309,9 +309,9 @@ public class JavaTextTools implements IPHPPartitions {
         * 
         * @since 2.0
         */
-       public RuleBasedScanner getMultilineCommentScanner() {
-               return fMultilineCommentScanner;
-       }
+//     public RuleBasedScanner getMultilineCommentScanner() {
+//             return fMultilineCommentScanner;
+//     }
 
        /**
         * Returns a scanner which is configured to scan HTML code.
@@ -330,9 +330,9 @@ public class JavaTextTools implements IPHPPartitions {
         * 
         * @since 2.0
         */
-       public RuleBasedScanner getSmartyScanner() {
-               return fSmartyScanner;
-       }
+//     public RuleBasedScanner getSmartyScanner() {
+//             return fSmartyScanner;
+//     }
 
        /**
         * Returns a scanner which is configured to scan Smarty code.
@@ -341,9 +341,9 @@ public class JavaTextTools implements IPHPPartitions {
         * 
         * @since 2.0
         */
-       public RuleBasedScanner getSmartyDocScanner() {
-               return fSmartyDocScanner;
-       }
+//     public RuleBasedScanner getSmartyDocScanner() {
+//             return fSmartyDocScanner;
+//     }
 
        /**
         * Returns a scanner which is configured to scan Java singleline comments.
@@ -352,9 +352,9 @@ public class JavaTextTools implements IPHPPartitions {
         * 
         * @since 2.0
         */
-       public RuleBasedScanner getSinglelineCommentScanner() {
-               return fSinglelineCommentScanner;
-       }
+//     public RuleBasedScanner getSinglelineCommentScanner() {
+//             return fSinglelineCommentScanner;
+//     }
 
        /**
         * Returns a scanner which is configured to scan Java strings.
@@ -373,9 +373,9 @@ public class JavaTextTools implements IPHPPartitions {
         * 
         * @return a JavaDoc scanner
         */
-       public RuleBasedScanner getJavaDocScanner() {
-               return fPHPDocScanner;
-       }
+//     public RuleBasedScanner getJavaDocScanner() {
+//             return fPHPDocScanner;
+//     }
 
        /**
         * Returns a scanner which is configured to scan Java-specific partitions,
@@ -504,9 +504,9 @@ public class JavaTextTools implements IPHPPartitions {
         * @return the partition managing position categories or <code>null</code>
         *         if there is none
         */
-       public String[] getPartitionManagingPositionCategories() {
-               return new String[] { DefaultPartitioner.CONTENT_TYPES_CATEGORY };
-       }
+//     public String[] getPartitionManagingPositionCategories() {
+//             return new String[] { DefaultPartitioner.CONTENT_TYPES_CATEGORY };
+//     }
 
        /**
         * Determines whether the preference change encoded by the given event
@@ -731,7 +731,7 @@ public class JavaTextTools implements IPHPPartitions {
         * @return the core preference store
         * @since 3.0
         */
-       protected Preferences getCorePreferenceStore() {
-               return fCorePreferenceStore;
-       }
+//     protected Preferences getCorePreferenceStore() {
+//             return fCorePreferenceStore;
+//     }
 }
\ No newline at end of file
index 4203e32..2172de7 100644 (file)
@@ -79,7 +79,7 @@ public class NewClassWizardPage extends NewTypeWizardPage {
         */
        public void init(IStructuredSelection selection) {
                IJavaElement jelem = getInitialJavaElement(selection);
-               initContainerPage(jelem);
+               //initContainerPage(jelem);
                initTypePage(jelem);
                doStatusUpdate();
 
@@ -189,9 +189,9 @@ public class NewClassWizardPage extends NewTypeWizardPage {
         * 
         * @return the selection state of the 'Create Main' checkbox
         */
-       public boolean isCreateMain() {
-               return fMethodStubsButtons.isSelected(0);
-       }
+//     public boolean isCreateMain() {
+//             return fMethodStubsButtons.isSelected(0);
+//     }
 
        /**
         * Returns the current selection state of the 'Create Constructors'
@@ -199,9 +199,9 @@ public class NewClassWizardPage extends NewTypeWizardPage {
         * 
         * @return the selection state of the 'Create Constructors' checkbox
         */
-       public boolean isCreateConstructors() {
-               return fMethodStubsButtons.isSelected(1);
-       }
+//     public boolean isCreateConstructors() {
+//             return fMethodStubsButtons.isSelected(1);
+//     }
 
        /**
         * Returns the current selection state of the 'Create inherited abstract
@@ -210,9 +210,9 @@ public class NewClassWizardPage extends NewTypeWizardPage {
         * @return the selection state of the 'Create inherited abstract methods'
         *         checkbox
         */
-       public boolean isCreateInherited() {
-               return fMethodStubsButtons.isSelected(2);
-       }
+//     public boolean isCreateInherited() {
+//             return fMethodStubsButtons.isSelected(2);
+//     }
 
        /**
         * Sets the selection state of the method stub checkboxes.
@@ -272,4 +272,4 @@ public class NewClassWizardPage extends NewTypeWizardPage {
        // monitor.done();
        // }
        // }
-}
+}
\ No newline at end of file
index a7857e8..58fd483 100644 (file)
@@ -95,35 +95,35 @@ public abstract class NewContainerWizardPage extends NewElementWizardPage {
         *            the Java element used to compute the initial package fragment
         *            root used as the source folder
         */
-       protected void initContainerPage(IJavaElement elem) {
-               //IPackageFragmentRoot initRoot = null;
-               // if (elem != null) {
-               // initRoot= JavaModelUtil.getPackageFragmentRoot(elem);
-               // if (initRoot == null || initRoot.isArchive()) {
-               // IJavaProject jproject= elem.getJavaProject();
-               // if (jproject != null) {
-               // try {
-               // initRoot= null;
-               // if (jproject.exists()) {
-               // IPackageFragmentRoot[] roots= jproject.getPackageFragmentRoots();
-               // for (int i= 0; i < roots.length; i++) {
-               // if (roots[i].getKind() == IPackageFragmentRoot.K_SOURCE) {
-               // initRoot= roots[i];
-               // break;
-               // }
-               // }
-               // }
-               // } catch (JavaModelException e) {
-               // PHPeclipsePlugin.log(e);
-               // }
-               // if (initRoot == null) {
-               // initRoot= jproject.getPackageFragmentRoot(jproject.getResource());
-               // }
-               // }
-               // }
-               // }
-               // setPackageFragmentRoot(initRoot, true);
-       }
+//     protected void initContainerPage(IJavaElement elem) {
+//             //IPackageFragmentRoot initRoot = null;
+//             // if (elem != null) {
+//             // initRoot= JavaModelUtil.getPackageFragmentRoot(elem);
+//             // if (initRoot == null || initRoot.isArchive()) {
+//             // IJavaProject jproject= elem.getJavaProject();
+//             // if (jproject != null) {
+//             // try {
+//             // initRoot= null;
+//             // if (jproject.exists()) {
+//             // IPackageFragmentRoot[] roots= jproject.getPackageFragmentRoots();
+//             // for (int i= 0; i < roots.length; i++) {
+//             // if (roots[i].getKind() == IPackageFragmentRoot.K_SOURCE) {
+//             // initRoot= roots[i];
+//             // break;
+//             // }
+//             // }
+//             // }
+//             // } catch (JavaModelException e) {
+//             // PHPeclipsePlugin.log(e);
+//             // }
+//             // if (initRoot == null) {
+//             // initRoot= jproject.getPackageFragmentRoot(jproject.getResource());
+//             // }
+//             // }
+//             // }
+//             // }
+//             // setPackageFragmentRoot(initRoot, true);
+//     }
 
        /**
         * Utility method to inspect a selection to find a Java element.
@@ -223,9 +223,9 @@ public abstract class NewContainerWizardPage extends NewElementWizardPage {
        /**
         * Sets the focus to the source folder's text field.
         */
-       protected void setFocusOnContainer() {
-               fContainerDialogField.setFocus();
-       }
+//     protected void setFocusOnContainer() {
+//             fContainerDialogField.setFocus();
+//     }
 
        // -------- ContainerFieldAdapter --------
 
@@ -234,7 +234,7 @@ public abstract class NewContainerWizardPage extends NewElementWizardPage {
 
                // -------- IStringButtonAdapter
                public void changeControlPressed(DialogField field) {
-                       containerChangeControlPressed(field);
+                       //containerChangeControlPressed(field);
                }
 
                // -------- IDialogFieldListener
@@ -243,21 +243,21 @@ public abstract class NewContainerWizardPage extends NewElementWizardPage {
                }
        }
 
-       private void containerChangeControlPressed(DialogField field) {
-               // take the current jproject as init element of the dialog
-               // IPackageFragmentRoot root= getPackageFragmentRoot();
-               // root= chooseSourceContainer(root);
-               // if (root != null) {
-               // setPackageFragmentRoot(root, true);
-               // }
-       }
+//     private void containerChangeControlPressed(DialogField field) {
+//             // take the current jproject as init element of the dialog
+//             // IPackageFragmentRoot root= getPackageFragmentRoot();
+//             // root= chooseSourceContainer(root);
+//             // if (root != null) {
+//             // setPackageFragmentRoot(root, true);
+//             // }
+//     }
 
        private void containerDialogFieldChanged(DialogField field) {
                if (field == fContainerDialogField) {
                        fContainerStatus = containerChanged();
                }
                // tell all others
-               handleFieldChanged(CONTAINER);
+               //handleFieldChanged(CONTAINER);
        }
 
        // ----------- validation ----------
@@ -351,8 +351,8 @@ public abstract class NewContainerWizardPage extends NewElementWizardPage {
         *            The name of the field that has changed (field id). For the
         *            source folder the field id is <code>CONTAINER</code>
         */
-       protected void handleFieldChanged(String fieldName) {
-       }
+//     protected void handleFieldChanged(String fieldName) {
+//     }
 
        // ---- get ----------------
 
@@ -473,4 +473,4 @@ public abstract class NewContainerWizardPage extends NewElementWizardPage {
        // }
        // return null;
        // }
-}
+}
\ No newline at end of file
index cde654e..50de3fe 100644 (file)
@@ -28,9 +28,9 @@ import net.sourceforge.phpdt.core.compiler.InvalidInputException;
 //import net.sourceforge.phpdt.externaltools.internal.ui.StatusInfo;
 import net.sourceforge.phpeclipse.ui.StatusInfo;
 import net.sourceforge.phpdt.internal.corext.codemanipulation.StubUtility;
-import net.sourceforge.phpdt.internal.corext.template.php.JavaContext;
-import net.sourceforge.phpdt.internal.corext.template.php.Templates;
-import net.sourceforge.phpdt.internal.corext.util.JavaModelUtil;
+//import net.sourceforge.phpdt.internal.corext.template.php.JavaContext;
+//import net.sourceforge.phpdt.internal.corext.template.php.Templates;
+//import net.sourceforge.phpdt.internal.corext.util.JavaModelUtil;
 import net.sourceforge.phpdt.internal.ui.PHPUiImages;
 import net.sourceforge.phpdt.internal.ui.util.SWTUtil;
 import net.sourceforge.phpdt.internal.ui.wizards.NewWizardMessages;
@@ -46,9 +46,9 @@ import net.sourceforge.phpdt.internal.ui.wizards.dialogfields.Separator;
 import net.sourceforge.phpdt.internal.ui.wizards.dialogfields.StringButtonDialogField;
 import net.sourceforge.phpdt.internal.ui.wizards.dialogfields.StringButtonStatusDialogField;
 import net.sourceforge.phpdt.internal.ui.wizards.dialogfields.StringDialogField;
-import net.sourceforge.phpdt.ui.CodeGeneration;
-import net.sourceforge.phpdt.ui.PreferenceConstants;
-import net.sourceforge.phpeclipse.PHPeclipsePlugin;
+//import net.sourceforge.phpdt.ui.CodeGeneration;
+//import net.sourceforge.phpdt.ui.PreferenceConstants;
+//import net.sourceforge.phpeclipse.PHPeclipsePlugin;
 
 import org.eclipse.core.runtime.CoreException;
 import org.eclipse.core.runtime.IProgressMonitor;
@@ -56,9 +56,9 @@ import org.eclipse.core.runtime.IStatus;
 import org.eclipse.core.runtime.NullProgressMonitor;
 import org.eclipse.core.runtime.SubProgressMonitor;
 //import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.jface.text.templates.Template;
-import org.eclipse.jface.text.templates.TemplateException;
+//import org.eclipse.jface.text.BadLocationException;
+//import org.eclipse.jface.text.templates.Template;
+//import org.eclipse.jface.text.templates.TemplateException;
 import org.eclipse.jface.viewers.LabelProvider;
 import org.eclipse.swt.SWT;
 import org.eclipse.swt.graphics.Image;
@@ -702,7 +702,7 @@ public abstract class NewTypeWizardPage extends NewContainerWizardPage {
         * @see net.sourceforge.phpdt.ui.wizards.NewContainerWizardPage#handleFieldChanged(String)
         */
        protected void handleFieldChanged(String fieldName) {
-               super.handleFieldChanged(fieldName);
+               //super.handleFieldChanged(fieldName);
                if (fieldName == CONTAINER) {
                        fPackageStatus = packageChanged();
                        // fEnclosingTypeStatus= enclosingTypeChanged();
@@ -728,9 +728,9 @@ public abstract class NewTypeWizardPage extends NewContainerWizardPage {
         * 
         * @return the text of the enclosing type input field
         */
-       public String getEnclosingTypeText() {
-               return fEnclosingTypeDialogField.getText();
-       }
+//     public String getEnclosingTypeText() {
+//             return fEnclosingTypeDialogField.getText();
+//     }
 
        /**
         * Returns the package fragment corresponding to the current input.
@@ -853,27 +853,27 @@ public abstract class NewTypeWizardPage extends NewContainerWizardPage {
         * @return the selected modifiers
         * @see Flags
         */
-       public int getModifiers() {
-               int mdf = 0;
-               if (fAccMdfButtons.isSelected(PUBLIC_INDEX)) {
-                       mdf += F_PUBLIC;
-               } else if (fAccMdfButtons.isSelected(PRIVATE_INDEX)) {
-                       mdf += F_PRIVATE;
-               } else if (fAccMdfButtons.isSelected(PROTECTED_INDEX)) {
-                       mdf += F_PROTECTED;
-               }
-               // if (fOtherMdfButtons.isSelected(ABSTRACT_INDEX) && (fStaticMdfIndex
-               // != 0)) {
-               // mdf+= F_ABSTRACT;
-               // }
-               if (fOtherMdfButtons.isSelected(FINAL_INDEX)) {
-                       mdf += F_FINAL;
-               }
-               if (fOtherMdfButtons.isSelected(fStaticMdfIndex)) {
-                       mdf += F_STATIC;
-               }
-               return mdf;
-       }
+//     public int getModifiers() {
+//             int mdf = 0;
+//             if (fAccMdfButtons.isSelected(PUBLIC_INDEX)) {
+//                     mdf += F_PUBLIC;
+//             } else if (fAccMdfButtons.isSelected(PRIVATE_INDEX)) {
+//                     mdf += F_PRIVATE;
+//             } else if (fAccMdfButtons.isSelected(PROTECTED_INDEX)) {
+//                     mdf += F_PROTECTED;
+//             }
+//             // if (fOtherMdfButtons.isSelected(ABSTRACT_INDEX) && (fStaticMdfIndex
+//             // != 0)) {
+//             // mdf+= F_ABSTRACT;
+//             // }
+//             if (fOtherMdfButtons.isSelected(FINAL_INDEX)) {
+//                     mdf += F_FINAL;
+//             }
+//             if (fOtherMdfButtons.isSelected(fStaticMdfIndex)) {
+//                     mdf += F_STATIC;
+//             }
+//             return mdf;
+//     }
 
        /**
         * Sets the modifiers.
@@ -887,38 +887,38 @@ public abstract class NewTypeWizardPage extends NewContainerWizardPage {
         *            otherwise they are read-only
         * @see Flags
         */
-       public void setModifiers(int modifiers, boolean canBeModified) {
-               if (Flags.isPublic(modifiers)) {
-                       fAccMdfButtons.setSelection(PUBLIC_INDEX, true);
-               } else if (Flags.isPrivate(modifiers)) {
-                       fAccMdfButtons.setSelection(PRIVATE_INDEX, true);
-               } else if (Flags.isProtected(modifiers)) {
-                       fAccMdfButtons.setSelection(PROTECTED_INDEX, true);
-               } else {
-                       fAccMdfButtons.setSelection(DEFAULT_INDEX, true);
-               }
-               // if (Flags.isAbstract(modifiers)) {
-               // fOtherMdfButtons.setSelection(ABSTRACT_INDEX, true);
-               // }
-               if (Flags.isFinal(modifiers)) {
-                       fOtherMdfButtons.setSelection(FINAL_INDEX, true);
-               }
-               if (Flags.isStatic(modifiers)) {
-                       fOtherMdfButtons.setSelection(fStaticMdfIndex, true);
-               }
-
-               fAccMdfButtons.setEnabled(canBeModified);
-               fOtherMdfButtons.setEnabled(canBeModified);
-       }
+//     public void setModifiers(int modifiers, boolean canBeModified) {
+//             if (Flags.isPublic(modifiers)) {
+//                     fAccMdfButtons.setSelection(PUBLIC_INDEX, true);
+//             } else if (Flags.isPrivate(modifiers)) {
+//                     fAccMdfButtons.setSelection(PRIVATE_INDEX, true);
+//             } else if (Flags.isProtected(modifiers)) {
+//                     fAccMdfButtons.setSelection(PROTECTED_INDEX, true);
+//             } else {
+//                     fAccMdfButtons.setSelection(DEFAULT_INDEX, true);
+//             }
+//             // if (Flags.isAbstract(modifiers)) {
+//             // fOtherMdfButtons.setSelection(ABSTRACT_INDEX, true);
+//             // }
+//             if (Flags.isFinal(modifiers)) {
+//                     fOtherMdfButtons.setSelection(FINAL_INDEX, true);
+//             }
+//             if (Flags.isStatic(modifiers)) {
+//                     fOtherMdfButtons.setSelection(fStaticMdfIndex, true);
+//             }
+//
+//             fAccMdfButtons.setEnabled(canBeModified);
+//             fOtherMdfButtons.setEnabled(canBeModified);
+//     }
 
        /**
         * Returns the content of the superclass input field.
         * 
         * @return the superclass name
         */
-       public String getSuperClass() {
-               return fSuperClassDialogField.getText();
-       }
+//     public String getSuperClass() {
+//             return fSuperClassDialogField.getText();
+//     }
 
        /**
         * Sets the super class name.
@@ -940,9 +940,9 @@ public abstract class NewTypeWizardPage extends NewContainerWizardPage {
         * @return a list of chosen super interfaces. The list's elements are of
         *         type <code>String</code>
         */
-       public List getSuperInterfaces() {
-               return fSuperInterfacesDialogField.getElements();
-       }
+//     public List getSuperInterfaces() {
+//             return fSuperInterfacesDialogField.getElements();
+//     }
 
        /**
         * Sets the super interfaces.
@@ -1798,36 +1798,36 @@ public abstract class NewTypeWizardPage extends NewContainerWizardPage {
         * @return the type comment or <code>null</code> if a type comment is not
         *         desired
         */
-       protected String getTypeComment(ICompilationUnit parentCU) {
-               if (PreferenceConstants.getPreferenceStore().getBoolean(
-                               PreferenceConstants.CODEGEN_ADD_COMMENTS)) {
-                       try {
-                               StringBuffer typeName = new StringBuffer();
-                               if (isEnclosingTypeSelected()) {
-                                       typeName.append(
-                                                       JavaModelUtil
-                                                                       .getTypeQualifiedName(getEnclosingType()))
-                                                       .append('.');
-                               }
-                               typeName.append(getTypeName());
-                               String comment = CodeGeneration.getTypeComment(parentCU,
-                                               typeName.toString(), String.valueOf('\n'));
-                               if (comment != null && isValidComment(comment)) {
-                                       return comment;
-                               }
-                       } catch (CoreException e) {
-                               PHPeclipsePlugin.log(e);
-                       }
-               }
-               return null;
-       }
+//     protected String getTypeComment(ICompilationUnit parentCU) {
+//             if (PreferenceConstants.getPreferenceStore().getBoolean(
+//                             PreferenceConstants.CODEGEN_ADD_COMMENTS)) {
+//                     try {
+//                             StringBuffer typeName = new StringBuffer();
+//                             if (isEnclosingTypeSelected()) {
+//                                     typeName.append(
+//                                                     JavaModelUtil
+//                                                                     .getTypeQualifiedName(getEnclosingType()))
+//                                                     .append('.');
+//                             }
+//                             typeName.append(getTypeName());
+//                             String comment = CodeGeneration.getTypeComment(parentCU,
+//                                             typeName.toString(), String.valueOf('\n'));
+//                             if (comment != null && isValidComment(comment)) {
+//                                     return comment;
+//                             }
+//                     } catch (CoreException e) {
+//                             PHPeclipsePlugin.log(e);
+//                     }
+//             }
+//             return null;
+//     }
 
        /**
         * @deprecated Use getTemplate(String,ICompilationUnit,int)
         */
-       protected String getTemplate(String name, ICompilationUnit parentCU) {
-               return getTemplate(name, parentCU, 0);
-       }
+//     protected String getTemplate(String name, ICompilationUnit parentCU) {
+//             return getTemplate(name, parentCU, 0);
+//     }
 
        /**
         * Returns the string resulting from evaluation the given template in the
@@ -1844,24 +1844,24 @@ public abstract class NewTypeWizardPage extends NewContainerWizardPage {
         *            a source offset into the parent compilation unit. The template
         *            is evalutated at the given source offset
         */
-       protected String getTemplate(String name, ICompilationUnit parentCU, int pos) {
-               try {
-                       Template[] templates = Templates.getInstance().getTemplates(name);
-                       if (templates.length > 0) {
-                               return JavaContext
-                                               .evaluateTemplate(templates[0], parentCU, pos);
-                       }
-               } catch (CoreException e) {
-                       PHPeclipsePlugin.log(e);
-               } catch (BadLocationException e1) {
-                       // TODO Auto-generated catch block
-                       e1.printStackTrace();
-               } catch (TemplateException e1) {
-                       // TODO Auto-generated catch block
-                       e1.printStackTrace();
-               }
-               return null;
-       }
+//     protected String getTemplate(String name, ICompilationUnit parentCU, int pos) {
+//             try {
+//                     Template[] templates = Templates.getInstance().getTemplates(name);
+//                     if (templates.length > 0) {
+//                             return JavaContext
+//                                             .evaluateTemplate(templates[0], parentCU, pos);
+//                     }
+//             } catch (CoreException e) {
+//                     PHPeclipsePlugin.log(e);
+//             } catch (BadLocationException e1) {
+//                     // TODO Auto-generated catch block
+//                     e1.printStackTrace();
+//             } catch (TemplateException e1) {
+//                     // TODO Auto-generated catch block
+//                     e1.printStackTrace();
+//             }
+//             return null;
+//     }
 
        /**
         * @deprecated Use
@@ -1954,4 +1954,4 @@ public abstract class NewTypeWizardPage extends NewContainerWizardPage {
        // }
        // };
        // }
-}
+}
\ No newline at end of file