1: <?php
2: namespace duyplus\tmdbapi\classes\data;
3:
4: /**
5: * This class handles all the data you can get from the api Configuration
6: *
7: * @package TMDB_V3_API_PHP
8: * @author Alvaro Octal
9: * @version 0.7
10: * @date 20/01/2015
11: * @updated 31/12/2024
12: * @link https://github.com/duyplus/tmdbapi
13: * @copyright Licensed under BSD (http://www.opensource.org/licenses/bsd-license.php)
14: */
15:
16: class Genre
17: {
18: //------------------------------------------------------------------------------
19: // Class Variables
20: //------------------------------------------------------------------------------
21:
22: private $_data;
23:
24: /**
25: * Construct Class
26: *
27: * @param array $data An array with the data of a Collection
28: */
29: public function __construct($data)
30: {
31: $this->_data = $data;
32: }
33:
34: //------------------------------------------------------------------------------
35: // Get Variables
36: //------------------------------------------------------------------------------
37:
38: /**
39: * Get the Genre's name
40: *
41: * @return string
42: */
43: public function getName()
44: {
45: return $this->_data['name'];
46: }
47:
48: /**
49: * Get the Genre's id
50: *
51: * @return int
52: */
53: public function getID()
54: {
55: return $this->_data['id'];
56: }
57: }
58: ?>