/** * Returns the given {@code timeValue} if it is not {@code null}, if {@code null} then returns * {@link #NEG_ONE_SECONDS}. * * @param timeValue may be {@code null} * @return {@code timeValue} or {@link #NEG_ONE_SECONDS} */ public static TimeValue defaultsToNegativeOneMillisecond(final TimeValue timeValue) { return defaultsTo(timeValue, NEG_ONE_MILLISECONDS); }
/** * Returns the given {@code timeValue} if it is not {@code null}, if {@code null} then returns * {@link #NEG_ONE_SECONDS}. * * @param timeValue may be {@code null} * @return {@code timeValue} or {@link #NEG_ONE_SECONDS} */ public static TimeValue defaultsToNegativeOneSecond(final TimeValue timeValue) { return defaultsTo(timeValue, NEG_ONE_SECONDS); }
/** * Returns the given {@code timeValue} if it is not {@code null}, if {@code null} then returns * {@link #NEG_ONE_SECONDS}. * * @param timeValue may be {@code null} * @return {@code timeValue} or {@link #NEG_ONE_SECONDS} */ public static TimeValue defaultsToNegativeOneMillisecond(final TimeValue timeValue) { return defaultsTo(timeValue, NEG_ONE_MILLISECONDS); }
/** * Returns the given {@code timeValue} if it is not {@code null}, if {@code null} then returns * {@link #ZERO_MILLISECONDS}. * * @param timeValue may be {@code null} * @return {@code timeValue} or {@link #ZERO_MILLISECONDS} */ public static TimeValue defaultsToZeroMillis(final TimeValue timeValue) { return defaultsTo(timeValue, ZERO_MILLISECONDS); }
/** * Returns the given {@code timeValue} if it is not {@code null}, if {@code null} then returns * {@link #ZERO_MILLISECONDS}. * * @param timeValue may be {@code null} * @return {@code timeValue} or {@link #ZERO_MILLISECONDS} */ public static TimeValue defaultsToZeroMillis(final TimeValue timeValue) { return defaultsTo(timeValue, ZERO_MILLISECONDS); }
/** * Returns the given {@code timeValue} if it is not {@code null}, if {@code null} then returns * {@link #NEG_ONE_SECONDS}. * * @param timeValue may be {@code null} * @return {@code timeValue} or {@link #NEG_ONE_SECONDS} */ public static TimeValue defaultsToNegativeOneSecond(final TimeValue timeValue) { return defaultsTo(timeValue, NEG_ONE_SECONDS); }