Gets the weekdays.

@return DayOfWeek[]
778133
public static function weekdays() : array
    {
        $days     = self::getAll();
        $weekDays = [];

        foreach ($days as $key => $day) {
            if ($day->isWeekDay()) {
                $weekDays[] = $day;
            }
        }

        return $weekDays;
    }
749696
public function weeks($startDay = 'Monday')
    {
        if (!isset($this->weeks[$startDay])) {
            $this->weeks[$startDay] = array();
            $keepWeeking = true;
            $weekPoint = clone $this->firstDay();

            while ($keepWeeking) {
                $candidateWeek = new Week($weekPoint, $startDay);
                if ($candidateWeek->weekStart() <= $this->lastDay()) {
                    $candidateWeek->setContainingMonth($this);
                    $this->weeks[$startDay][] = $candidateWeek;
                    $weekPoint->modify('+1 week');
                } else {
                    $keepWeeking = false;
                }
            }
        }
        return $this->weeks[$startDay];
    }
573594
def weekly(date=datetime.date.today()):
    
    return date - datetime.timedelta(days=date.weekday())
442604
public static function getCurrentDayOfWeekName()
    {
        $now = new DateTime();

        $year = $now->format('Y');
        $month = $now->format('m');
        $day = $now->format('d');

        return self::getDayOfWeekName($year, $month, $day);
    }
786937
def weekday(cls, year, month, day):
        """"""
        return NepDate.from_bs_date(year, month, day).weekday()
286770
protected function calculateDays($numberOfDays)
    {
        $endDate = Carbon::today();
        $startDate = Carbon::today()->subDays($numberOfDays);

        return [$startDate, $endDate];
    }
385098
public Date[] getDates()
   {
      int frequency = NumberHelper.getInt(m_frequency);
      if (frequency < 1)
      {
         frequency = 1;
      }

      Calendar calendar = DateHelper.popCalendar(m_startDate);
      List<Date> dates = new ArrayList<Date>();

      switch (m_recurrenceType)
      {
         case DAILY:
         {
            getDailyDates(calendar, frequency, dates);
            break;
         }

         case WEEKLY:
         {
            getWeeklyDates(calendar, frequency, dates);
            break;
         }

         case MONTHLY:
         {
            getMonthlyDates(calendar, frequency, dates);
            break;
         }

         case YEARLY:
         {
            getYearlyDates(calendar, dates);
            break;
         }
      }

      DateHelper.pushCalendar(calendar);
      
      return dates.toArray(new Date[dates.size()]);
   }
1358039
public function toArray()
    {
        $start    = $this->intervalStart;
        $end      = $this->intervalEnd;
        $period   = new \DatePeriod($start, new \DateInterval('P1D'), $end);
        $days     = array();

        foreach ($period as $current_day) {
            $days[] = $current_day;
        }

        $days[]  = $end;

        return $days;
    }
289102
public static function weekRange()
    {
        $timestamp = time();
        return [
            strtotime(date('Y-m-d', strtotime("+0 week Monday", $timestamp))),
            strtotime(date('Y-m-d', strtotime("+0 week Sunday", $timestamp))) + 24 * 3600 - 1
        ];
    }
796622
public static function getPeriodToFrequency()
    {
        return array(
            Schedule::PERIOD_NEVER => Piwik::translate('General_Never'),
            Schedule::PERIOD_DAY   => Piwik::translate('General_Daily'),
            Schedule::PERIOD_WEEK  => Piwik::translate('General_Weekly'),
            Schedule::PERIOD_MONTH => Piwik::translate('General_Monthly'),
        );
    }
1329027
public static function getWeekDays()
    {
        static $weekdays = null;
        if ($weekdays == null) {
            $weekdays   = array();
            for ($i = 0; $i < 7; $i++) {
                $weekdays[$i] = strftime('%A', mktime(0, 0, 0, 1, $i, 2001));
            }
        }
        return $weekdays;
    }
286778
def get_all_days():
    
    weekly = get_weekly()
    daily = get_daily()

    return [w * (d / 100.0) for w in weekly for d in daily]
673797
public Weekday getDayOfWeek() {

        long utcDays = CALSYS.transform(this);
        return Weekday.valueOf(MathUtils.floorModulo(utcDays + 5, 7) + 1);

    }
767528
protected function buildWeekDays()
	{
		foreach( $this->days as $day )
			$days[]	= UI_HTML_Tag::create( "div", $day, array( 'class' => "weekday" ) );
		$days	= implode( "", $days );
		$code	= UI_HTML_Tag::create( "div", $days, array( 'class' => "weekdays" ) );
		return $code;
	}
279980
public function get_columns() {

		// Lowercase day, for column key
		$day = strtolower( date( 'l', $this->day_start ) );

		// Return Week & Day
		return array(
			'hour' => sprintf( esc_html__( 'Wk. %s', 'wp-event-calendar' ), date_i18n( 'W', $this->today ) ),
			$day   => date_i18n( 'l, F j, Y', $this->day_start ),
		);
	}
1127726
public Day getDayOfWeek()
   {
      Day result = null;
      if (!m_days.isEmpty())
      {
         result = m_days.iterator().next();
      }
      return result;
   }
1080743
public function getDays() {
    $query = \Drupal::entityQuery('day');
    $query->condition('league', $this->id());
    $query->sort('id', 'ASC');
    $ids = $query->execute();

    return Day::loadMultiple($ids);
  }