Can we declare an anonymous class as both extending a class
and implementing an interface?
Answer Posted / imtiyaz
sorry i will take back my words...
as Devnaga said anonymous class will be created by extending
a class or implementing interface.
you can't to do both at a time simply saying
new SomeClass() extends someOther
we can't write in the same way
new SomeClass() implements someOther
we Can't That's it
| Is This Answer Correct ? | 3 Yes | 2 No |
Post New Answer View All Answers
What is 32 bit float?
Make a data structure and implement an algorithm to print all the files in a directory. (The root directory can have sub-directories too.)
can I implement my own start() method? : Java thread
Why array is used in java?
What are java packages? What's the significance of packages?
What is anagram number?
What is a null point?
What is the flag in java?
What are the concepts of 'OOPS'?
What is a parameter in a function?
What are the six ways to use this keyword?
Will the compiler creates a default constructor if I have a parameterized constructor in the class?
What data structures are used to perform recursion?
Where are local variables stored?
What is the purpose of static methods and variables?