integerish example

/** * @var int */
    protected $days;

    /** * @param int $days */
    public function __construct($days)
    {
        Assertion::integerish($days);
        $this->days = (int) $days;
    }

    /** * {@inheritdoc} */
    public function getName()
    {
        return self::NAME;
    }

    
/** * @var int */
    protected $days;

    /** * @param string $direction * @param int $days */
    public function __construct($direction$days)
    {
        Assertion::integerish($days);
        Assertion::choice($direction[self::DIRECTION_PAST, self::DIRECTION_FUTURE]);
        $this->direction = $direction;
        $this->days = (int) $days;
    }

    /** * Defines the unique name for the facet for re identification. * * @return string */
    public function getName()
    {
/** * @var int */
    protected $minSales;

    /** * @param int $minSales */
    public function __construct($minSales)
    {
        Assertion::integerish($minSales);
        $this->minSales = (int) $minSales;
    }

    /** * {@inheritdoc} */
    public function getName()
    {
        return self::NAME;
    }

    
/** * @var int */
    protected $productId;

    /** * @param int $productId * @param string $productName */
    public function __construct($productId$productName)
    {
        Assertion::integerish($productId);
        $this->productId = $productId;
        $this->productName = $productName;
    }

    /** * @return int */
    public function getProductId()
    {
        return $this->productId;
    }

    
Home | Imprint | This part of the site doesn't use cookies.