umalquracalendar

Get Month Name of java.time.chrono.HijrahDate instance

眉间皱痕 提交于 2020-01-11 05:33:10
问题 HijrahDate hd=HijrahChronology.INSTANCE.date(LocalDate.of(2014,11, 25)); If we have HijrahDate Instance , it is expected to have a method in UmalquraCalendar API that shows the name of month : i inspect properties of this instance using groovy API : ['era':AH, 'class':class java.time.chrono.HijrahDate, 'prolepticMonth':17233, 'eraValue':1, 'dayOfWeek':2, 'leapYear':false, 'chronology':Hijrah-umalqura, 'dayOfYear':32] However we don't find the month name which must be one of the following list

Get Month Name of java.time.chrono.HijrahDate instance

巧了我就是萌 提交于 2019-12-01 06:33:13
HijrahDate hd=HijrahChronology.INSTANCE.date(LocalDate.of(2014,11, 25)); If we have HijrahDate Instance , it is expected to have a method in UmalquraCalendar API that shows the name of month : i inspect properties of this instance using groovy API : ['era':AH, 'class':class java.time.chrono.HijrahDate, 'prolepticMonth':17233, 'eraValue':1, 'dayOfWeek':2, 'leapYear':false, 'chronology':Hijrah-umalqura, 'dayOfYear':32] However we don't find the month name which must be one of the following list items : Muḥarram (محرم meaning "forbidden"), so called because battle was forbidden (haram) during

Convert between calendars

蹲街弑〆低调 提交于 2019-11-30 12:37:01
How to convert between calendars? Here is what I have: UmAlQuraCalendar hijri = new UmAlQuraCalendar(); GregorianCalendar cal = new GregorianCalendar(); DateTime hijriDate = new DateTime(1434, 11, 23, hijri); DateTime gregorianDate = ...; // I need a gregorianDate that corresponds to the hijriDate . It seems that the Date saved in DateTime is always in the current calendar. So if the current calendar is Gregorian hijriDate is already in Gregorian. var hijriDate = new DateTime(1434, 11, 23, hijri); //Console writeline will show 2013-09-29 00:00:00 If your current calendar is UmAlQuraCalendar

Convert between calendars

时光总嘲笑我的痴心妄想 提交于 2019-11-29 17:51:57
问题 How to convert between calendars? Here is what I have: UmAlQuraCalendar hijri = new UmAlQuraCalendar(); GregorianCalendar cal = new GregorianCalendar(); DateTime hijriDate = new DateTime(1434, 11, 23, hijri); DateTime gregorianDate = ...; // I need a gregorianDate that corresponds to the hijriDate . 回答1: It seems that the Date saved in DateTime is always in the current calendar. So if the current calendar is Gregorian hijriDate is already in Gregorian. var hijriDate = new DateTime(1434, 11,