Package Bio :: Package EUtils :: Module Datatypes :: Class DateRange
[show private | hide private]
[frames | no frames]

Class DateRange


Restrict a search to matches within a date range

Some examples:
    matches between 1995 and 2000 -- DateRange("1995", "1999/12/31")
    matches before 1990 -- DateRange(maxdate = "1990/01/01")
    matches in 2002 or later -- DateRange(mindate = "2002/01/01")
    matches in June or July of 2001 -- DateRange("2001/06", "2001/07")

Method Summary
  __init__(self, mindate, maxdate, datetype)
mindate = None, maxdate = None, datetype = None 'mindate' -- matches must be on or after this date 'maxdate' -- matches must be on or before this date 'datetype' -- the date field to use for the search (defaults to Entrez date, which is "edat") At least one of mindate or maxdate must be specified.
  get_query_params(self)
returns the fields to add to the EUtils query

Method Details

__init__(self, mindate=None, maxdate=None, datetype=None)
(Constructor)

mindate = None, maxdate = None, datetype = None

'mindate' -- matches must be on or after this date
'maxdate' -- matches must be on or before this date
'datetype' -- the date field to use for the search (defaults
     to Entrez date, which is "edat")

At least one of mindate or maxdate must be specified.
If mindate is omitted, all results on or before maxdate are returned.
If maxdate is omitted, all results on or after mindate are returned.

Dates must be formatted as 'YYYY/MM/DD', 'YYYY/MM', or 'YYYY'.

get_query_params(self)

returns the fields to add to the EUtils query

This is an internal implementation feature you can ignore.

Generated by Epydoc 2.1 on Mon Aug 27 16:13:10 2007 http://epydoc.sf.net