NAME
Ucam::Term - return information about the start and end dates of terms (and a few related events) at the University of Cambridge, UK.
SYNOPSIS
use Ucam::Term;
my $term = Ucam::Term->new('m',2010);
print $term->name, " term ", $term->year, " starts ";
print $term->dates->start, "\n";
my $term = Ucam::Term->new('e',2015);
print "General Admission ", $term->year, " starts ";
print $term->general_admission->start, "\n";
DESCRIPTION
The academic year at the University of Cambridge, UK, is divided into three Terms - Michaelmas (autumn), Lent (spring) and Easter (summer). The half-way point of each term is called the Division of Term. Three quarters of each Term is designated Full Term, during which lectures are given and when undergraduate students are normally required to be in residence. Near the end of the Easter Term there are three or four days of General Admission, during which degrees are conferred on those who have just successfully completed courses, followed by the Long Vacation period of residence during which some additional courses of instruction are given.
The dates of some of these events and periods are fixed, but others depend on dates that appear in the University's published 'Ordnances' (see "SEE ALSO" below for references) which are updated from time to time. This version of the module contains data covering the period from the Michaelmas Term 2007 to the Easter Term 2030.
This module returns DateTime or DateTime::Span objects corresponding to these events and periods. Note that the DateTime::Span objects run from 00:00 (inclusive) on the day the period starts to 00:00 (exclusive) on the day after the period ends (see DateTime::Span->end_is_open). This means that union/intersection/complement/intersects/contains operations will all work correctly, but that it is normally necessary to subtract one day from the end date of the span in order to find the date of the last day of the period.
METHODS
Ucam::Term->new()
Create a new Ucam::Term object
my $term = Ucam::Term->new('michaelmas',2010);
Requires two arguments: term and year. Term can be 'm', 'mich', 'michaelmas', 'l', 'lent', 'e', 'easter' in any mixture of case. Year should be the full 4-digit year number. Croaks if given an unrecognised term. Otherwise returns a new Ucam::Term object.
Ucam::Term->available_years()
List years with useful information
my @years = Ucam::Term->available_years
Returns a sorted list of years for which at least some term date information is available. Some years returned will not have dates for all terms available (typically the first year will have only Michaelemas defined, the last only Lent and Easter). Convenient for iterating over all information available.
$term->name()
Extract term name
my $name = $term->name
Return the full, human-readable name of the term represented by the object ('Michaelmas', 'Lent', or 'Easter')
$term->year()
Extract term year
my $year = $term->year
Return the year of the term represented by the object.
$term->dates()
Return the term start/end dates for the object
my $span = $term->dates
Return a DateTime::Span representing the corresponding term. This runs from 00:00 on the first day of term (inclusive) to 00:00 on the day after term ends (exclusive). Returns undef unless the module has data for this term (even though this is really only needed for Easter terms)
$term->fullterm_dates()
Return the full term start/end dates for the object
my $span = $term->fullterm_dates
Return a DateTime::Span representing the corresponding full term. This runs from 00:00 on the first day of full term (inclusive) to 00:00 on the day after full term ends (exclusive). Returns undef unless the module has data for this term.
$term->division()
Returns the date of the division of term
$division = $term->division
Returns a DateTime object representing 00:00 on the day corresponding to the division of term.
$term->general_admission()
Return the start/end dates for General Admission based on the table that appears in Ordinances, Chapter II, Section 10 'Dates of Term and Full Term' (see general_admission_alg() for what should be the same data derived from the algorythm in Ordinances, Chapter II, Section 12 'Admission to Degrees')
my $span = $term->general_admission
Return a DateTime::Span representing the period of General Admission following an Easter term. The span runs from 00:00 on the first day of General Admission (inclusive) to 00:00 on the day after the final day (exclusive). Returns undef unless the module has data for this term. Croaks if called on an object that doesn't represent an Easter term.
$term->general_admission_alg()
Return the start/end dates for General Admission based on the algorythm that appears in Ordinances, Chapter II, Section 12 'Admission to Degrees' (see general_admission() for what should be the same data derived from the algorythm in Ordinances, Chapter II, Section 10 'Dates of Trem and Full Term' )
my $span = $term->general_admission_alg
Return a DateTime::Span representing the period of General Admission following an Easter term. The span runs from 00:00 on the first day of General Admission (inclusive) to 00:00 on the day after the final day (exclusive). Returns undef unless the module has data for this term. Croaks if called on an object that doesn't represent an Easter term.
$term->long_vac()
Return the start/end dates for the 'Long Vacation period of residence'
my $span = $term->long_vac
Return a DateTime::Span representing the period of the 'Long Vacation period of residence' that follows an Easter term. The span runs from 00:00 on the first day (inclusive) to 00:00 on the day after the final day (exclusive). Returns undef unless the module has data for this term. Croaks if called on an object that doesn't represent an Easter term.
AUTHOR
Jon Warbrick, jw35@cam.ac.uk.
SEE ALSO
University of Cambridge Statutes and Ordnances, Chapter II ("Matriculation, Residence, Admission to Degrees") (http://www.admin.cam.ac.uk/univ/so/) contains most of the rules implemented by this module:
"Section 10: DATES OF TERM AND FULL TERM"
"1. The Michaelmas Term shall begin on 1 October and shall consist of eighty days, ending on 19 December. The Lent Term shall begin on 5 January and shall consist of eighty days, ending on 25 March or in any leap year on 24 March. The Easter Term shall begin on 10 April and shall consist of seventy days ending on 18 June, provided that in any year in which Full Easter Term begins on or after 22 April the Easter Term shall begin on 17 April and end on 25 June.
"2. Full Term shall consist of three-fourths of the whole term reckoned from the first day of Full Term as hereinafter determined.
"3. The dates on which Full Terms begin and end shall be as shown in the table appended to these regulations.
"...
"8. A course of instruction given during the Long Vacation shall not occupy more than four weeks. Except with the approval of the Council on the recommendation of the General Board, no such course given within the Precincts of the University shall begin earlier than the second Monday after General Admission or end later than the sixth Saturday after the Saturday of General Admission."
"Section 12: ADMISSION TO DEGREES"
[Prior to 2013]:
"13. In every year the Thursday, Friday, and Saturday after the third Sunday in June shall be days of General Admission to Degrees, save that, in accordance with Regulation 3 for Terms and Long Vacation, in any year in which Full Easter Term begins on or after 22 April the days of General Admission shall be the Thursday, Friday, and Saturday after the fourth Sunday in June. On each day of General Admission there shall be one or more Congregations for General Admission to Degrees at such hours as the Vice-Chancellor shall appoint."
[As ammended by Grace 1 of 13 February 2013 (http://www.admin.cam.ac.uk/reporter/2012-13/weekly/6297/section6.shtml) with effect from 1 October 2013]:
"13. Every year the Wednesday, Thursday, Friday, and Saturday after the third Sunday in June shall be days of General Admission to Degrees, save that, in accordance to Regulation 3 for Terms and Long Vacation, in any year in which Full Easter Term begins on or after 22 April the days of General Admission shall be the Wednesday, Thursday, Friday, and Saturday after the fourth Sunday in June. On each day of General Admission there shall be one or more Congregations for General Admission to Degrees at such hours as the Vice-Chancellor shall appoint."
[As ammended by Grace 2 of 5 February 2014 (http://www.admin.cam.ac.uk/reporter/2013-14/weekly/6336/section8.shtml)]
"14. Every year the Wednesday, Thursday, Friday, and Saturday in the week next but one following the last week of Full Easter Term shall be days of General Admission to Degrees."
[In practice, the dates of General Admission as given in the table in Section 10: 'Dates of Term and Full Term' appear to be cannonical - between 2010 and 2014 the dates in the table and the ordnance diagreed and it was the ordanance that was updated]
Division of Term is best described in http://www.cam.ac.uk/univ/termdates.html:
"Division of Term is half-way through Term (not Full Term). The dates are the same for every year except for Easter term: 9 November, 13 February, and 14 May or 21 May depending on whether Easter Term starts on 10 April or 17 April."
See also DateTime, DateTime::Span
COPYRIGHT and LICENSE
Copyright (c) 2010, 2013, 2017 University of Cambridge Information Services. This program is free software; you can distribute it and/or modify it under the same terms as Perl itself.
The full text of the license can be found in the LICENSE file included with this module.