NumberFormat is currently a bit leniant. It will parse '123xx' but not 'xx123'. Folks using JFormattedTextField that want number parsing use NumberFormat. It's not expected that either string would be valid, instead both should throw an exception. Obviously we can't change this now, so perhaps we could add an option to turn on strict parsing.
Use a ParsePosition to get the index after parsing. If ParsePostion.getIndex() != string.length(), then parse() didn't consume the entire string.
Developers can easily write code which checks if the given text includes an unexpected character before/after digits using ParsePosition and ParseException.
I have no plan to add a method for the strict mode.
*** (#1 of 1): [ UNSAVED ] ###@###.###