src/pylib/Lib/datetime_impl/timedelta_impl/meth

Source   Edit  

Types

FI = float | I_in_FI
float or int64 Source   Edit  

Procs

func `$`(self: timedelta): string {....raises: [], tags: [], forbids: [].}

for timedelta.__str__

[D day[s], ][H]H:MM:SS[.UUUUUU], where D is negative for negative t.

Source   Edit  
func `%`(self, t: timedelta): timedelta {....raises: [], tags: [], forbids: [].}
Source   Edit  
func `*`(f: float; self: timedelta): timedelta {....raises: [], tags: [],
    forbids: [].}
Source   Edit  
func `*`(i: int64; self: timedelta): timedelta {....raises: [], tags: [],
    forbids: [].}
Source   Edit  
func `*`(self: timedelta; f: float): timedelta {....raises: [], tags: [],
    forbids: [].}
Source   Edit  
func `*`(self: timedelta; i: int64): timedelta {....raises: [], tags: [],
    forbids: [].}
Source   Edit  
func `+`(a, b: timedelta): timedelta {....raises: [], tags: [], forbids: [].}
Source   Edit  
func `+`(self: timedelta): timedelta {....raises: [], tags: [], forbids: [].}
Source   Edit  
func `+=`(mself; t: timedelta) {....raises: [], tags: [], forbids: [].}
Source   Edit  
func `-`(a, b: timedelta): timedelta {....raises: [], tags: [], forbids: [].}
Source   Edit  
func `-`(self: timedelta): timedelta {....raises: [], tags: [], forbids: [].}
Source   Edit  
func `-=`(mself; t: timedelta) {....raises: [], tags: [], forbids: [].}
Source   Edit  
func `/`(self: timedelta; i: int | float): timedelta
Source   Edit  
func `/`(self: timedelta; t: timedelta): float {....raises: [], tags: [],
    forbids: [].}
Source   Edit  
func `//`(self: timedelta; i: int): timedelta {....raises: [], tags: [],
    forbids: [].}
Source   Edit  
func `//`(self: timedelta; t: timedelta): int {....raises: [], tags: [],
    forbids: [].}
Source   Edit  
func abs(self: timedelta): timedelta {....raises: [], tags: [], forbids: [].}
Source   Edit  
func divmod(t1, t2: timedelta): (int64, timedelta) {....raises: [], tags: [],
    forbids: [].}
Source   Edit  
func max(_: _`gensym1694498900:type): timedelta
Source   Edit  
func min(_: _`gensym1694498896:type): timedelta
Source   Edit  
func repr(self: timedelta): string {....raises: [], tags: [], forbids: [].}
Source   Edit  
func resolution(_: _`gensym1694498904:type): timedelta
Source   Edit  
func timedelta(days: FI = 0; seconds: FI = 0; microseconds: FI = 0;
               milliseconds: FI = 0; minutes: FI = 0; hours: FI = 0;
               weeks: FI = 0): timedelta
Source   Edit  
func timedelta(days: int64; seconds = 0'i64; microseconds = 0'i64;
               milliseconds = 0'i64; minutes = 0'i64; hours = 0'i64;
               weeks = 0'i64): timedelta {....raises: [], tags: [], forbids: [].}

timedelta with int-only arguments

See timedelta that accepts mixin float and int as arguments

Hint: if setting default value for days(a.k.a. days=0), timedelta() will fail to be compiled due to ambiguous call
Source   Edit  
func total_seconds(self: timedelta): float {....raises: [], tags: [], forbids: [].}
timedelta.total_seconds() Source   Edit