Just a suggestion, would these usage be more intuiative to the user (using full regular expression pattern for matches)?
Use URL query parameter:
<root>file:///opt/lib?file-re-pattern=.*jar</root>
Or extend root element with attribute:
<root file-re-pattern=".*jar">file:///opt/lib</root>
The 2nd one would require a change to the api, since root is currently directly mapped to String,
and would have to be changed to some custom attribute handling class.
I'll use the 1st approach. Perhaps some other (shorter) key word suggestion?
* root-re-pattern perhaps?