Creates a getter for a field. The field becomes private and is renamed according to the code style settings (by default, a _ prefix is added).