Instead of putting quotes literally into regualar expressions ("\\-"), I like it more to use Pattern.quote("-"), because that way one doesn't have to reverse engineer this with every reading.