Code example for TimeZone

Methods: clone

0
    public static void setDefaultTimeZone(final TimeZone timeZone) {
        if (timeZone == null) {
            // -- reset timezone to the default 
            _timezone = TimeZone.getDefault();
        } else { 
            _timezone = (TimeZone) timeZone.clone();
        } 
    } // -- setDefaultTimeZone 
 
    /** 
     * Sets a flag indicating whether or not Milliseconds should be suppressed 
     * upon formatting a dateTime as a String. 
     * 
     * @param suppressMillis a boolean when true indicates that millis should be 
     *        suppressed during conversion of a dateTime to a String 
     */ 
    public static void setSuppressMillis(final boolean suppressMillis) {
        _suppressMillis = suppressMillis;
    } // -- setAlwaysUseUTCTime