The fact that a getter returns an int and that the field is an int is purely coincidental and to think otherwise is a mistake. ...If you need to change the way the object is implemented in such a way that the type of X changes, you are in deep trouble. ...