<commit_before><?php
/**
 * This file is part of stubbles.
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 *
 * @package  stubbles\date
 */
namespace stubbles\date\span;
/**
 * Allows iteration over months of a datespan.
 *
 * @since  5.2.0
 */
class Months implements \Iterator
{
    /**
     * start date of the iteration
     *
     * @type  int
     */
    private $year;
    /**
     * start date of the span
     *
     * @type  \stubbles\date\span\Month
     */
    private $currentMonth;

    /**
     * constructor
     *
     * @param  \stubbles\date\span\Year  $year
     */
    public function __construct(Year $year)
    {
        $this->year         = $year->asInt();
        $this->currentMonth = new Month($this->year, 1);
    }

    /**
     * returns current day within iteration
     *
     * @return  \stubbles\date\span\Day
     */
    public function current()
    {
        return $this->currentMonth;
    }

    /**
     * returns key for current day, which is it's string representation
     *
     * @return  string
     */
    public function key()
    {
        return $this->currentMonth->asString();
    }

    /**
     * advances iteration to next day
     */
    public function next()
    {
        $this->currentMonth = $this->currentMonth->next();
    }

    /**
     * returns iteration back to first day of datespan
     */
    public function rewind()
    {<commit_msg>fix doc comment<commit_after><?php
/**
 * This file is part of stubbles.
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 *
 * @package  stubbles\date
 */
namespace stubbles\date\span;
/**
 * Allows iteration over months of a datespan.
 *
 * @since  5.2.0
 */
class Months implements \Iterator
{
    /**
     * start date of the iteration
     *
     * @type  int
     */
    private $year;
    /**
     * start date of the span
     *
     * @type  \stubbles\date\span\Month
     */
    private $currentMonth;

    /**
     * constructor
     *
     * @param  \stubbles\date\span\Year  $year
     */
    public function __construct(Year $year)
    {
        $this->year         = $year->asInt();
        $this->currentMonth = new Month($this->year, 1);
    }

    /**
     * returns current day within iteration
     *
     * @return  \stubbles\date\span\Month
     */
    public function current()
    {
        return $this->currentMonth;
    }

    /**
     * returns key for current day, which is it's string representation
     *
     * @return  string
     */
    public function key()
    {
        return $this->currentMonth->asString();
    }

    /**
     * advances iteration to next day
     */
    public function next()
    {
        $this->currentMonth = $this->currentMonth->next();
    }

    /**
     * returns iteration back to first day of datespan
     */
    public function rewind()
    {
{'fraction_non_alphanumeric': 0.11997319034852547, 'fraction_numerical': 0.002680965147453083, 'mean_word_length': 1.8952473326867119, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 23, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3075250', 'n_tokens_mistral': 883, 'n_tokens_neox': 878, 'n_words': 252}