title: How to avoid multiple if statements where result is add to list
body: <p>I would like to ask you for an idea. I have class, where I have a lot of if statements, lets say it looks like that:</p>
  <pre><code>List&lt;String&gt; errors = new ArrayList&lt;&gt;();
  boolean errorCodition1 = SuperUtils.calculateIfObjectIsCorrect(this); // rest of them same
  
  if(errorCondition1){
      errors.add(errorsMessage.getSuperError());
  }
  
  if(errorCondition2){
      errors.add(errorsMessage.getMinorError());
  }
  
  if(errorCondition3){
      errors.add(errorsMessage.getAlmostCriticalError());
  }
  
  if(errorCondition4){
      errors.add(errorsMessage.getOverNineThousendError());
  }
  
  displayErrors(errors);
  </code></pre>
  <p>Maybe this code does not look super terrible, but lets assume that we will need to add more conditions. How would you avoid it?</p>
  <p>This code is called always when class is initialize, so lets say for example in constructor.</p>