<commit_before><?php

namespace AppBundle\Entity;

use Doctrine\ORM\Mapping as ORM;
use JsonSerializable;

/**
 * Utility
 *
 * @ORM\Table(name="utility")
 * @ORM\Entity(repositoryClass="AppBundle\Repository\UtilityRepository")
 */
class Utility implements JsonSerializable
{

    const DATE_FORMAT = 'd.m.Y H:i:s';
    /**
     * @var int
     *
     * @ORM\Column(name="id", type="integer")
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="AUTO")
     */
    private $id;

    /**
     * @var string
     *
     * @ORM\Column(name="name", type="string", length=255, unique=true)
     */
    private $name;

    /**
     * @var UtilityRate[]
     * @ORM\OneToMany(targetEntity="AppBundle\Entity\UtilityRate", mappedBy="utility")
     */
    private $rates;

    /**
     * @var Invoice[]
     * @ORM\OneToMany(targetEntity="AppBundle\Entity\Invoice", mappedBy="utility")
     */
    private $invoices;

    /**
     * @var Invoice[]
     * @ORM\OneToMany(targetEntity="AppBundle\Entity\Reading", mappedBy="utility")
     */
    private $readings;


    /**
     * Get id
     *
     * @return int
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * Set name
     *
     * @param string $name
     *
     * @return Utility
     */
    public function setName($name)
    {
        $this->name = $name;

        return $this;
    }

    /**
     * Get name
     *<commit_msg>exclude OneToMany fields from serializing<commit_after><?php

namespace AppBundle\Entity;

use Doctrine\ORM\Mapping as ORM;
use JMS\Serializer\Annotation\Exclude;
use JsonSerializable;

/**
 * Utility
 *
 * @ORM\Table(name="utility")
 * @ORM\Entity(repositoryClass="AppBundle\Repository\UtilityRepository")
 */
class Utility implements JsonSerializable
{

    const DATE_FORMAT = 'd.m.Y H:i:s';
    /**
     * @var int
     *
     * @ORM\Column(name="id", type="integer")
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="AUTO")
     */
    private $id;

    /**
     * @var string
     *
     * @ORM\Column(name="name", type="string", length=255, unique=true)
     */
    private $name;

    /**
     * @var UtilityRate[]
     * @ORM\OneToMany(targetEntity="AppBundle\Entity\UtilityRate", mappedBy="utility")
     * @Exclude
     */
    private $rates;

    /**
     * @var Invoice[]
     * @ORM\OneToMany(targetEntity="AppBundle\Entity\Invoice", mappedBy="utility")
     * @Exclude
     */
    private $invoices;

    /**
     * @var Invoice[]
     * @ORM\OneToMany(targetEntity="AppBundle\Entity\Reading", mappedBy="utility")
     * @Exclude
     */
    private $readings;


    /**
     * Get id
     *
     * @return int
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * Set name
     *
     * @param string $name
     *
     * @return Utility
     */
    public function setName($name)
    {
        $this->name = $name;

        return $this;
    }

    /**
     * Get name
     *
{'fraction_non_alphanumeric': 0.15766224940536866, 'fraction_numerical': 0.0020387359836901123, 'mean_word_length': 2.1758360302049624, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, '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': '5915609', 'n_tokens_mistral': 1005, 'n_tokens_neox': 969, 'n_words': 167}