open-orchestra/open-orchestra-mongo-libs

View on GitHub
MongoTrait/Cacheable.php

Summary

Maintainability
A
0 mins
Test Coverage
<?php

namespace OpenOrchestra\MongoTrait;

use Doctrine\ODM\MongoDB\Mapping\Annotations as ODM;

/**
 * Class Cacheable
 */
trait Cacheable
{
    /**
     * @var int $id
     *
     * @ODM\Field(type="int")
     */
    protected $maxAge;

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

    /**
     * @param int $maxAge
     */
    public function setMaxAge($maxAge)
    {
        $this->maxAge = $maxAge;
    }
}