title: Eclipse: How to automatically generate getter when adding a field?
body: <p>I am using TDD, and have a very typical coding pattern, using Eclipse to autocreate methods and fields as I code the unit test. For example:</p>
  
  <ol>
  <li><p>type name of method that doesn't exist, e.g:</p>
  
  <p><code>myObj.setValue(someValue);</code></p></li>
  <li><p>Click on the little red error mark in the IDE to create the "setValue" method. </p></li>
  <li><p>Type inside of setValue method:</p>
  
  <p><code>public void setValue(String value) {
      this.value = value;
  }</code></p></li>
  <li><p>Click the red error mark to auto-create a private field (called "value in this case");</p></li>
  </ol>
  
  <p>So at this point, I would like Eclipse to auto-create the getter method, without having to do it using the <em>source -> generate getters and setters</em> menu.</p>
  
  <p>I saw this question: <a href="https://stackoverflow.com/questions/3822687/how-do-you-force-eclipse-to-prompt-you-to-create-a-getter-and-setter-when-it-doe">How do you force Eclipse to prompt you to create a getter and setter when it doesn't do it automatically</a> which seems to imply that Eclipse does this, but I couldn't find where to configure that.</p>
  
  <p>Is there some way to configure Eclipse to automatically add setter/getters when adding new private variable?  </p>
  
  <p><strong>UPDATE</strong>: 
  To clarify further, I'm looking for something like I saw in the <a href="http://www.springsource.org/spring-roo#documentation" rel="nofollow noreferrer">Spring Roo</a> documentation. If you take a look at the "How It Works" section, it describes how the framework automatically adds additional methods to your class, whenever you add a private variable. (My preference is not to run another process like that, however, and also not to get all the cruft that it seems to add).  I was hoping Eclipse had something similar.</p>