title: Modify and return passed parameter
body: <p>I have code that has method like that modify and return the passed object parameter.</p>
  
  <p>It strongly looks to me like a bad code smell.</p>
  
  <pre><code>public class Creator {
    public MyClass create(MyClass param) {
  
      SomeClass attr1 = createAttr1();
      SomeClass attr2 = createAttr2();
      //... more creation
  
      param.setAttr1(attr1);
      param.setAttr2(attr2);
      //... set other created attributes.
  
      return param;
    }
  }
  
  
  public class MyApp {
    public static void main(String[] args) {
      Creator creatorProcesss = new Creator();
      MyClass myClass = new MyClass();
      myClass = creatorProcesss.create(myClass);
    }
  }
  </code></pre>
  
  <p>Is there a proper way to refactor it ?</p>