<commit_before><?php

/*
 * This file is part of the TempoSimple project.
 *
 * (c) <NAME> <<EMAIL>>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace TempoSimple\Bundle\SpaghettiBundle\Factory;

use Symfony\Component\Console\Input\InputInterface;
use TempoSimple\Service\TimeTrackingBundle\Query\ActivityQuery;
use TempoSimple\Service\TimeTrackingBundle\Query\BillableQuery;
use TempoSimple\Service\TimeTrackingBundle\Query\DailyQuery;
use TempoSimple\Service\TimeTrackingBundle\Query\PunchQuery;

class ConsoleQueryFactory
{
    /**
     * @param InputInterface $input
     *
     * @return BillableQuery
     */
    public function makeActivity(InputInterface $input)
    {
        $month = $input->getOption('month');

        return new ActivityQuery($month);
    }

    /**
     * @param InputInterface $input
     *
     * @return BillableQuery
     */
    public function makeBillable(InputInterface $input)
    {
        $projectName = $input->getOption('project');
        $month = $input->getOption('month');

        return new BillableQuery($projectName, $month);
    }

    /**
     * @param InputInterface $input
     *
     * @return DailyQuery
     */
    public function makeDaily(InputInterface $input)
    {
        $day = $input->getOption('date');

        return new DailyQuery($day);
    }

    /**
     * @param InputInterface $input
     *
     * @return PunchQuery
     */
    public function makePunch(InputInterface $input)
    {
        $project = $input->getOption('project');
        $task = $input->getArgument('task');
        $date = $input->getOption('date');
        $startHour = $input->getOption('start-hour');
        $endHour = $input->getOption('end-hour');
        $description = $input->getOption('description');

        return new PunchQuery(
            $project,
            $task,
            $date,
            $startHour,
            $endHour,
            $description
        );
    }
}<commit_msg>[FixPunch] Fixed constructor arguments<commit_after><?php

/*
 * This file is part of the TempoSimple project.
 *
 * (c) <NAME> <<EMAIL>>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace TempoSimple\Bundle\SpaghettiBundle\Factory;

use Symfony\Component\Console\Input\InputInterface;
use TempoSimple\Service\TimeTrackingBundle\Query\ActivityQuery;
use TempoSimple\Service\TimeTrackingBundle\Query\BillableQuery;
use TempoSimple\Service\TimeTrackingBundle\Query\DailyQuery;
use TempoSimple\Service\TimeTrackingBundle\Query\PunchQuery;

class ConsoleQueryFactory
{
    /**
     * @param InputInterface $input
     *
     * @return BillableQuery
     */
    public function makeActivity(InputInterface $input)
    {
        $month = $input->getOption('month');

        return new ActivityQuery($month);
    }

    /**
     * @param InputInterface $input
     *
     * @return BillableQuery
     */
    public function makeBillable(InputInterface $input)
    {
        $projectName = $input->getOption('project');
        $month = $input->getOption('month');

        return new BillableQuery($projectName, $month);
    }

    /**
     * @param InputInterface $input
     *
     * @return DailyQuery
     */
    public function makeDaily(InputInterface $input)
    {
        $day = $input->getOption('date');

        return new DailyQuery($day);
    }

    /**
     * @param InputInterface $input
     *
     * @return PunchQuery
     */
    public function makePunch(InputInterface $input)
    {
        $project = $input->getOption('project');
        $task = $input->getArgument('task');
        $date = $input->getOption('date');
        $startHour = $input->getOption('start-hour');
        $endHour = $input->getOption('end-hour');
        $description = $input->getOption('description');

        return new PunchQuery(
            $task,
            $endHour,
            $description,
            $project,
            $startHour,
            $date
        );
    }
}
{'fraction_non_alphanumeric': 0.12247873633049818, 'fraction_numerical': 0.0, 'mean_word_length': 2.6042031523642732, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 29, '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': '1464829', 'n_tokens_mistral': 1179, 'n_tokens_neox': 1157, 'n_words': 243}