code: public String getFormatedDate()
      {
          if(date == null){return "";}
          
          StringBuilder sb = new StringBuilder();
          GregorianCalendar g = new GregorianCalendar();
          g.setTime(date);
          sb.append(String.valueOf(g.get(GregorianCalendar.YEAR))).append("-");
          sb.append(twoDigitFormat(g.get(GregorianCalendar.MONTH) + 1)).append("-");
          sb.append(twoDigitFormat(g.get(GregorianCalendar.DAY_OF_MONTH)));
          
          return sb.toString();
      }
docs: <p>getFormatedDate.</p>
  
  @return a {@link java.lang.String} object.