org.eclipse.jdt.internal.core
Class CreateInitializerOperation

java.lang.Object
  extended by org.eclipse.jdt.internal.core.JavaModelOperation
      extended by org.eclipse.jdt.internal.core.CreateElementInCUOperation
          extended by org.eclipse.jdt.internal.core.CreateTypeMemberOperation
              extended by org.eclipse.jdt.internal.core.CreateInitializerOperation
All Implemented Interfaces:
IWorkspaceRunnable, org.eclipse.core.runtime.IProgressMonitor

public class CreateInitializerOperation
extends CreateTypeMemberOperation

This operation creates a initializer in a type.

Required Attributes:


Field Summary
 
Fields inherited from class org.eclipse.jdt.internal.core.JavaModelOperation
HAS_MODIFIED_RESOURCE_ATTR, progressMonitor, TRUE
 
Fields inherited from interface org.eclipse.core.runtime.IProgressMonitor
UNKNOWN
 
Constructor Summary
CreateInitializerOperation(IType parentElement, java.lang.String source)
          When executed, this operation will create an initializer with the given name in the given type with the specified source.
 
Method Summary
 java.lang.String getMainTaskName()
          Returns the name of the main task of this operation for progress reporting.
 
Methods inherited from class org.eclipse.jdt.internal.core.CreateTypeMemberOperation
verify
 
Methods inherited from class org.eclipse.jdt.internal.core.CreateElementInCUOperation
createAfter, createBefore
 
Methods inherited from class org.eclipse.jdt.internal.core.JavaModelOperation
beginTask, done, executeNestedOperation, getJavaModel, getResultElements, hasModifiedResource, internalWorked, isCanceled, isReadOnly, newJavaElementDelta, run, runOperation, setCanceled, setTaskName, subTask, worked
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CreateInitializerOperation

public CreateInitializerOperation(IType parentElement,
                                  java.lang.String source)
When executed, this operation will create an initializer with the given name in the given type with the specified source.

By default the new initializer is positioned after the last existing initializer declaration, or as the first member in the type if there are no initializers.

Method Detail

getMainTaskName

public java.lang.String getMainTaskName()
Description copied from class: CreateElementInCUOperation
Returns the name of the main task of this operation for progress reporting.

Specified by:
getMainTaskName in class CreateElementInCUOperation
See Also:
CreateElementInCUOperation.getMainTaskName()