private YearQuarter with(int newYear, Quarter newQuarter) {
        if (year == newYear && quarter == newQuarter) {
            return this;
        }
        return new YearQuarter(newYear, newQuarter);
    }
private YearQuarter with ( int newYear , Quarter newQuarter ) { if ( year == newYear && quarter == newQuarter ) { return this ; } return new YearQuarter ( newYear , newQuarter ) ; }
Returns a copy of this year-quarter with the new year and quarter, checking
to see if a new object is in fact required.

@param newYear  the year to represent, validated from MIN_YEAR to MAX_YEAR
@param newQuarter  the quarter-of-year to represent, validated not null
@return the year-quarter, not null