The datetime this event first started, or None if it never did.
503709
def _getMyFirstDatetimeFrom(self):
        
        myStartDt = getAwareDatetime(self.repeat.dtstart, None,
                                     self.tz, dt.time.min)
        return self.__after(myStartDt, excludeCancellations=False)
462747
private void selectDefaultDate() {
        Calendar today = Calendar.getInstance();
        int hour = -1, minute = -1;

        // get the next possible selection
        Calendar date = getNextItemDate(today);
        // if it is the today item, we need to take a look the time
        if(date != null && DateSpinner.compareCalendarDates(date, today) == 0) {
            // same as getNextTimeDate for TimeSpinner
            final int last = timeSpinner.getLastItemPosition();
            final int searchHour = today.get(Calendar.HOUR_OF_DAY),
                    searchMinute = today.get(Calendar.MINUTE);
            for (int i=0; i<=last; i++) {
                final TimeItem time = ((TimeItem) timeSpinner.getItemAtPosition(i));
                if(time.getHour() > searchHour || (time.getHour() == searchHour && time.getMinute() >= searchMinute)) {
                    hour = time.getHour();
                    minute = time.getMinute();
                    break;
                }
            }

            // it may be too late in the evening to select the today item
            // or if FLAG_HIDE_TIME has been set, set it to tomorrow morning:
            if((hour == -1 && minute == -1) || shouldHideTime) {
                Calendar tomorrow = (Calendar) today.clone();
                tomorrow.add(Calendar.DAY_OF_YEAR, 1);
                date = getNextItemDate(tomorrow); // if this returns null it'll be set to today below
            }
        }
        if(date == null) {
            // it seems this spinner only contains past items, use the last one
            date = ((DateItem) dateSpinner.getItemAtPosition(dateSpinner.getLastItemPosition())).getDate();
        }

        if(hour == -1 && minute == -1) {
            // the date is not today, just select the earliest possible time
            final TimeItem time = ((TimeItem) timeSpinner.getItemAtPosition(0));
            hour = time.getHour();
            minute = time.getMinute();
        }

        // finally, select what we found
        date.set(Calendar.HOUR_OF_DAY, hour);
        date.set(Calendar.MINUTE, minute);
        setSelectedDate(date);
    }
455699
private void checkDates() {
		DateTime created = this.dateCreated;
		DateTime published = this.datePublished;
		DateTime modified = this.dateModified;
		DateTime reviewed = this.dateReviewed;
		if(
			created != null
			&& published != null
			&& published.compareTo(created) < 0
		) throw new IllegalArgumentException("published may not be before created");
		if(
			created != null
			&& modified != null
			&& modified.compareTo(created) < 0
		) throw new IllegalArgumentException("modified may not be before created");
		if(
			created != null
			&& reviewed != null
			&& reviewed.compareTo(created) < 0
		) throw new IllegalArgumentException("reviewed may not be before created");
	}
186066
def date(self) -> Optional[DateHeader]:
        """"""
        try:
            return cast(DateHeader, self[b'date'][0])
        except (KeyError, IndexError):
            return None
357675
public LocalDateTime getStartDateTime() {
        if (startDateTime == null) {
            startDateTime = LocalDateTime.of(getStartDate(), getStartTime());
        }

        return startDateTime;
    }
1187491
public function isWithinOneDay()
	{
		$started = (is_null($this->started)) ? new \DateTime('now') : $this->started;
		$stopped = (is_null($this->stopped)) ? new \DateTime('now') : $this->stopped;

		return ($started->format('Y-m-d') === $stopped->format('Y-m-d'));
	}
1276410
def is_open(self, when=None):
        
        if when is None:
            when = datetime.now()

        return self._val[0] <= when and when <= self._val[1]
452214
def check(self):
    

    if self.value is None:
      return False
    return (time.clock() - self.start) >= self.value
708690
def daterange_start(value):
    ''''''
    if not value:
        return None
    elif isinstance(value, datetime):
        return value.date()
    elif isinstance(value, date):
        return value

    result = parse_dt(value).date()
    dashes = value.count('-')

    if dashes >= 2:
        return result
    elif dashes == 1:
        # Year/Month only
        return result.replace(day=1)
    else:
        # Year only
        return result.replace(day=1, month=1)
992666
def getDayStart(self, dateTime):
        '''  '''
        return ensure_localtime(dateTime).replace(hour=0,minute=0,second=0,microsecond=0)
657176
def start(self):
        
        if self._timer.isActive():
            return

        self._starttime = datetime.datetime.now()
        self._timer.start()
785248
public function isDue(DateTime $date = null)
    {
        // The execution time is being defaulted if not defined
        if (! $this->executionTime) {
            $this->at('* * * * *');
        }

        $date = $date !== null ? $date : $this->creationTime;

        if ($this->executionYear && $this->executionYear !== $date->format('Y')) {
            return false;
        }

        return $this->executionTime->isDue($date);
    }
56022
private boolean startUpdate(UpdateRackHeartbeat updateRack,
                              UpdatePodSystem updatePod)
  {
    long now = CurrentTime.currentTime();
    
    if (_lastHubTime + getTimeout() < now) {
    }
    else if (_lastRackCrc != updateRack.getCrc()) {
    }
    else if (updatePod != null && _lastPodCrc != updatePod.getCrc()) {
    }
    else {
      return false;
    }
    
    _lastHubTime = now;
    _lastRackCrc = updateRack.getCrc();
    
    if (updatePod != null) {
      _lastPodCrc = updatePod.getCrc();
    }
    
    return true;
  }
1330360
public synchronized Date setStartDate(Date time)
    {
        m_cachedInfo.setStartDate(time);
        int iThisIndex = m_model.indexOf(this);
        if (iThisIndex != -1)
            m_model.fireTableRowsUpdated(iThisIndex, iThisIndex);
        this.changeRemoteDate(null, null, this, time, null);
        return this.getStartDate();
    }
190414
def time_afterwards_preceding(
            self, when: datetime.datetime) -> Optional[datetime.timedelta]:
        
        if self.is_empty():
            return None
        end_time = self.end_datetime()
        if when <= end_time:
            return datetime.timedelta()
        else:
            return when - end_time
182007
public boolean isStartedBy(T element) {
    if (element == null) { return false; }
    return comparator.compare(element, min) == 0;
  }
1179788
def _occursOn(self, myDate):
        
        # TODO analyse which is faster (rrule or db) and test that first
        if myDate not in self.repeat:
            return False
        if CancellationPage.events.child_of(self)                            \
                           .filter(except_date=myDate).exists():
            return False
        return True