Example usage for org.jfree.data.time Month next

List of usage examples for org.jfree.data.time Month next

Introduction

In this page you can find the example usage for org.jfree.data.time Month next.

Prototype

@Override
public RegularTimePeriod next() 

Source Link

Document

Returns the month following this one.

Usage

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

/**
 * Some checks for the testNext() method.
 *///from  ww  w  . j  a  v a2  s.c  o m
@Test
public void testNext() {
    Month m = new Month(12, 2000);
    m = (Month) m.next();
    assertEquals(new Year(2001), m.getYear());
    assertEquals(1, m.getMonth());
    m = new Month(12, 9999);
    assertNull(m.next());
}

From source file:org.jfree.data.time.junit.MonthTest.java

/**
 * Some checks for the testNext() method.
 *///w w w .j a  v  a2 s .  c  o  m
public void testNext() {
    Month m = new Month(12, 2000);
    m = (Month) m.next();
    assertEquals(new Year(2001), m.getYear());
    assertEquals(1, m.getMonth());
    m = new Month(12, 9999);
    assertNull(m.next());
}