Java Code Examples for org.joda.time.LocalDate.plusYears()

The following are Jave code examples for showing how to use plusYears() of the org.joda.time.LocalDate class. You can vote up the examples you like. Your votes will be used in our system to get more good examples.
Example 1
Project: moneytracking   File:   Source Code and License Vote up 6 votes
private Date createPlannedDate(String type, Date d) {
    LocalDate lo = LocalDate.fromDateFields(d);
    switch (type) {
        case "Daily":
            lo = lo.plusDays(1);
        case "Weekly":
            lo = lo.plusWeeks(1);
        case "Monthly":
            lo = lo.plusMonths(1);
        case "Yearly":
            lo = lo.plusYears(1);
    return lo.toDate();