Easy way to convert regex to a java compatible regex?
<p>hi all I have a regex defined in python/ruby/php that is like this</p>

<pre><code>"(forumdisplay.php\?.*page=%CURRENTPAGE%)"
</code></pre>

<p>when I do it for java, I have to double escape that question mark to //?</p>

<p>like so:</p>

<pre><code>"(forumdisplay.php\\?.*page=%CURRENTPAGE%)";
</code></pre>

<p>is there a function I can use to do that automatically? or would I need to change all my regexes over to work with the java regex engine?</p>

<p>thanks</p>
