title: Check that date is within a given range of date inclusive
body: <p><strong>This question is to compare dates inclusively in Java.</strong></p>
  
  <p>Is there a better way to check if a given date is within a range inclusively?</p>
  
  <pre><code>Date startDate, endDate, dateToCheck;
  
  if ( dateToCheck.equals(startDate) || 
       dateToCheck.equals(endDate) || 
      (dateToCheck.after(startDate) &amp;&amp; dateToCheck.before(endDate) ) 
  </code></pre>