TermCode — A perl module used to provide codes for the current term in various formats


There are several different ways to refer to a given term. This module contains several constants which are used to differentiate the various ways to refer to a term.

Indicates the number of seconds since the epoch as of the first second of the first month of term in local time.
Indicates the format used for MFCF classlist files.
Indicates the format used by the Registrar's office, for example in the schedule of classes.
Indicates a commonly-used short readable form, with a letter for the term within the year followed by a 2-digit year.
Indicates a commonly-used long readable form, with the term within the year, followed by a space, followed by a 4-digit year.

There are two functions available in the module to retrieve particular term codes.

get_termcode(month, year, format)
Given a numeric month (0-11) and a fully-specified year as would be returned by the localtime function, returns the code for the term in that month. The format used is determined by the final argument, which must be one of the constants listed above.
Works similar to get_termcode, but uses the current month and year automatically.
Topic revision: r1 - 2016-01-11 - YiLee
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback