Did I have to redeclare buttons and edittext in subclass in Android Java? | Sololearn: Learn to code for FREE!
Novo curso! Todo programador deveria aprender IA generativa!
Experimente uma aula grƔtis
0

Did I have to redeclare buttons and edittext in subclass in Android Java?

Suppose I have a superclass A which contains EditText and a button having protected access modifier. The button on press sets the text to Edittext (say Everytime the button is pressed "a" is inserted into Edittext. Suppose I want to extend this class and in subclass their is nothing which I declared. Suppose the content of subclass contains same Edittext and button having same function. Did I have to rewrite the code for button press or did it just inherit from superclass. Please provide some exple with code.

30th Jan 2019, 2:49 AM
Sheikh Zakir Ahmad
Sheikh Zakir Ahmad - avatar
1 Resposta
28th May 2019, 2:00 PM
ŠŠ½Š“рŠµŠ¹ Š§Š°Ń‡ŠøŠ½, Andrew Chachin
ŠŠ½Š“рŠµŠ¹ Š§Š°Ń‡ŠøŠ½, Andrew Chachin - avatar