Commit Graph

3402 Commits

Author SHA1 Message Date
Sebastian Bazley 89c6497228 StringBuffer => StringBuilder where being used as a local-only buffer
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1391112 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 17:21:12 +00:00
Sebastian Bazley 3ab8e13026 Javadoc
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1391095 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 16:46:50 +00:00
Sebastian Bazley acb89828f1 Javadoc typos
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1391048 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 15:02:09 +00:00
Sebastian Bazley a0148b0e20 Explicit boxing
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1391027 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 14:20:10 +00:00
Sebastian Bazley f9837a0728 Suppress boxing warnings for assertEquals()
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1391025 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 14:18:55 +00:00
Sebastian Bazley cc730589cd Document some @SuppressWarning annotations
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1391003 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 13:34:33 +00:00
Sebastian Bazley 76833dc4a4 Explicit boxing
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390993 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 13:16:30 +00:00
Sebastian Bazley f068cb71b5 Tab police
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390989 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 13:12:09 +00:00
Sebastian Bazley 0490f1c291 LANG-820 TypeUtils.normalizeUpperBounds broken?
Added test to show it works OK

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390984 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 13:01:57 +00:00
Sebastian Bazley 04babff379 LANG-818 FastDateFormat's "z" pattern does not respect timezone of Calendar instances passed to format()
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390980 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 12:56:19 +00:00
Sebastian Bazley cfab1e4fa1 LANG-815 DurationFormatUtils.formatPeriod() mis-calculation
Add test case to show there is no issue

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390971 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 12:46:42 +00:00
Sebastian Bazley 77eed078c8 LANG-777 jar contains velocity template of release notes
Merge releases notes into standard location

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390966 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 12:32:45 +00:00
Sebastian Bazley 586e0b1c8a Copy of Commons Parent version; generates same output
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390962 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 12:21:51 +00:00
Sebastian Bazley 6ecb0a30c3 LANG-830 FastDateParser could use \Q \E to quote regexes
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390954 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 11:50:52 +00:00
Sebastian Bazley e5ae84a6fc LANG-829 FastDateParser could use Calendar.getDisplayNames for all text fields
Remove unnecessary KeyValue instances

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390937 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 10:59:30 +00:00
Chas Honton 8c87749695 LANG-829: FastDateParser could use Calendar.getDisplayNames for all text fields
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390839 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 04:50:21 +00:00
Sebastian Bazley 9960dd4204 Add some more tests
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390816 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 03:04:49 +00:00
Sebastian Bazley 67914b1475 Add some more tests
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390815 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 02:46:55 +00:00
Sebastian Bazley 9dabaeeb96 Show where the parsing failed
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390814 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 02:33:01 +00:00
Sebastian Bazley f899c178b7 Don't save short eras if they are the same as the long eras
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390811 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 02:18:18 +00:00
Sebastian Bazley 65a6458eaa LANG-832 FastDateParser does not handle unterminated quotes correctly
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390795 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 00:55:31 +00:00
Sebastian Bazley ad72b9f2bf LANG-831 FastDateParser does not handle white-space properly
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390779 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 00:09:15 +00:00
Sebastian Bazley 192b1e1b6b Allow access to parsedPattern for test purposes
Make ParseException text similar to that thrown by SimpleDateFormat

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390778 13f79535-47bb-0310-9956-ffa450edef68
2012-09-27 00:02:58 +00:00
Sebastian Bazley c03f033c1c Trailing spaces
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390722 13f79535-47bb-0310-9956-ffa450edef68
2012-09-26 20:44:16 +00:00
Sebastian Bazley de3d06ff01 Package protection is sufficient here
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390656 13f79535-47bb-0310-9956-ffa450edef68
2012-09-26 18:43:40 +00:00
Sebastian Bazley e568101617 Wrong class name; make line stand out better
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390650 13f79535-47bb-0310-9956-ffa450edef68
2012-09-26 18:37:31 +00:00
Sebastian Bazley d7af943548 LANG-828 FastDateParser does not handle non-Gregorian calendars properly
Use Calendar#getDisplayNames() instead of DateFormatSymbols#getEras()

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390626 13f79535-47bb-0310-9956-ffa450edef68
2012-09-26 18:03:24 +00:00
Sebastian Bazley e582456625 LANG-828 FastDateParser does not handle non-Gregorian calendars properly
Fix bug in Java 7 (Locale.toString() format has changed)

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390189 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 22:12:14 +00:00
Sebastian Bazley 73ea9c43c6 Extract constant
Label output with test case name

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390172 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 21:46:34 +00:00
Sebastian Bazley eedd1169bf Label output with test case name
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390171 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 21:46:11 +00:00
Sebastian Bazley 3e47c0599e Remove unused field
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390158 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 21:31:41 +00:00
Sebastian Bazley 6ac6f2c870 Unused imports
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390157 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 21:30:27 +00:00
Sebastian Bazley 005f41f136 One reason why the ja_JP_JP and th_TH_* locales don't work
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1390143 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 21:11:34 +00:00
Sebastian Bazley 34beef1d08 LANG-828 FastDateParser does not handle non-Gregorian calendars properly
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1389976 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 16:32:20 +00:00
Sebastian Bazley 5ffcb8d35b getInstance() (Java 1.6) supports more locales
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1389939 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 15:41:57 +00:00
Sebastian Bazley 6d06d0a1c0 Fix testParses() so it works for non-GMT timezones: the format must include hours to allow for GMT-offsets
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1389869 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 14:07:47 +00:00
Sebastian Bazley f67add0e72 Grammar
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1389682 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 02:03:24 +00:00
Sebastian Bazley f621ea87cc Document why tests seem to fail
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1389681 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 02:02:21 +00:00
Sebastian Bazley 62d5c0eecb LANG-826 FastDateParser does not handle non-ASCII digits correctly
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1389673 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 01:07:01 +00:00
Sebastian Bazley bb8164bb2c Make immutable private variable final
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1389670 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 01:01:50 +00:00
Sebastian Bazley 0120e9264d More tests; era seems to cause issues, so check this separately
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1389667 13f79535-47bb-0310-9956-ffa450edef68
2012-09-25 00:51:11 +00:00
Sebastian Bazley 246ecda5e2 Split test into 4 so each failure can be detected
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1389484 13f79535-47bb-0310-9956-ffa450edef68
2012-09-24 17:01:47 +00:00
Sebastian Bazley a81da42d90 LANG-799 - DateUtils#parseDate uses default locale; add Locale support
Remove inappropriate test - we don't use localized formats

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1389172 13f79535-47bb-0310-9956-ffa450edef68
2012-09-24 00:11:23 +00:00
Gary D. Gregory 01ee7028e6 [LANG-825] Create StrBuilder APIs similar to String.format(String, Object...)
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1389042 13f79535-47bb-0310-9956-ffa450edef68
2012-09-23 13:01:27 +00:00
Sebastian Bazley 72b9613ddb LANG-799 - DateUtils#parseDate uses default locale; add Locale support
Show current default locale

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1388824 13f79535-47bb-0310-9956-ffa450edef68
2012-09-22 16:07:55 +00:00
Sebastian Bazley 12a0e3bdde LANG-799 - DateUtils#parseDate uses default locale; add Locale support
Parse German date with English Locale, specifying German Locale override

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1388821 13f79535-47bb-0310-9956-ffa450edef68
2012-09-22 15:36:31 +00:00
Sebastian Bazley 79c627478f LANG-799 - DateUtils#parseDate uses default locale; add Locale support
Remove unnecessary test

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1388818 13f79535-47bb-0310-9956-ffa450edef68
2012-09-22 15:27:40 +00:00
Sebastian Bazley ebdef1b957 LANG-799 - DateUtils#parseDate uses default locale; add Locale support
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1388806 13f79535-47bb-0310-9956-ffa450edef68
2012-09-22 13:22:30 +00:00
Sebastian Bazley b219a449bb LANG-799 Add tests to show ParseException when default Locale is wrong
Add Strictly tests for valid strings

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1388793 13f79535-47bb-0310-9956-ffa450edef68
2012-09-22 12:41:16 +00:00
Sebastian Bazley 37fd0adafb LANG-799 Add tests to show ParseException when default Locale is wrong
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1388787 13f79535-47bb-0310-9956-ffa450edef68
2012-09-22 12:33:25 +00:00