Fix issue 2286: class properties would allow empty class names.
This change modifies the class property definition implementation so that it now prevents empty class names.
| | |
| | | |
| | | // Regular expression for validating class names. |
| | | private static final String CLASS_RE = |
| | | "^([A-Za-z]+[A-Za-z0-9_]*)*(\\.[A-Za-z]+[A-Za-z0-9_]*)" |
| | | + "*([\\$][A-Za-z0-9_]+)*$"; |
| | | "^([A-Za-z][A-Za-z0-9_]*\\.)*[A-Za-z][A-Za-z0-9_]*(\\$[A-Za-z0-9_]+)*$"; |
| | | |
| | | // Flag indicating whether class property values should be |
| | | // validated. |
| | |
| | | public Object[][] createBuilderAddInstanceOfData2() { |
| | | return new Object[][]{ |
| | | { "1" }, |
| | | { "" }, |
| | | { " " }, |
| | | { " " }, |
| | | { "abc." }, |
| | | { "abc.123" }, |
| | | { "abc.123$" }, |