Im Decompiled apk, respectively, appeared .java files, But some files have in the name of such "AudioPlayerActivity$$Lambda$1.java", what is this "$$Lambda$1"??
Asked
Active
Viewed 912 times
3
-
Those are classes that the compiler generated automatically. – Antimony Mar 12 '17 at 20:37
1 Answers
3
"AudioPlayerActivity$$Lambda$1.java" these is basically an anonymous block of code written inside the "AudioPlayerActivity.java", now the "AudioPlayerActivity.java" can have any number of anonymous block of code, so while decompiling it, all these blocks gets converted into separate classes with a number at the end in a sequential order. Let's take an example, I have a class HelloWorld.java which contains a block
runOnUiThread(new Runnable() {
@Override
public void run() {
}
});
and another anonymous block for a clicklistener on button like this.
button.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
}
});
then on decompiling i would get 3 classes helloworld.smali, helloworld$1.smali (with code for runOnUithread) and helloworld$2.smali (with code for onClickListener).

Ravinder Bhandari
- 2,546
- 21
- 25