PageRenderTime 49ms CodeModel.GetById 21ms RepoModel.GetById 1ms app.codeStats 0ms

/vendor/sendinblue/api-v3-sdk/lib/Model/GetDeviceBrowserStats.php

https://gitlab.com/i-have-a-green/digitemis-v3
PHP | 403 lines | 158 code | 46 blank | 199 comment | 5 complexity | 248cecbc120f01980654b02878046a86 MD5 | raw file
  1. <?php
  2. /**
  3. * GetDeviceBrowserStats
  4. *
  5. * PHP version 5
  6. *
  7. * @category Class
  8. * @package SendinBlue\Client
  9. * @author Swagger Codegen team
  10. * @link https://github.com/swagger-api/swagger-codegen
  11. */
  12. /**
  13. * SendinBlue API
  14. *
  15. * SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed | | 406 | Error. Not Acceptable |
  16. *
  17. * OpenAPI spec version: 3.0.0
  18. * Contact: contact@sendinblue.com
  19. * Generated by: https://github.com/swagger-api/swagger-codegen.git
  20. * Swagger Codegen version: 2.4.12
  21. */
  22. /**
  23. * NOTE: This class is auto generated by the swagger code generator program.
  24. * https://github.com/swagger-api/swagger-codegen
  25. * Do not edit the class manually.
  26. */
  27. namespace SendinBlue\Client\Model;
  28. use \ArrayAccess;
  29. use \SendinBlue\Client\ObjectSerializer;
  30. /**
  31. * GetDeviceBrowserStats Class Doc Comment
  32. *
  33. * @category Class
  34. * @package SendinBlue\Client
  35. * @author Swagger Codegen team
  36. * @link https://github.com/swagger-api/swagger-codegen
  37. */
  38. class GetDeviceBrowserStats implements ModelInterface, ArrayAccess
  39. {
  40. const DISCRIMINATOR = null;
  41. /**
  42. * The original name of the model.
  43. *
  44. * @var string
  45. */
  46. protected static $swaggerModelName = 'getDeviceBrowserStats';
  47. /**
  48. * Array of property to type mappings. Used for (de)serialization
  49. *
  50. * @var string[]
  51. */
  52. protected static $swaggerTypes = [
  53. 'clickers' => 'int',
  54. 'uniqueClicks' => 'int',
  55. 'viewed' => 'int',
  56. 'uniqueViews' => 'int'
  57. ];
  58. /**
  59. * Array of property to format mappings. Used for (de)serialization
  60. *
  61. * @var string[]
  62. */
  63. protected static $swaggerFormats = [
  64. 'clickers' => 'int64',
  65. 'uniqueClicks' => 'int64',
  66. 'viewed' => 'int64',
  67. 'uniqueViews' => 'int64'
  68. ];
  69. /**
  70. * Array of property to type mappings. Used for (de)serialization
  71. *
  72. * @return array
  73. */
  74. public static function swaggerTypes()
  75. {
  76. return self::$swaggerTypes;
  77. }
  78. /**
  79. * Array of property to format mappings. Used for (de)serialization
  80. *
  81. * @return array
  82. */
  83. public static function swaggerFormats()
  84. {
  85. return self::$swaggerFormats;
  86. }
  87. /**
  88. * Array of attributes where the key is the local name,
  89. * and the value is the original name
  90. *
  91. * @var string[]
  92. */
  93. protected static $attributeMap = [
  94. 'clickers' => 'clickers',
  95. 'uniqueClicks' => 'uniqueClicks',
  96. 'viewed' => 'viewed',
  97. 'uniqueViews' => 'uniqueViews'
  98. ];
  99. /**
  100. * Array of attributes to setter functions (for deserialization of responses)
  101. *
  102. * @var string[]
  103. */
  104. protected static $setters = [
  105. 'clickers' => 'setClickers',
  106. 'uniqueClicks' => 'setUniqueClicks',
  107. 'viewed' => 'setViewed',
  108. 'uniqueViews' => 'setUniqueViews'
  109. ];
  110. /**
  111. * Array of attributes to getter functions (for serialization of requests)
  112. *
  113. * @var string[]
  114. */
  115. protected static $getters = [
  116. 'clickers' => 'getClickers',
  117. 'uniqueClicks' => 'getUniqueClicks',
  118. 'viewed' => 'getViewed',
  119. 'uniqueViews' => 'getUniqueViews'
  120. ];
  121. /**
  122. * Array of attributes where the key is the local name,
  123. * and the value is the original name
  124. *
  125. * @return array
  126. */
  127. public static function attributeMap()
  128. {
  129. return self::$attributeMap;
  130. }
  131. /**
  132. * Array of attributes to setter functions (for deserialization of responses)
  133. *
  134. * @return array
  135. */
  136. public static function setters()
  137. {
  138. return self::$setters;
  139. }
  140. /**
  141. * Array of attributes to getter functions (for serialization of requests)
  142. *
  143. * @return array
  144. */
  145. public static function getters()
  146. {
  147. return self::$getters;
  148. }
  149. /**
  150. * The original name of the model.
  151. *
  152. * @return string
  153. */
  154. public function getModelName()
  155. {
  156. return self::$swaggerModelName;
  157. }
  158. /**
  159. * Associative array for storing property values
  160. *
  161. * @var mixed[]
  162. */
  163. protected $container = [];
  164. /**
  165. * Constructor
  166. *
  167. * @param mixed[] $data Associated array of property values
  168. * initializing the model
  169. */
  170. public function __construct(array $data = null)
  171. {
  172. $this->container['clickers'] = isset($data['clickers']) ? $data['clickers'] : null;
  173. $this->container['uniqueClicks'] = isset($data['uniqueClicks']) ? $data['uniqueClicks'] : null;
  174. $this->container['viewed'] = isset($data['viewed']) ? $data['viewed'] : null;
  175. $this->container['uniqueViews'] = isset($data['uniqueViews']) ? $data['uniqueViews'] : null;
  176. }
  177. /**
  178. * Show all the invalid properties with reasons.
  179. *
  180. * @return array invalid properties with reasons
  181. */
  182. public function listInvalidProperties()
  183. {
  184. $invalidProperties = [];
  185. if ($this->container['clickers'] === null) {
  186. $invalidProperties[] = "'clickers' can't be null";
  187. }
  188. if ($this->container['uniqueClicks'] === null) {
  189. $invalidProperties[] = "'uniqueClicks' can't be null";
  190. }
  191. if ($this->container['viewed'] === null) {
  192. $invalidProperties[] = "'viewed' can't be null";
  193. }
  194. if ($this->container['uniqueViews'] === null) {
  195. $invalidProperties[] = "'uniqueViews' can't be null";
  196. }
  197. return $invalidProperties;
  198. }
  199. /**
  200. * Validate all the properties in the model
  201. * return true if all passed
  202. *
  203. * @return bool True if all properties are valid
  204. */
  205. public function valid()
  206. {
  207. return count($this->listInvalidProperties()) === 0;
  208. }
  209. /**
  210. * Gets clickers
  211. *
  212. * @return int
  213. */
  214. public function getClickers()
  215. {
  216. return $this->container['clickers'];
  217. }
  218. /**
  219. * Sets clickers
  220. *
  221. * @param int $clickers Number of total clicks for the campaign using the particular browser
  222. *
  223. * @return $this
  224. */
  225. public function setClickers($clickers)
  226. {
  227. $this->container['clickers'] = $clickers;
  228. return $this;
  229. }
  230. /**
  231. * Gets uniqueClicks
  232. *
  233. * @return int
  234. */
  235. public function getUniqueClicks()
  236. {
  237. return $this->container['uniqueClicks'];
  238. }
  239. /**
  240. * Sets uniqueClicks
  241. *
  242. * @param int $uniqueClicks Number of unique clicks for the campaign using the particular browser
  243. *
  244. * @return $this
  245. */
  246. public function setUniqueClicks($uniqueClicks)
  247. {
  248. $this->container['uniqueClicks'] = $uniqueClicks;
  249. return $this;
  250. }
  251. /**
  252. * Gets viewed
  253. *
  254. * @return int
  255. */
  256. public function getViewed()
  257. {
  258. return $this->container['viewed'];
  259. }
  260. /**
  261. * Sets viewed
  262. *
  263. * @param int $viewed Number of openings for the campaign using the particular browser
  264. *
  265. * @return $this
  266. */
  267. public function setViewed($viewed)
  268. {
  269. $this->container['viewed'] = $viewed;
  270. return $this;
  271. }
  272. /**
  273. * Gets uniqueViews
  274. *
  275. * @return int
  276. */
  277. public function getUniqueViews()
  278. {
  279. return $this->container['uniqueViews'];
  280. }
  281. /**
  282. * Sets uniqueViews
  283. *
  284. * @param int $uniqueViews Number of unique openings for the campaign using the particular browser
  285. *
  286. * @return $this
  287. */
  288. public function setUniqueViews($uniqueViews)
  289. {
  290. $this->container['uniqueViews'] = $uniqueViews;
  291. return $this;
  292. }
  293. /**
  294. * Returns true if offset exists. False otherwise.
  295. *
  296. * @param integer $offset Offset
  297. *
  298. * @return boolean
  299. */
  300. public function offsetExists($offset)
  301. {
  302. return isset($this->container[$offset]);
  303. }
  304. /**
  305. * Gets offset.
  306. *
  307. * @param integer $offset Offset
  308. *
  309. * @return mixed
  310. */
  311. public function offsetGet($offset)
  312. {
  313. return isset($this->container[$offset]) ? $this->container[$offset] : null;
  314. }
  315. /**
  316. * Sets value based on offset.
  317. *
  318. * @param integer $offset Offset
  319. * @param mixed $value Value to be set
  320. *
  321. * @return void
  322. */
  323. public function offsetSet($offset, $value)
  324. {
  325. if (is_null($offset)) {
  326. $this->container[] = $value;
  327. } else {
  328. $this->container[$offset] = $value;
  329. }
  330. }
  331. /**
  332. * Unsets offset.
  333. *
  334. * @param integer $offset Offset
  335. *
  336. * @return void
  337. */
  338. public function offsetUnset($offset)
  339. {
  340. unset($this->container[$offset]);
  341. }
  342. /**
  343. * Gets the string presentation of the object
  344. *
  345. * @return string
  346. */
  347. public function __toString()
  348. {
  349. if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
  350. return json_encode(
  351. ObjectSerializer::sanitizeForSerialization($this),
  352. JSON_PRETTY_PRINT
  353. );
  354. }
  355. return json_encode(ObjectSerializer::sanitizeForSerialization($this));
  356. }
  357. }