JDK-7151414 : (cal) Support calendar type identification
  • Type: Enhancement
  • Component: core-libs
  • Sub-Component: java.util:i18n
  • Affected Version: 7
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2012-03-06
  • Updated: 2017-05-17
  • Resolved: 2012-09-05
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 8
8 b55Fixed
Related Reports
Relates :  
Relates :  
Description
Thai Buddhist calendar and Japanese imperial calendar systems were added in 1.4 and 1.6, respectively. However, there's no public way to identify those non-Gregorian calendars. You need to rely on a Locale with which a Calendar object has been created. There should be a method to get calendar system identification.

Unicode LDML (Locale Data Markup Language) defines identifiers for calendar types. Java SE should use the same identifiers.

http://unicode.org/reports/tr35/

Comments
Run the new test developed for JEP 127 with latest JPRT build and JDK8 b62.
29-10-2012

SUGGESTED FIX http://hg.openjdk.java.net/jdk8/tl/jdk/rev/131a683a2ce0
21-08-2012

EVALUATION getCalendarType() should be aded to Calendar. The identifiers to be supported are: gregory - Gregorian/Julian hybrid buddhist - Thai Buddhist japanese - Japanese imperial
06-03-2012