title: JavaParser: How to add new language elements
body: <p>I want to create a Java transpiler that will read nearly-Java code (call it JavaHash) and emit "pure" Java code on the other end. In particular, I want to add a new token that is the hashtag "#" in front of a hashmap member so that I might access it similar to a JavaScript hash object:</p>
  
  <pre><code>Map&lt;String, String&gt; foo = new HashMap&lt;String, String&gt;();
  ...
  foo.put("name", "Roger");
  ...
  String name = #foo.name;
  </code></pre>
  
  <p>I can't get the JavaParser to do anything but throw an error on the "#" hashtag.</p>
  
  <p>Are there ways to catch tokens before they are parsed?</p>