OpenQuizz
Une application de gestion des contenus pédagogiques
BaseTimeBuilder Class Reference
Inheritance diagram for BaseTimeBuilder:
Collaboration diagram for BaseTimeBuilder:

Public Member Functions

def build_date (cls, YYYY=None, MM=None, DD=None, Www=None, D=None, DDD=None)
 
def build_time (cls, hh=None, mm=None, ss=None, tz=None)
 
def build_datetime (cls, date, time)
 
def build_duration (cls, PnY=None, PnM=None, PnW=None, PnD=None, TnH=None, TnM=None, TnS=None)
 
def build_interval (cls, start=None, end=None, duration=None)
 
def build_repeating_interval (cls, R=None, Rnn=None, interval=None)
 
def build_timezone (cls, negative=None, Z=None, hh=None, mm=None, name="")
 
def range_check_date (cls, YYYY=None, MM=None, DD=None, Www=None, D=None, DDD=None, rangedict=None)
 
def range_check_time (cls, hh=None, mm=None, ss=None, tz=None, rangedict=None)
 
def range_check_duration (cls, PnY=None, PnM=None, PnW=None, PnD=None, TnH=None, TnM=None, TnS=None, rangedict=None)
 
def range_check_repeating_interval (cls, R=None, Rnn=None, interval=None, rangedict=None)
 
def range_check_timezone (cls, negative=None, Z=None, hh=None, mm=None, name="", rangedict=None)
 

Static Public Attributes

 DATE_YYYY_LIMIT
 
 DATE_MM_LIMIT
 
 DATE_DD_LIMIT
 
 DATE_WWW_LIMIT
 
 DATE_D_LIMIT
 
 DATE_DDD_LIMIT
 
 TIME_HH_LIMIT
 
 TIME_MM_LIMIT
 
 TIME_SS_LIMIT
 
 TZ_HH_LIMIT
 
 TZ_MM_LIMIT
 
 DURATION_PNY_LIMIT
 
 DURATION_PNM_LIMIT
 
 DURATION_PNW_LIMIT
 
 DURATION_PND_LIMIT
 
 DURATION_TNH_LIMIT
 
 DURATION_TNM_LIMIT
 
 DURATION_TNS_LIMIT
 
 INTERVAL_RNN_LIMIT
 
dictionary DATE_RANGE_DICT
 
dictionary TIME_RANGE_DICT = {"hh": TIME_HH_LIMIT, "mm": TIME_MM_LIMIT, "ss": TIME_SS_LIMIT}
 
dictionary DURATION_RANGE_DICT
 
dictionary REPEATING_INTERVAL_RANGE_DICT = {"Rnn": INTERVAL_RNN_LIMIT}
 
dictionary TIMEZONE_RANGE_DICT = {"hh": TZ_HH_LIMIT, "mm": TZ_MM_LIMIT}
 
bool LEAP_SECONDS_SUPPORTED = False
 

Member Function Documentation

◆ build_date()

def build_date (   cls,
  YYYY = None,
  MM = None,
  DD = None,
  Www = None,
  D = None,
  DDD = None 
)

Reimplemented in TupleBuilder, and PythonTimeBuilder.

◆ build_datetime()

def build_datetime (   cls,
  date,
  time 
)

Reimplemented in TupleBuilder, and PythonTimeBuilder.

◆ build_duration()

def build_duration (   cls,
  PnY = None,
  PnM = None,
  PnW = None,
  PnD = None,
  TnH = None,
  TnM = None,
  TnS = None 
)

Reimplemented in TupleBuilder, and PythonTimeBuilder.

◆ build_interval()

def build_interval (   cls,
  start = None,
  end = None,
  duration = None 
)

Reimplemented in TupleBuilder, and PythonTimeBuilder.

◆ build_repeating_interval()

def build_repeating_interval (   cls,
  R = None,
  Rnn = None,
  interval = None 
)

Reimplemented in TupleBuilder, and PythonTimeBuilder.

◆ build_time()

def build_time (   cls,
  hh = None,
  mm = None,
  ss = None,
  tz = None 
)

Reimplemented in TupleBuilder, and PythonTimeBuilder.

◆ build_timezone()

def build_timezone (   cls,
  negative = None,
  Z = None,
  hh = None,
  mm = None,
  name = "" 
)

Reimplemented in TupleBuilder, and PythonTimeBuilder.

◆ range_check_date()

def range_check_date (   cls,
  YYYY = None,
  MM = None,
  DD = None,
  Www = None,
  D = None,
  DDD = None,
  rangedict = None 
)

◆ range_check_duration()

def range_check_duration (   cls,
  PnY = None,
  PnM = None,
  PnW = None,
  PnD = None,
  TnH = None,
  TnM = None,
  TnS = None,
  rangedict = None 
)

Reimplemented in PythonTimeBuilder.

◆ range_check_repeating_interval()

def range_check_repeating_interval (   cls,
  R = None,
  Rnn = None,
  interval = None,
  rangedict = None 
)

◆ range_check_time()

def range_check_time (   cls,
  hh = None,
  mm = None,
  ss = None,
  tz = None,
  rangedict = None 
)

◆ range_check_timezone()

def range_check_timezone (   cls,
  negative = None,
  Z = None,
  hh = None,
  mm = None,
  name = "",
  rangedict = None 
)

Field Documentation

◆ DATE_D_LIMIT

DATE_D_LIMIT
static
Initial value:
"Invalid weekday string.",
1,
7,
DayOutOfBoundsError,
"Weekday number must be between 1..7.",
range_check,
)

◆ DATE_DD_LIMIT

DATE_DD_LIMIT
static
Initial value:
"Invalid day string.",
1,
31,
DayOutOfBoundsError,
"Day must be between 1..31.",
range_check,
)

◆ DATE_DDD_LIMIT

DATE_DDD_LIMIT
static
Initial value:
"Invalid ordinal day string.",
1,
366,
DayOutOfBoundsError,
"Ordinal day must be between 1..366.",
range_check,
)

◆ DATE_MM_LIMIT

DATE_MM_LIMIT
static
Initial value:
"Invalid month string.",
1,
12,
MonthOutOfBoundsError,
"Month must be between 1..12.",
range_check,
)

◆ DATE_RANGE_DICT

dictionary DATE_RANGE_DICT
static
Initial value:
= {
"YYYY": DATE_YYYY_LIMIT,
"MM": DATE_MM_LIMIT,
"DD": DATE_DD_LIMIT,
"Www": DATE_WWW_LIMIT,
"D": DATE_D_LIMIT,
"DDD": DATE_DDD_LIMIT,
}

◆ DATE_WWW_LIMIT

DATE_WWW_LIMIT
static
Initial value:
"Invalid week string.",
1,
53,
WeekOutOfBoundsError,
"Week number must be between 1..53.",
range_check,
)

◆ DATE_YYYY_LIMIT

DATE_YYYY_LIMIT
static
Initial value:
"Invalid year string.",
0000,
9999,
YearOutOfBoundsError,
"Year must be between 1..9999.",
range_check,
)

◆ DURATION_PND_LIMIT

DURATION_PND_LIMIT
static
Initial value:
"Invalid day duration string.",
0,
None,
ISOFormatError,
"Duration days component must be positive.",
range_check,
)

◆ DURATION_PNM_LIMIT

DURATION_PNM_LIMIT
static
Initial value:
"Invalid month duration string.",
0,
None,
ISOFormatError,
"Duration months component must be positive.",
range_check,
)

◆ DURATION_PNW_LIMIT

DURATION_PNW_LIMIT
static
Initial value:
"Invalid week duration string.",
0,
None,
ISOFormatError,
"Duration weeks component must be positive.",
range_check,
)

◆ DURATION_PNY_LIMIT

DURATION_PNY_LIMIT
static
Initial value:
"Invalid year duration string.",
0,
None,
ISOFormatError,
"Duration years component must be positive.",
range_check,
)

◆ DURATION_RANGE_DICT

dictionary DURATION_RANGE_DICT
static
Initial value:
= {
"PnY": DURATION_PNY_LIMIT,
"PnM": DURATION_PNM_LIMIT,
"PnW": DURATION_PNW_LIMIT,
"PnD": DURATION_PND_LIMIT,
"TnH": DURATION_TNH_LIMIT,
"TnM": DURATION_TNM_LIMIT,
"TnS": DURATION_TNS_LIMIT,
}

◆ DURATION_TNH_LIMIT

DURATION_TNH_LIMIT
static
Initial value:
"Invalid hour duration string.",
0,
None,
ISOFormatError,
"Duration hours component must be positive.",
range_check,
)

◆ DURATION_TNM_LIMIT

DURATION_TNM_LIMIT
static
Initial value:
"Invalid minute duration string.",
0,
None,
ISOFormatError,
"Duration minutes component must be positive.",
range_check,
)

◆ DURATION_TNS_LIMIT

DURATION_TNS_LIMIT
static
Initial value:
"Invalid second duration string.",
0,
None,
ISOFormatError,
"Duration seconds component must be positive.",
range_check,
)

◆ INTERVAL_RNN_LIMIT

INTERVAL_RNN_LIMIT
static
Initial value:
"Invalid duration repetition string.",
0,
None,
ISOFormatError,
"Duration repetition count must be positive.",
range_check,
)

◆ LEAP_SECONDS_SUPPORTED

bool LEAP_SECONDS_SUPPORTED = False
static

◆ REPEATING_INTERVAL_RANGE_DICT

dictionary REPEATING_INTERVAL_RANGE_DICT = {"Rnn": INTERVAL_RNN_LIMIT}
static

◆ TIME_HH_LIMIT

TIME_HH_LIMIT
static
Initial value:
"Invalid hour string.",
0,
24,
HoursOutOfBoundsError,
"Hour must be between 0..24 with " "24 representing midnight.",
range_check,
)

◆ TIME_MM_LIMIT

TIME_MM_LIMIT
static
Initial value:
"Invalid minute string.",
0,
59,
MinutesOutOfBoundsError,
"Minute must be between 0..59.",
range_check,
)

◆ TIME_RANGE_DICT

dictionary TIME_RANGE_DICT = {"hh": TIME_HH_LIMIT, "mm": TIME_MM_LIMIT, "ss": TIME_SS_LIMIT}
static

◆ TIME_SS_LIMIT

TIME_SS_LIMIT
static
Initial value:
"Invalid second string.",
0,
60,
SecondsOutOfBoundsError,
"Second must be between 0..60 with " "60 representing a leap second.",
range_check,
)

◆ TIMEZONE_RANGE_DICT

dictionary TIMEZONE_RANGE_DICT = {"hh": TZ_HH_LIMIT, "mm": TZ_MM_LIMIT}
static

◆ TZ_HH_LIMIT

TZ_HH_LIMIT
static
Initial value:
"Invalid timezone hour string.",
0,
23,
HoursOutOfBoundsError,
"Hour must be between 0..23.",
range_check,
)

◆ TZ_MM_LIMIT

TZ_MM_LIMIT
static
Initial value:
"Invalid timezone minute string.",
0,
59,
MinutesOutOfBoundsError,
"Minute must be between 0..59.",
range_check,
)

The documentation for this class was generated from the following file:
aniso8601.builders.Limit
Limit
Definition: __init__.py:35