Example usage for org.jfree.date SerialDate SERIAL_LOWER_BOUND

List of usage examples for org.jfree.date SerialDate SERIAL_LOWER_BOUND

Introduction

In this page you can find the example usage for org.jfree.date SerialDate SERIAL_LOWER_BOUND.

Prototype

int SERIAL_LOWER_BOUND

To view the source code for org.jfree.date SerialDate SERIAL_LOWER_BOUND.

Click Source Link

Document

The serial number for 1 January 1900.

Usage

From source file:org.jfree.data.time.Day.java

/**
 * Returns the day preceding this one./*from   w  w  w  .  j  a va2  s.c  o  m*/
 *
 * @return The day preceding this one.
 */
@Override
public RegularTimePeriod previous() {
    Day result;
    int serial = this.serialDate.toSerial();
    if (serial > SerialDate.SERIAL_LOWER_BOUND) {
        SerialDate yesterday = SerialDate.createInstance(serial - 1);
        return new Day(yesterday);
    } else {
        result = null;
    }
    return result;
}