You can declare the method to be final, as in:
public final String getId() {
...
}
For more info, see http://docs.oracle.com/javase/tutorial/java/IandI/final.html
You can declare the method to be final, as in:
public final String getId() {
...
}
For more info, see http://docs.oracle.com/javase/tutorial/java/IandI/final.html