Re: Possible bug in Calendar
- From: Harold Yarmouth <hyarmouth991476@xxxxxxxxxxx>
- Date: Tue, 04 Nov 2008 04:52:15 -0500
Joshua Cranmer wrote:
Harold Yarmouth wrote:Joshua Cranmer wrote:Nice to know that you're so culturally sensitive in ignoring
"Cultural sensitivity" is neither here nor there. "Cultural sensitivity" is not a major concern of programming language or API design. It may be a concern of application user-interface design, but that's a whole different kettle of fish.
I was referring to "cultural sensitivity" to be polite in suggesting "You have an arrogant Anglo-Amerocentric viewpoint."
You should not suggest an insulting lie about me at all. In future, don't.
There are countries who use non-Gregorian calendars for civil purposes, by requiring that the API dictate everything in Gregorian, you've essentially said "screw you" to said countries.
Bull. I only suggested that the CORE part of the API do everything with one standard time representation. There can be a translation class used to interface to the user using whatever means of measuring and naming times that they prefer, of course, but the core should be something simple and world-standard, like a Gregorian calendar or seconds since the epoch or whatever.
Someone else posted a link to a JSR that details how to do this right, or at least better.
Which means using the plain-Jane Gregorian calendar under the hood in Date and other business objects related to dates, with DateFormat or other similar classes providing translations into locale-specific representations.
When viewed pedantically, the typical fiscal calendar is not even the same as the civil Gregorian calendar in place in most countries: March 1, 2009 is in the same fiscal year as November 2, 2008.
The last time I checked, fiscal calendars vary from organization to organization. There users have to supply their own code to translate from a standard time format into their local fiscal calendar.
So if I'm doing calculations on a fiscal calendar, it should tell
me that the two are in the same year, right?
Yes, though the core Date class won't do so.
If Calendar's sole purpose was this sort of translation there wouldn't be a problem. But Calendar is also the "DateBuilder" because Date has no non-deprecated methods or constructors to directly build a standard date using standard units, say from one encoded in such units in a file or a network packet.
Note that time is near-impossible to determine good APIs for since the human concept of time is not even consistent, let alone the technical muck designed to make it saner for human use.
See that JSR.
.
- References:
- Re: Possible bug in Calendar
- From: Harold Yarmouth
- Re: Possible bug in Calendar
- From: Joshua Cranmer
- Re: Possible bug in Calendar
- Prev by Date: Re: Possible bug in Calendar
- Next by Date: Re: Store the speech content
- Previous by thread: Re: Possible bug in Calendar
- Next by thread: Re: Possible bug in Calendar
- Index(es):
Relevant Pages
|