Constructors

Link copied to clipboard
constructor()
constructor(method: Method)
constructor(constructor: Constructor<*>)
constructor(descriptor: String)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
Link copied to clipboard

The method declared class fully qualified name.

----------------

Link copied to clipboard

The method descriptor.

----------------

Link copied to clipboard

Method modifiers. Match using java.lang.reflect.Modifier mask bits, default match type is contains, if you need to match exactly, please use modifiers overloaded function.

Link copied to clipboard
Link copied to clipboard

The method name.

----------------

Link copied to clipboard
Link copied to clipboard

This method uses consecutive OP instructions.

----------------

Link copied to clipboard
Link copied to clipboard

This method uses consecutive smali instructions.

----------------

Link copied to clipboard

The method parameter count.

----------------

Link copied to clipboard
Link copied to clipboard

The method parameter types fully qualified name. If set to null, it means matching any parameter type. The list implies the number of parameters.

Link copied to clipboard

The method return type fully qualified name.

----------------

Link copied to clipboard
Link copied to clipboard

This method using numbers. To avoid floating point precision error, the number is considered equal when the value error is less than 1e-6.

Link copied to clipboard

Using string list. Default match type is contains, if you need to match exactly, please use usingStrings or addUsingString overloaded function for each string.

Functions

Link copied to clipboard

Add method annotation matcher.

----------------

Link copied to clipboard
inline fun addCall(init: MethodMatcher.() -> Unit): MethodMatcher
fun addCall(methodDescriptor: String): MethodMatcher
Link copied to clipboard
inline fun addCaller(init: MethodMatcher.() -> Unit): MethodMatcher

fun addCaller(methodDescriptor: String): MethodMatcher

Adds a matcher for when this method is called by a specified method.

----------------

Link copied to clipboard
fun addEqString(usingString: String): MethodMatcher

Add using string(fuzzy match).

----------------

Link copied to clipboard
inline fun addInvoke(init: MethodMatcher.() -> Unit): MethodMatcher

fun addInvoke(methodDescriptor: String): MethodMatcher

Add a matcher that calls the method corresponding to the descriptor.

----------------

This method calls the matcher for the specified method.

----------------

Link copied to clipboard
fun addParamType(paramType: Class<*>?): MethodMatcher

Add method parameter type class matcher.

----------------

inline fun addParamType(init: ClassMatcher.() -> Unit): MethodMatcher

fun addParamType(paramType: String?, matchType: StringMatchType = StringMatchType.Equals, ignoreCase: Boolean = false): MethodMatcher

Add method parameter type fully qualified name. If set to null, it means matching any parameter type.

Link copied to clipboard

fun addUsingField(fieldDescriptor: String, usingType: UsingType = UsingType.Any): MethodMatcher
fun addUsingField(usingField: FieldMatcher, usingType: UsingType = UsingType.Any): MethodMatcher

Using fields matcher.

----------------

Link copied to clipboard

Add using number matcher. To avoid floating point precision error, the number is considered equal when the value error is less than 1e-6.

Link copied to clipboard

Add using string matcher.

----------------

fun addUsingString(usingString: String, matchType: StringMatchType = StringMatchType.Contains, ignoreCase: Boolean = false): MethodMatcher

Add using string.

----------------

Link copied to clipboard

Method annotation count.

----------------

fun annotationCount(min: Int = 0, max: Int = Int.MAX_VALUE): MethodMatcher

Method annotation count range.

----------------

Link copied to clipboard

The method annotations matcher.

----------------

Link copied to clipboard

The matcher for when this method is called by the specified set of methods.

----------------

Link copied to clipboard
Link copied to clipboard

The method declared class.

----------------

inline fun declaredClass(init: ClassMatcher.() -> Unit): MethodMatcher

The method declared class matcher.

----------------

fun declaredClass(className: String, matchType: StringMatchType = StringMatchType.Equals, ignoreCase: Boolean = false): MethodMatcher

The method declared class fully qualified name.

----------------

Link copied to clipboard
fun descriptor(descriptor: String): MethodMatcher

The method descriptor, specifies a unique method.

----------------

Link copied to clipboard

This method calls the matcher for the specified methods set.

----------------

Link copied to clipboard

Method modifiers matcher.

----------------

fun modifiers(modifiers: Int, matchType: MatchType = MatchType.Contains): MethodMatcher

Method modifiers. Match using java.lang.reflect.Modifier mask bits.

----------------

Link copied to clipboard

The method name matcher

----------------

fun name(name: String, matchType: StringMatchType = StringMatchType.Equals, ignoreCase: Boolean = false): MethodMatcher

The method name.

----------------

Link copied to clipboard

This method uses opcodes matcher

----------------

fun opCodes(opCodes: Collection<Int>, matchType: OpCodeMatchType = OpCodeMatchType.Contains, opCodeSize: IntRange? = null): MethodMatcher

This method uses consecutive OP instructions.

----------------

Link copied to clipboard
fun opNames(opNames: Collection<String>, matchType: OpCodeMatchType = OpCodeMatchType.Contains, opCodeSize: IntRange? = null): MethodMatcher

This method uses consecutive smali instructions.

----------------

Link copied to clipboard

The method parameter count.

----------------

fun paramCount(min: Int = 0, max: Int = Int.MAX_VALUE): MethodMatcher

The method parameter count range.

----------------

Link copied to clipboard
inline fun params(init: ParametersMatcher.() -> Unit): MethodMatcher

The method parameter types matcher.

----------------

Link copied to clipboard

empty parameters overload.

----------------

fun paramTypes(vararg paramTypes: Class<*>?): MethodMatcher

The method parameter types class matcher. If set to null, it means matching any parameter type. The list implies the number of parameters.

fun paramTypes(vararg paramTypes: String?): MethodMatcher

The method parameter types fully qualified name. If set to null, it means matching any parameter type. The list implies the number of parameters.

Link copied to clipboard

The method return type.

----------------

inline fun returnType(init: ClassMatcher.() -> Unit): MethodMatcher

The method return type matcher.

----------------

fun returnType(typeName: String, matchType: StringMatchType = StringMatchType.Equals, ignoreCase: Boolean = false): MethodMatcher

The method return type fully qualified name.

----------------

Link copied to clipboard
fun usingEqStrings(vararg usingStrings: String): MethodMatcher

Using strings matcher(fuzzy match).

----------------

Link copied to clipboard

Using fields matcher.

----------------

Link copied to clipboard
fun usingNumbers(vararg usingNumbers: Number): MethodMatcher

Using numbers matcher. To avoid floating point precision error, the number is considered equal when the value error is less than 1e-6.


Using numbers matcher.

----------------

Link copied to clipboard
fun usingStrings(vararg usingStrings: String): MethodMatcher

Using strings matcher. default match type is contains, if you need to match exactly, please use usingStrings or addUsingString overloaded function for each string.


fun usingStrings(usingStrings: Collection<String>, matchType: StringMatchType = StringMatchType.Contains, ignoreCase: Boolean = false): MethodMatcher

Using strings matcher.

----------------