In the Java programming language, the keyword "final" is used
with different entity which makes it unchangeable later. We can have final
methods, final classes, final data members, final local variables and final
parameters.
1. variables: A final variable can be set once and only once.
2. methods: A final method cannot be overridden nor hidden.
3. classes: A final class cannot be extended. A final class implicitly has
all the methods as final, but not necessarily the data members.
Read more at:
http:/www.roseindia.net/javatutorials/final_methods.shtml
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.
Ask Questions? Discuss: Java final
Post your Comment