Package sootup.java.core
Class JavaSootMethod
java.lang.Object
sootup.core.model.SootClassMember<MethodSignature>
sootup.core.model.SootMethod
sootup.java.core.JavaSootMethod
- All Implemented Interfaces:
HasPosition
,Method
,HasAnnotation
- Direct Known Subclasses:
JavaAnnotationSootMethod
,WalaSootMethod
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
static class
Defines aJavaSootField.JavaSootFieldBuilder
to provide a fluent API.Nested classes/interfaces inherited from class sootup.core.model.SootMethod
SootMethod.BuildStep, SootMethod.MethodSourceStep, SootMethod.ModifierStep, SootMethod.SignatureStep, SootMethod.SootMethodBuilder, SootMethod.ThrownExceptionsStep
-
Field Summary
Fields inherited from class sootup.core.model.SootMethod
bodySource, exceptions, parameterTypes
-
Constructor Summary
ConstructorDescriptionJavaSootMethod
(BodySource source, MethodSignature methodSignature, Iterable<MethodModifier> modifiers, Iterable<ClassType> thrownExceptions, Iterable<AnnotationUsage> annotations, Position position) -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
withAnnotations
(Iterable<AnnotationUsage> annotations) withModifiers
(Iterable<MethodModifier> modifiers) Creates a new SootMethod based on a newOverridingBodySource
.withSource
(BodySource source) withThrownExceptions
(Iterable<ClassType> thrownExceptions) Methods inherited from class sootup.core.model.SootMethod
equals, equivHashCode, getBody, getBodySource, getExceptionSignatures, getModifiers, getParameterCount, getParameterType, getParameterTypes, getReturnType, hasBody, hashCode, isAbstract, isConcrete, isFinal, isMain, isNative, isPrivate, isProtected, isPublic, isStatic, isSynchronized, toString
Methods inherited from class sootup.core.model.SootClassMember
getDeclaringClassType, getName, getPosition, getSignature, toString
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface sootup.core.model.Method
getSignature
-
Constructor Details
-
JavaSootMethod
public JavaSootMethod(@Nonnull BodySource source, @Nonnull MethodSignature methodSignature, @Nonnull Iterable<MethodModifier> modifiers, @Nonnull Iterable<ClassType> thrownExceptions, @Nonnull Iterable<AnnotationUsage> annotations, @Nonnull Position position)
-
-
Method Details
-
getAnnotations
- Specified by:
getAnnotations
in interfaceHasAnnotation
-
withOverridingMethodSource
@Nonnull public JavaSootMethod withOverridingMethodSource(@Nonnull Function<OverridingBodySource, OverridingBodySource> overrider) Description copied from class:SootMethod
Creates a new SootMethod based on a newOverridingBodySource
. This is useful to change selected parts of aSootMethod
without recreating aBodySource
completely.OverridingBodySource
allows for replacing the body of a method.- Overrides:
withOverridingMethodSource
in classSootMethod
-
withSource
- Overrides:
withSource
in classSootMethod
-
withModifiers
- Overrides:
withModifiers
in classSootMethod
-
withThrownExceptions
- Overrides:
withThrownExceptions
in classSootMethod
-
withAnnotations
-
withBody
- Overrides:
withBody
in classSootMethod
-
builder
-