Issue
How can i call super implementation in child class, if same method is overriden in Child class ??
`
// This interface is in different File
public Interface ParentClass {
ResponseEntity<byte[]> getName(firstName, LastName) // How can i use this interface defined under getAllData
}
// This method is in different File
public class ChildClass implements ParentClass {
public getAllData(fName, lName) {
ResponseEntity<byte[]> hObject = getName(fName, lName); // this is calling below Overridden method. How to call super Implementation Interface here.
}
@Override
public getName(fName, lName) { // This is getting called everytime during service call
throw new Exception();
}
}
// Before writing this Override method i was able to access Parent Interface
`
I can't remove Override method also.. Please help me. Many Thanks in advance
Solution
// This method is in different File
public class ChildClass implements ParentClass {
public getAllData(fName, lName) {
return super.getName(fName, lName);
}
Answered By - Petr F.