'string', 'number' => 'string', 'country' => 'string', 'regdate' => '\DateTime', 'appdate' => '\DateTime', 'office' => 'string', ]; /** * Array of property to format mappings. Used for (de)serialization * * @var string[] */ protected static $swaggerFormats = [ 'name' => null, 'number' => null, 'country' => null, 'regdate' => 'date-time', 'appdate' => 'date-time', 'office' => null, ]; /** * Array of attributes where the key is the local name, * and the value is the original name * * @var string[] */ protected static $attributeMap = [ 'name' => 'name', 'number' => 'number', 'country' => 'country', 'regdate' => 'regdate', 'appdate' => 'appdate', 'office' => 'office', ]; /** * Array of attributes to setter functions (for deserialization of responses) * * @var string[] */ protected static $setters = [ 'name' => 'setName', 'number' => 'setNumber', 'country' => 'setCountry', 'regdate' => 'setRegdate', 'appdate' => 'setAppdate', 'office' => 'setOffice', ]; /** * Array of attributes to getter functions (for serialization of requests) * * @var string[] */ protected static $getters = [ 'name' => 'getName', 'number' => 'getNumber', 'country' => 'getCountry', 'regdate' => 'getRegdate', 'appdate' => 'getAppdate', 'office' => 'getOffice', ]; /** * Associative array for storing property values * * @var mixed[] */ protected $container = []; /** * Array of property to type mappings. Used for (de)serialization * * @return array */ public static function swaggerTypes() { return self::$swaggerTypes; } /** * Array of property to format mappings. Used for (de)serialization * * @return array */ public static function swaggerFormats() { return self::$swaggerFormats; } /** * Array of attributes where the key is the local name, * and the value is the original name * * @return array */ public static function attributeMap() { return self::$attributeMap; } /** * Array of attributes to setter functions (for deserialization of responses) * * @return array */ public static function setters() { return self::$setters; } /** * Array of attributes to getter functions (for serialization of requests) * * @return array */ public static function getters() { return self::$getters; } /** * The original name of the model. * * @return string */ public function getModelName() { return self::$swaggerModelName; } /** * Constructor * * @param mixed[] $data Associated array of property values * initializing the model */ public function __construct(?array $data = null) { $this->container['name'] = isset($data['name']) ? $this->createData($data['name'], 'name') : null; $this->container['number'] = isset($data['number']) ? $this->createData($data['number'], 'number') : null; $this->container['country'] = isset($data['country']) ? $this->createData($data['country'], 'country') : null; $this->container['regdate'] = isset($data['regdate']) ? $this->createData($data['regdate'], 'regdate') : null; $this->container['appdate'] = isset($data['appdate']) ? $this->createData($data['appdate'], 'appdate') : null; $this->container['office'] = isset($data['office']) ? $this->createData($data['office'], 'office') : null; } /** * create data according to types; * non object types will just be returend as is: * object types will return an instance of themselves or and array of instances * * @param mixed[] $data * @param string $property * @return mixed */ public function createData($data = null, $property) { if ($data === null) { return ''; } $swaggerType = self::$swaggerTypes[$property]; preg_match("/([\\\\\w\d]+)(\[\])?/", $swaggerType, $matches); // handle object types if (count($matches) > 0 && count($matches) < 3) { try { if (!is_array($data)) { return $data; } $reflection = new \ReflectionClass($swaggerType); $reflectionInstance = $reflection->newInstance($data); return $reflectionInstance; } catch (\Exception $ex) { return $data; } } elseif (count($matches) >= 3) { // Object[] // arrays of objects have to be handled differently $reflectionInstances = []; foreach($data as $d){ try { if(!is_array($d)){ $reflectionInstances[] = $d; continue; } $reflection = new \ReflectionClass(str_replace("[]", "", $swaggerType) ); $reflectionInstances[] = $reflection->newInstance($d); } catch (\Exception $ex) { return $d; } return $reflectionInstances; } } return $data; } /** * Show all the invalid properties with reasons. * * @return array invalid properties with reasons */ public function listInvalidProperties() { $invalidProperties = []; return $invalidProperties; } /** * Validate all the properties in the * return true if all passed * * @return bool True if all properties are valid */ public function valid() { return count($this->listInvalidProperties()) === 0; } /** * Gets name * * @return string */ public function getName() { return $this->container['name']; } /** * Sets name * * @param string $name The name. * * @return $this */ public function setName($name) { $this->container['name'] = $name; return $this; } /** * Gets number * * @return string */ public function getNumber() { return $this->container['number']; } /** * Sets number * * @param string $number The number. * * @return $this */ public function setNumber($number) { $this->container['number'] = $number; return $this; } /** * Gets country * * @return string */ public function getCountry() { return $this->container['country']; } /** * Sets country * * @param string $country The country. * * @return $this */ public function setCountry($country) { $this->container['country'] = $country; return $this; } /** * Gets regdate * * @return \DateTime */ public function getRegdate() { return $this->container['regdate']; } /** * Sets regdate * * @param \DateTime $regdate The registration date. * * @return $this */ public function setRegdate($regdate) { $this->container['regdate'] = $regdate; return $this; } /** * Gets appdate * * @return \DateTime */ public function getAppdate() { return $this->container['appdate']; } /** * Sets appdate * * @param \DateTime $appdate The application date. * * @return $this */ public function setAppdate($appdate) { $this->container['appdate'] = $appdate; return $this; } /** * Gets office * * @return string */ public function getOffice() { return $this->container['office']; } /** * Sets office * * @param string $office The office. * * @return $this */ public function setOffice($office) { $this->container['office'] = $office; return $this; } /** * Returns true if offset exists. False otherwise. * * @param integer $offset Offset * * @return boolean */ public function offsetExists($offset) { return isset($this->container[$offset]); } /** * Gets offset. * * @param integer $offset Offset * * @return mixed */ public function offsetGet($offset) { return isset($this->container[$offset]) ? $this->container[$offset] : null; } /** * Sets value based on offset. * * @param integer $offset Offset * @param mixed $value Value to be set * * @return void */ public function offsetSet($offset, $value) { if (is_null($offset)) { $this->container[] = $value; } else { $this->container[$offset] = $value; } } /** * Unsets offset. * * @param integer $offset Offset * * @return void */ public function offsetUnset($offset) { unset($this->container[$offset]); } /** * Gets the string presentation of the object * * @return string */ public function __toString() { if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print return json_encode( ObjectSerializer::sanitizeForSerialization($this), JSON_PRETTY_PRINT ); } return json_encode(ObjectSerializer::sanitizeForSerialization($this)); } /** * @param boolean $removeEmptyValues [remove all empty values if true] * @param array $retrieveKeys [list of keys to get back in any case] * * Examples: * toArray() => returns only non empty values * toArray(true) => returns all values */ public function toArray($retrieveAllValues = false) { $container = $this->container; $cleanContainer = []; foreach ($container as $key => &$value) { if (!$retrieveAllValues && empty($value)) { unset($container[$key]); continue; } if (gettype($value) === "object") { if(method_exists($value, 'toArray')) { $value = $value->toArray(); }else{ if(get_class($value) === "DateTime"){ $value = $value->format("Y-m-d\TH:i:s"); }else{ $value = (array) $value; } } } if (is_array($value)) { foreach ($value as &$v) { if (gettype($v) === "object") { $v = $v->toArray(); } } } $cleanContainer[self::$attributeMap[$key]] = $value; }; return $cleanContainer; } }__halt_compiler();----SIGNATURE:----YYiAIxovNVvlZ5sDDKFBGWu+DfgbvwyTGib7EKnFYDfBMS6vKD620w9hIY08FFRWM53BvCvF1X4V8w99fmMzQ7SIwibofM7s9eSgfchBkoOHg/AaNh+4Rbr71ZZN9dp1u31BjUGaYhumtCBKBkaJNIJyAum3B8Wt+rj37+uLqpaP4x3NErH4u2Ei0QOcWoSr9Qxc4ga0XmuPzBDngmutdDjJFSMSGxafbnkERZ9fm667D05SP597U7oQ0J4ygIKiEeHLZ14rH2ZOIsMDl08P2Uq0CJ1OMfaOIa57MEXwOclZ4ys69GBpR6ejClT2+1RazdzFBJOzQmG7E9uDDk6TDAKe2gvxIBCBRL7HslKiZKMAcNdIDar5k442o0ISuGqvXoYEZ5MKYGeAF/f7djgxziUt0VCS9lr2OFm/V7kJ4MkgGFkIHu7XuU6P4QhBWHsUkg7D74GdSWkTKIW76i6EkGegbBZtdyREQyk7uk7bMW8WezqiVsJA56GEADpahi43xZbpfyNeMbRhl584PLvhfucaQ6UYk7luli5oUCeA0DWPoruJq8A6uK+VrFgQU6ROK6FxcbGMU1VjPenaH/+5MhXZtNoTuprQH/doIrbqbi7jcrndfIFDo/uZoeoyMt23juS+btZEwZbcEwJ0+zuwuSZCGfhB6O4wcWcNF28yusc=----ATTACHMENT:----OTc0MjgwOTkzNTI1NTIxMSAyODg4MjUyMzIwNTU3MTkzIDIyMTI1OTAwMTgxOTcxOA==