title: Best Practices -- Constructors and Setters
body: <p>I have an IDE which I can use to automatically create constructors and setters for instance variables, but I was wondering if the way that it creates them is possibly not best practice. Here is what it does:</p>
  
  <pre><code>private String partNum;
  private String partDesc;
  private int quant;
  private double price;
  
  public Invoice( String partNum, String partDesc, int quant, double price )
  {
      this.partNum = partNum;
      this.partDesc = partDesc;
      this.quant = quant;
      this.price = price;
  }
  </code></pre>
  
  <p>It's the 'this.name' thing that I'm worried about, as well as the constructor labeling the parameters the same names as the variables it's constructing. The setter also does the same thing -- uses a parameter name that's the same as the name of the variable it's setting, and uses this.name.</p>
  
  <p>So, is there anything wrong with this?</p>