<?php


namespace CubiStore\Web\Model;

use Doctrine\ORM\Mapping as ORM;

/**
 * @ORM\Entity
 * @ORM\Table(name="release")
 */
class Release
{
    /**
     * @var integer
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="AUTO")
     * @ORM\Column(type="bigint")
     */
    private $id;

    /**
     * @var \DateTime
     */
    private $added;

    /**
     * @var App
     * @ORM\ManyToOne(targetEntity="App", inversedBy="releases")
     */
    private $app;

    /**
     * @var integer
     * @ORM\Column(type="integer")
     */
    private $minSdkVersion;

    /**
     * @var integer
     * @ORM\Column(type="integer")
     */
    private $targetSdkVersion;

    /**
     * @var string
     */
    private $hash;

    /**
     * @var string
     */
    private $hashAlgorithm;

    /**
     * @var integer
     */
    private $size;

    /**
     * @var string
     * @ORM\Column(type="string")
     */
    private $versionName;

    /**
     * @var integer
     * @ORM\Column(type="integer")
     */
    private $versionCode;

    /**
     * @var string
     * @ORM\Column(type="string")
     */
    private $apk;

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

    /**
     * @return App
     */
    public function getApp(): App
    {
        return $this->app;
    }

    /**
     * @param App $app
     */
    public function setApp(App $app): void
    {
        $this->app = $app;
    }

    /**
     * @return string
     */
    public function getVersionName(): string
    {
        return $this->versionName;
    }

    /**
     * @param string $versionName
     */
    public function setVersionName(string $versionName): void
    {
        $this->versionName = $versionName;
    }

    /**
     * @return int
     */
    public function getVersionCode(): int
    {
        return $this->versionCode;
    }

    /**
     * @param int $versionCode
     */
    public function setVersionCode(int $versionCode): void
    {
        $this->versionCode = $versionCode;
    }

    /**
     * @return string
     */
    public function getApk(): string
    {
        return $this->apk;
    }

    /**
     * @param string $apk
     */
    public function setApk(string $apk): void
    {
        $this->apk = $apk;
    }
}
