Beispiel #1
0
def date(interp, date_format, timestamp=int(pytime.time())):

    timelib_timezone = interp.get_default_timezone("date").timelib_timezone
    timelib_time = timelib.timelib_time_from_timestamp(timestamp,
                                                       timelib_timezone)

    return interp.space.wrap(timelib.date_format(date_format, timelib_time))
Beispiel #2
0
def gmdate(space, date_format, timestamp=int(pytime.time())):

    timelib_timezone = timelib.timelib_timezone('GMT')
    timelib_time = timelib.timelib_time_from_timestamp(timestamp,
                                                       timelib_timezone)

    return space.wrap(timelib.date_format(date_format, timelib_time))
Beispiel #3
0
def format(space, this, str_time):
    return space.wrap(timelib.date_format(str_time, this.timelib_time))
Beispiel #4
0
def _get_date(interp, this):
    return interp.space.wrap(
        timelib.date_format('Y-m-d H:i:s', this.timelib_time))
Beispiel #5
0
def format(space, this, str_time):
    return space.wrap(timelib.date_format(str_time, this.timelib_time))
Beispiel #6
0
def _get_date(interp, this):
    return interp.space.wrap(timelib.date_format("Y-m-d H:i:s", this.timelib_time))
Beispiel #7
0
def date_format(space, date, str_time):
    return space.wrap(timelib.date_format(str_time, date.timelib_time))
Beispiel #8
0
def date_format(space, date, str_time):
    return space.wrap(timelib.date_format(str_time, date.timelib_time))
Beispiel #9
0
def date(interp, date_format, timestamp=int(pytime.time())):

    timelib_timezone = interp.get_default_timezone("date").timelib_timezone
    timelib_time = timelib.timelib_time_from_timestamp(timestamp, timelib_timezone)

    return interp.space.wrap(timelib.date_format(date_format, timelib_time))
Beispiel #10
0
def gmdate(space, date_format, timestamp=int(pytime.time())):

    timelib_timezone = timelib.timelib_timezone('GMT')
    timelib_time = timelib.timelib_time_from_timestamp(timestamp, timelib_timezone)

    return space.wrap(timelib.date_format(date_format, timelib_time))