/// <summary>
/// A protected method checking calendar year and the era number.
/// </summary>
/// <param name="year">An integer representing the calendar year.
/// </param>
/// <param name="era">The era number as reference.</param>
/// <exception name="T:System.ArgumentException">
/// The exception is thrown if the era is not supported by the class.
/// </exception>
/// <exception cref="T:System.ArgumentOutOfRangeException">
/// The exception is thrown if the calendar year is outside of
/// the supported range.
/// </exception>
internal int M_CheckYEG(int year, ref int era)
{
M_CheckEra(ref era);
return(M_EraHandler.GregorianYear(year, era));
}