title: Java: Extend SimpleDateFormat with new pattern letters
body: <p>Java's <a href="http://docs.oracle.com/javase/1.4.2/docs/api/java/text/SimpleDateFormat.html" rel="nofollow">SimpleDateFormat</a> is used to format a Date object to a string. The formatter supports various <em>pattern letters</em>, which denote textual representation of a Date field. For example, <code>yy</code> is two-letter year, <code>yyyy</code> is four-letter year, and <code>E</code> is day of week.</p>
  
  <p>For example, A <code>SimpleDateFormat</code> initialized with <code>yyyy.MM.dd G 'at' HH:mm:ss z</code> will format a date to something like <code>2001.07.04 AD at 12:08:56 PDT</code>.</p>
  
  <p>I would like to add some pattern letters to SimpleDateFormat. For example, want <code>C</code> to denote Hebrew weekday (<code>יום ראשון</code>, <code>יום שני</code>, ...).</p>
  
  <p>What's the right way to extend SimpleDateFormat with these new pattern letters? The only online example I could find <a href="http://home-1.worldonline.nl/~bmc88/java/sbook/035.html" rel="nofollow">seems somewhat complicated</a>. I can live with formatting only, without parsing.</p>