Date

class orion_notebook.date.OrionDate(input_date: Union[datetime.date, datetime.datetime, str])

Bases: object

Class to wrap a date and normalize it around the lib

date()datetime.date

Returns a date object from the normalized input

Returns

A date object from the normalized input

Return type

date

dateYYYYmmdd()str

Returns a date in format ‘YYYYmmdd’ from the normalized input

Returns

Date formatted to string with the format ‘YYYYmmdd’

Return type

str

dateYYYYmmddHHMMSS()str

Returns a date with time in format ‘YYYYmmddHHMMSS’ from the normalized input

Returns

Date with time formatted to string with the format ‘YYYYmmddHHMMSS’

Return type

str

dateYYYYmmddHHMMSSmmmuuu()str

Returns a date with time in format ‘YYYYmmddHHMMSSmmmuuu’ from the normalized input

Returns

Date with time formatted to string with the format ‘YYYYmmddHHMMSSmmmuuu’

Return type

str

datetime()

Returns a datetime object from the normalized input

Returns

A datetime object from the normalized input

Return type

datetime

isoformat()

Returns a date,time string which contains the following information: Date, Time UTC offset to corresponding time zone as specified in the standard ISO 8601.

timestamp()

Returns a number representing the seconds since epoc from the normalized input

Returns

A number representing the POSIX timestamp from the normalized input

Return type

integer

timestamp_ms()

Returns a number representing the milliseconds since epoc from the normalized input

Returns

A number representing the POSIX timestamp from the normalized input

Return type

integer

value: datetime.datetime