Logo Search packages:      
Sourcecode: icu version File versions  Download package

UBool IslamicCalendar::inDaylightTime ( UErrorCode status  )  const [protected, virtual]

(Overrides Calendar) Return true if the current date for this Calendar is in Daylight Savings Time. Recognizes DST_OFFSET, if it is set.

Parameters:
status Fill-in parameter which receives the status of this operation.
Returns:
True if the current date for this Calendar is in Daylight Savings Time, false, otherwise.

For internal use only.

Implements Calendar.

Definition at line 445 of file islamcal.cpp.

References FALSE, Calendar::getTimeZone(), Calendar::internalGet(), NULL, U_FAILURE, U_SUCCESS, and UCAL_DST_OFFSET.

{
    // copied from GregorianCalendar
    if (U_FAILURE(status) || (&(getTimeZone()) == NULL && !getTimeZone().useDaylightTime())) 
        return FALSE;

    // Force an update of the state of the Calendar.
    ((IslamicCalendar*)this)->complete(status); // cast away const

    return (UBool)(U_SUCCESS(status) ? (internalGet(UCAL_DST_OFFSET) != 0) : FALSE);
}


Generated by  Doxygen 1.6.0   Back to index