Final keyword in Java
Final keyword in Java can be used in multiple places and I have seen whole chapters dedicated to this particular topic.
But, I want to share a very brief but to-the-point understanding of the final keyword in this article.
If you are using final keyword for any member(local variable/instance variable/method) it means there is no way that you can modify the value of that particular variable(if method, then you can’t override that method) throughout your program.
If you are declaring a class as final, then, it means that no other class(in same or different package) can extend that class(final class), in other words the final class can never be subclassed, but, the final class can be used as the “Superclass reference”.
Superclass reference just means that it can be used polymorphycially
Third is the case which you are referring to. If any object reference variable is declared as final, then it means that the final reference variable can never ever in its entire life refer to a different object but the data within the object(the object your reference variable is referring to) can be modified.
Hope it clears some of the concepts.