|
/ modules / paradigms / Adaptor_TemporalIsContainedInRewriter.py
SYNOPSIS
Adaptor_TemporalIsContainedInRewriter (paradigm,
minDate=101, maxDate=99991231)
paradigm
The underlying temporal paradigm.
minDate
The earliest supported date, expressed as an integer in
the encoding YYYYMMDD. The default value of 101
corresponds to 0000-01-01, i.e., to January 1, 0000.
Notice that leading zeros have been stripped off to
suppress Python's octal interpretation!
maxDate
The latest supported date, expressed as an integer in
the encoding YYYYMMDD. The default value of 99991231
corresponds to December 31, 9999.
DESCRIPTION
Adds support for the "is-contained-in" operator to a temporal
paradigm (the "underlying" paradigm) that doesn't otherwise
support it.
Several of the temporal paradigms, such as Temporal_BeginEnd and
Temporal_SingleDate, do not support the "is-contained-in"
operator if the table cardinality is "0+" or "1+". This
paradigm adds support by rewriting a temporal constraint
C("is-contained-in", begin, end)
as three constraints,
C("is-contained-in", begin, end) AND NOT
(C("overlaps", minDate, begin-1) OR
C("overlaps", end+1, maxDate))
The underlying paradigm is then used to individually translate
the three new constraints.
Exceptions thrown:
begin date precedes earliest supported date
end date follows latest supported date
AUTHOR
Greg Janee
gjanee@alexandria.ucsb.edu
HISTORY
$Log: Adaptor_TemporalIsContainedInRewriter.py,v $
Revision 1.2 2003/12/15 23:54:18 peter
Mondified source code documentation so that it formats properly when
creating HTML documents with happydoc.
Revision 1.1 2003/12/08 23:32:56 valentin
update to oct2003
Revision 1.1 2003/10/23 21:20:53 gjanee
Initial revision
|
Functions
|
|
|
|
_increment
|
_increment ( date )
|
|
|
_decrement
|
_decrement ( date )
|
|
|