public class DeleteMethodPrimitive extends MethodPrimitive
| Modifier and Type | Field and Description |
|---|---|
protected com.github.javaparser.ast.body.MethodDeclaration |
declaration |
protected com.github.javaparser.ast.body.MethodDeclaration |
invoker |
exceptionClasses, exceptions, modifiers, parameterClasses, returnClasschangesClassHierarchy, classContent, clazz, modifiedClasses| Constructor and Description |
|---|
DeleteMethodPrimitive(ClassContent classContent,
java.lang.String name,
java.lang.Class<?> returnClass,
java.lang.Class<?>[] parameterClasses) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
executePrimitive()
Deletes one method and its invoker from the source code of the class
|
boolean |
isSafe()
Returns if the primitive is safe or not.
|
protected void |
undoPrimitive()
Reverts the changes
|
getBodyInvoker, getDescriptor, getInvokerDescriptor, setThrowschangeVersion, execute, getSuperClass, getTargetClass, undo, undoUpdateVersion, updateVersion, updateVersionprotected com.github.javaparser.ast.body.MethodDeclaration declaration
protected com.github.javaparser.ast.body.MethodDeclaration invoker
public DeleteMethodPrimitive(ClassContent classContent, java.lang.String name, java.lang.Class<?> returnClass, java.lang.Class<?>[] parameterClasses)
protected void executePrimitive()
throws StructuralIntercessionException
executePrimitive in class AbstractPrimitiveStructuralIntercessionException - If there are any errorprotected void undoPrimitive()
throws StructuralIntercessionException
undoPrimitive in class AbstractPrimitiveStructuralIntercessionException - If there are any errorpublic boolean isSafe()
AbstractPrimitiveisSafe in interface PrimitiveisSafe in class AbstractPrimitive