(self)
return datetime(y, m, d, h, mn, s, ms)
Returns a ``datetime`` version of this object with all unspecified
        (None) attributes replaced by their lowest values.

        This method raises an error if the ``adatetime`` object has no year.

        >>> adt = adatetime(year=2009, month=5)
        >>> adt.floor()
        datetime.datetime(2009, 5, 1, 0, 0, 0, 0)
Returns a ``datetime`` version of this object with all unspecified
        (None) attributes replaced by their lowest values.
Returns a datetime version of this object with all unspecified ( None ) attributes replaced by their lowest values .
def floor(self):
        """Returns a ``datetime`` version of this object with all unspecified
        (None) attributes replaced by their lowest values.

        This method raises an error if the ``adatetime`` object has no year.

        >>> adt = adatetime(year=2009, month=5)
        >>> adt.floor()
        datetime.datetime(2009, 5, 1, 0, 0, 0, 0)
        """

        y, m, d, h, mn, s, ms = (self.year, self.month, self.day, self.hour,
                                 self.minute, self.second, self.microsecond)

        if y is None:
            raise ValueError("Date has no year")

        if m is None:
            m = 1
        if d is None:
            d = 1
        if h is None:
            h = 0
        if mn is None:
            mn = 0
        if s is None:
            s = 0
        if ms is None:
            ms = 0
        return datetime(y, m, d, h, mn, s, ms)
def floor ( self ) : y , m , d , h , mn , s , ms = ( self . year , self . month , self . day , self . hour , self . minute , self . second , self . microsecond ) if y is None : raise ValueError ( "Date has no year" ) if m is None : m = 1 if d is None : d = 1 if h is None : h = 0 if mn is None : mn = 0 if s is None : s = 0 if ms is None : ms = 0 return datetime ( y , m , d , h , mn , s , ms )