/src/bnetlib/Resource/Entity/Wow/Item/Stat.php
PHP | 101 lines | 38 code | 12 blank | 51 comment | 0 complexity | 0730d60dd72ab14969e4b8e44d2f69be MD5 | raw file
- <?php
- /**
- * This file is part of the bnetlib Library.
- * Copyright (c) 2012 Eric Boh <cossish@gmail.com>
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code. You can also view the
- * LICENSE file online at http://coss.github.com/bnetlib/license.html
- *
- * @category bnetlib
- * @package Resource
- * @subpackage WorldOfWarcraft
- * @copyright 2012 Eric Boh <cossish@gmail.com>
- * @license http://coss.gitbub.com/bnetlib/license.html MIT License
- */
- namespace bnetlib\Resource\Entity\Wow\Item;
- use bnetlib\Resource\Entity\EntityInterface;
- use bnetlib\ServiceLocator\ServiceLocatorInterface;
- /**
- * @category bnetlib
- * @package Resource
- * @subpackage WorldOfWarcraft
- * @copyright 2012 Eric Boh <cossish@gmail.com>
- * @license http://coss.gitbub.com/bnetlib/license.html MIT License
- */
- class Stat implements EntityInterface
- {
- /**
- * @var array
- */
- protected $data = array();
- /**
- * @var array|null
- */
- protected $headers;
- /**
- * @var ServiceLocatorInterface
- */
- protected $serviceLocator;
- /**
- * @inheritdoc
- */
- public function populate($data)
- {
- $this->data = $data;
- }
- /**
- * @inheritdoc
- */
- public function getResponseHeaders()
- {
- return $this->headers;
- }
- /**
- * @inheritdoc
- */
- public function setResponseHeaders($headers)
- {
- $this->headers = $headers;
- }
- /**
- * @inheritdoc
- */
- public function setServiceLocator(ServiceLocatorInterface $locator)
- {
- $this->serviceLocator = $locator;
- }
- /**
- * @return integer
- */
- public function getId()
- {
- return $this->data['stat'];
- }
- /**
- * @return integer
- */
- public function getAmount()
- {
- return $this->data['amount'];
- }
- /**
- * @return boolean
- */
- public function isReforged()
- {
- return $this->data['reforged'];
- }
- }