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

https://gitlab.com/i-have-a-green/digitemis-v3 · PHP · 362 lines · 131 code · 43 blank · 188 comment · 3 complexity · 7f168ec8ed5231a8d8f528ec6a968fc9 MD5 · raw file

  1. <?php
  2. /**
  3. * GetChildInfoStatistics
  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. * GetChildInfoStatistics Class Doc Comment
  32. *
  33. * @category Class
  34. * @description Statistics about your child account activity
  35. * @package SendinBlue\Client
  36. * @author Swagger Codegen team
  37. * @link https://github.com/swagger-api/swagger-codegen
  38. */
  39. class GetChildInfoStatistics implements ModelInterface, ArrayAccess
  40. {
  41. const DISCRIMINATOR = null;
  42. /**
  43. * The original name of the model.
  44. *
  45. * @var string
  46. */
  47. protected static $swaggerModelName = 'getChildInfo_statistics';
  48. /**
  49. * Array of property to type mappings. Used for (de)serialization
  50. *
  51. * @var string[]
  52. */
  53. protected static $swaggerTypes = [
  54. 'previousMonthTotalSent' => 'int',
  55. 'currentMonthTotalSent' => 'int',
  56. 'totalSent' => 'int'
  57. ];
  58. /**
  59. * Array of property to format mappings. Used for (de)serialization
  60. *
  61. * @var string[]
  62. */
  63. protected static $swaggerFormats = [
  64. 'previousMonthTotalSent' => 'int64',
  65. 'currentMonthTotalSent' => 'int64',
  66. 'totalSent' => 'int64'
  67. ];
  68. /**
  69. * Array of property to type mappings. Used for (de)serialization
  70. *
  71. * @return array
  72. */
  73. public static function swaggerTypes()
  74. {
  75. return self::$swaggerTypes;
  76. }
  77. /**
  78. * Array of property to format mappings. Used for (de)serialization
  79. *
  80. * @return array
  81. */
  82. public static function swaggerFormats()
  83. {
  84. return self::$swaggerFormats;
  85. }
  86. /**
  87. * Array of attributes where the key is the local name,
  88. * and the value is the original name
  89. *
  90. * @var string[]
  91. */
  92. protected static $attributeMap = [
  93. 'previousMonthTotalSent' => 'previousMonthTotalSent',
  94. 'currentMonthTotalSent' => 'currentMonthTotalSent',
  95. 'totalSent' => 'totalSent'
  96. ];
  97. /**
  98. * Array of attributes to setter functions (for deserialization of responses)
  99. *
  100. * @var string[]
  101. */
  102. protected static $setters = [
  103. 'previousMonthTotalSent' => 'setPreviousMonthTotalSent',
  104. 'currentMonthTotalSent' => 'setCurrentMonthTotalSent',
  105. 'totalSent' => 'setTotalSent'
  106. ];
  107. /**
  108. * Array of attributes to getter functions (for serialization of requests)
  109. *
  110. * @var string[]
  111. */
  112. protected static $getters = [
  113. 'previousMonthTotalSent' => 'getPreviousMonthTotalSent',
  114. 'currentMonthTotalSent' => 'getCurrentMonthTotalSent',
  115. 'totalSent' => 'getTotalSent'
  116. ];
  117. /**
  118. * Array of attributes where the key is the local name,
  119. * and the value is the original name
  120. *
  121. * @return array
  122. */
  123. public static function attributeMap()
  124. {
  125. return self::$attributeMap;
  126. }
  127. /**
  128. * Array of attributes to setter functions (for deserialization of responses)
  129. *
  130. * @return array
  131. */
  132. public static function setters()
  133. {
  134. return self::$setters;
  135. }
  136. /**
  137. * Array of attributes to getter functions (for serialization of requests)
  138. *
  139. * @return array
  140. */
  141. public static function getters()
  142. {
  143. return self::$getters;
  144. }
  145. /**
  146. * The original name of the model.
  147. *
  148. * @return string
  149. */
  150. public function getModelName()
  151. {
  152. return self::$swaggerModelName;
  153. }
  154. /**
  155. * Associative array for storing property values
  156. *
  157. * @var mixed[]
  158. */
  159. protected $container = [];
  160. /**
  161. * Constructor
  162. *
  163. * @param mixed[] $data Associated array of property values
  164. * initializing the model
  165. */
  166. public function __construct(array $data = null)
  167. {
  168. $this->container['previousMonthTotalSent'] = isset($data['previousMonthTotalSent']) ? $data['previousMonthTotalSent'] : null;
  169. $this->container['currentMonthTotalSent'] = isset($data['currentMonthTotalSent']) ? $data['currentMonthTotalSent'] : null;
  170. $this->container['totalSent'] = isset($data['totalSent']) ? $data['totalSent'] : null;
  171. }
  172. /**
  173. * Show all the invalid properties with reasons.
  174. *
  175. * @return array invalid properties with reasons
  176. */
  177. public function listInvalidProperties()
  178. {
  179. $invalidProperties = [];
  180. return $invalidProperties;
  181. }
  182. /**
  183. * Validate all the properties in the model
  184. * return true if all passed
  185. *
  186. * @return bool True if all properties are valid
  187. */
  188. public function valid()
  189. {
  190. return count($this->listInvalidProperties()) === 0;
  191. }
  192. /**
  193. * Gets previousMonthTotalSent
  194. *
  195. * @return int
  196. */
  197. public function getPreviousMonthTotalSent()
  198. {
  199. return $this->container['previousMonthTotalSent'];
  200. }
  201. /**
  202. * Sets previousMonthTotalSent
  203. *
  204. * @param int $previousMonthTotalSent Overall emails sent for the previous month
  205. *
  206. * @return $this
  207. */
  208. public function setPreviousMonthTotalSent($previousMonthTotalSent)
  209. {
  210. $this->container['previousMonthTotalSent'] = $previousMonthTotalSent;
  211. return $this;
  212. }
  213. /**
  214. * Gets currentMonthTotalSent
  215. *
  216. * @return int
  217. */
  218. public function getCurrentMonthTotalSent()
  219. {
  220. return $this->container['currentMonthTotalSent'];
  221. }
  222. /**
  223. * Sets currentMonthTotalSent
  224. *
  225. * @param int $currentMonthTotalSent Overall emails sent for current month
  226. *
  227. * @return $this
  228. */
  229. public function setCurrentMonthTotalSent($currentMonthTotalSent)
  230. {
  231. $this->container['currentMonthTotalSent'] = $currentMonthTotalSent;
  232. return $this;
  233. }
  234. /**
  235. * Gets totalSent
  236. *
  237. * @return int
  238. */
  239. public function getTotalSent()
  240. {
  241. return $this->container['totalSent'];
  242. }
  243. /**
  244. * Sets totalSent
  245. *
  246. * @param int $totalSent Overall emails sent for since the account exists
  247. *
  248. * @return $this
  249. */
  250. public function setTotalSent($totalSent)
  251. {
  252. $this->container['totalSent'] = $totalSent;
  253. return $this;
  254. }
  255. /**
  256. * Returns true if offset exists. False otherwise.
  257. *
  258. * @param integer $offset Offset
  259. *
  260. * @return boolean
  261. */
  262. public function offsetExists($offset)
  263. {
  264. return isset($this->container[$offset]);
  265. }
  266. /**
  267. * Gets offset.
  268. *
  269. * @param integer $offset Offset
  270. *
  271. * @return mixed
  272. */
  273. public function offsetGet($offset)
  274. {
  275. return isset($this->container[$offset]) ? $this->container[$offset] : null;
  276. }
  277. /**
  278. * Sets value based on offset.
  279. *
  280. * @param integer $offset Offset
  281. * @param mixed $value Value to be set
  282. *
  283. * @return void
  284. */
  285. public function offsetSet($offset, $value)
  286. {
  287. if (is_null($offset)) {
  288. $this->container[] = $value;
  289. } else {
  290. $this->container[$offset] = $value;
  291. }
  292. }
  293. /**
  294. * Unsets offset.
  295. *
  296. * @param integer $offset Offset
  297. *
  298. * @return void
  299. */
  300. public function offsetUnset($offset)
  301. {
  302. unset($this->container[$offset]);
  303. }
  304. /**
  305. * Gets the string presentation of the object
  306. *
  307. * @return string
  308. */
  309. public function __toString()
  310. {
  311. if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
  312. return json_encode(
  313. ObjectSerializer::sanitizeForSerialization($this),
  314. JSON_PRETTY_PRINT
  315. );
  316. }
  317. return json_encode(ObjectSerializer::sanitizeForSerialization($this));
  318. }
  319. }