Gregorian Calendar URI Space

This version:
http://placetime.com/2003/05/interval-gregorian-20030519
Latest version:
http://placetime.com/interval/gregorian/
Previous version:
http://placetime.com/2003/05/interval-gregorian-20030512
Author:
Ian Davis

Abstract

This is a specification of a URI space representing intervals in time according to the Gregorian calendar. An interval consists of an instant which indicates the start of the interval plus a duration.

Status

This URI space is EXPERIMENTAL and may be subject to change in the future. Please do not rely on the existence of any URIs in this space for production works.

Contents

The Gregorian celandar

The Gregorian calendar was devised under the direction of Pope Gregory XIII in order to correct inaccuracies that had crept into the existing Julian reckoning. It was adopted by various countries over a period of 400 years (see Dates of the Gregorian Reform).

The calendar is based on a 365-day year divided into twelve months of lengths 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30 and 31 days.

If a year is divisible by 4 and not by 100 or if it is divisble by 400 it is denoted a leap year and an extra day is added to the second month.

From time to time, a leap second may be added or subtracted to keep the calendar in step with astronomical time.

URI syntax

URIs in this space take the general form:

http://placetime.com/interval/gregorian/INSTANT/DURATION

The INSTANT part consists of a date and time specification of the following form: yyyy-mm-ddThh:nn:ssTZ

Where:

yyyy
Four digits (0,1,2,3,4,5,6,7,8,9) representing the year (0001 to 9999).
mm
Two digits representing the month of the year. (01 to 12)
dd
Two digits representing the day of the month. (01 to 28, 29, 30 or 31 depending on the month).
hh
Two digits representing the hour of the day. (01 to 23)
nn
Two digits representing the minute of the hour. (01 to 59)
ss
Two digits representing the second of the minute. (01 to 59, 60 or 61 depending on leap seconds)
T
Literal text separating the date and time portions of the URI
TZ
A string that represents the timezone. This may be a literal 'Z' which denotes UTC time, or an offset in the form shh:nn where:
s
Either the character '+' which denotes a positive offset from UTC or '-' which denotes a negative offset
hh
Two digits representing the number of hours in the offset. (01 to 12)
nn
Two digits representing the number of minutes in the offset. (01 to 59)

The DURATION part consists of a duration specification of the following form: PyYmMdDThHnMsS

Where:

P
Literal text indicating the start of the duration.
y
One or more digits (0,1,2,3,4,5,6,7,8,9) representing the number of years in the interval
m
One or more digits representing the number of months in the interval
d
One or more digits representing the number of days in the interval
h
One or more digits representing the number of hours in the interval
n
One or more digits representing the number of minutes in the interval
s
One or more digits representing the number of seconds in the interval
Y
Literal text delimiting the number of years.
M
Literal text delimiting the number of months.
D
Literal text delimiting the number of days.
T
Literal text separating the date and time portions of the duration.
H
Literal text delimiting the number of hours.
M
Literal text delimiting the number of minutes.
S
Literal text delimiting the number of seconds.

Components of the duration that have a value of zero MAY be omitted.

If no time components are specified in the duration then the T delimiter MUST be omitted.

Decimal values for duration components MUST NOT be used.

Negative values for duration components MUST NOT be used.

Note that there is currently no way to represent the same interval in different time-zones using this URI space. All times are specified in Coordinated Universal Time (UTC). Addition of time-zone information is under consideration.

Intervals that extend past 9999-12-31T23:59:59 cannot be represented in this URI space.

Retrievability

All URIs in this space are retrievable via the HTTP protocol.

Content negotiation using the HTTP Accept: header is performed to determine the appropriate representation format.

Currently HTML and RDF representations are provided. These can be addressed individually by appending .html or .rdf to the URL used to retrieve the representation. For example an HTML representation of the URI

http://placetime.com/interval/gregorian/1970-06-15T19:31:00Z/P1Y

may be obtained by issuing an HTTP GET on the following URL:

http://placetime.com/interval/gregorian/1970-06-15T19:31:00Z/P1Y.html

and the corresponding RDF representation using this URL:

http://placetime.com/interval/gregorian/1970-06-15T19:31:00Z/P1Y.rdf

Representations

The RDF representation of URIs in this space utilise the DAML-Time ontology. The URIs are instances of the DAML-Time Interval class.

Examples

http://placetime.com/interval/gregorian/1970-06-15T19:31:00Z/P1D
A time-interval of one day, beginning on 15 June 1970 at 31 minutes past 19 hours UTC.
http://placetime.com/interval/gregorian/1985-04-12T23:20:50Z/P1Y2M15DT12H30M0S
A time-interval of one year, two months, 15 days, 12 hours and 30 minutes, beginning on 12 April 1985 at 20 minutes and 50 seconds past 23 hours UTC. This is exactly equivilent to: http://placetime.com/interval/gregorian/1985-04-12T23:20:50Z/P1Y2M15DT12H30M
http://placetime.com/interval/gregorian/1969-07-16T09:32:00-04:00/PT195H18M35S
A time-interval of one hundred and ninety five hours, eighteen minutes and thirty five seconds beginning at thirty two minutes past nine o'clock in the morning, four hours behind UTC, on the sixteenth day of the month of July in year nineteen hundred and sixty nine of the Gregorian calendar.