Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(2)  |  Call(1)  |  Derive(0)  |  Import(1)

        is_time = lambda obj: isinstance(obj, time)
        


src/x/o/xoutil-1.5.4/xoutil/json.py   xoutil(Download)
    def default(self, o):
        from decimal import Decimal as _Decimal
        from xoutil.types import is_iterable
        from xoutil.datetime import (is_datetime as _is_datetime,
                                     new_datetime as _new_datetime,
            d = __new_date(o)
            return d.strftime(self.DATE_FORMAT)
        elif _is_time(o):
            return o.strftime(self.TIME_FORMAT)
        elif isinstance(o, _Decimal):