How to determine which button pressed on android

Viewed 52782

i need to know, how to recognize, which button is pressed. Like if i have two buttons ,say button 1 and button2,and both of them performing the same method, say method(),how to determine which button pressed ?

Regards

5 Answers
Related