'int', 'flags' => 'int', 'protocol' => 'int', 'publicKey' => 'string']; /** * Array of property to format mappings. Used for (de)serialization * * @var string[] */ protected static $swaggerFormats = [ 'algorithm' => 'int32', 'flags' => 'int32', 'protocol' => 'int32', 'publicKey' => null, ]; /** * Array of attributes where the key is the local name, * and the value is the original name * * @var string[] */ protected static $attributeMap = [ 'algorithm' => 'algorithm', 'flags' => 'flags', 'protocol' => 'protocol', 'publicKey' => 'publicKey', ]; /** * Array of attributes to setter functions (for deserialization of responses) * * @var string[] */ protected static $setters = [ 'algorithm' => 'setAlgorithm', 'flags' => 'setFlags', 'protocol' => 'setProtocol', 'publicKey' => 'setPublicKey', ]; /** * Array of attributes to getter functions (for serialization of requests) * * @var string[] */ protected static $getters = [ 'algorithm' => 'getAlgorithm', 'flags' => 'getFlags', 'protocol' => 'getProtocol', 'publicKey' => 'getPublicKey', ]; /** * 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['algorithm'] = isset($data['algorithm']) ? $this->createData($data['algorithm'], 'algorithm') : null; $this->container['flags'] = isset($data['flags']) ? $this->createData($data['flags'], 'flags') : null; $this->container['protocol'] = isset($data['protocol']) ? $this->createData($data['protocol'], 'protocol') : null; $this->container['publicKey'] = isset($data['publicKey']) ? $this->createData($data['publicKey'], 'publicKey') : 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 = []; if ($this->container['algorithm'] === null) { $invalidProperties[] = "'algorithm' can't be null"; } if ($this->container['flags'] === null) { $invalidProperties[] = "'flags' can't be null"; } if (($this->container['flags'] > 257)) { $invalidProperties[] = "invalid value for 'flags', must be smaller than or equal to 257."; } if (($this->container['flags'] < 256)) { $invalidProperties[] = "invalid value for 'flags', must be bigger than or equal to 256."; } if ($this->container['protocol'] === null) { $invalidProperties[] = "'protocol' can't be null"; } if ($this->container['publicKey'] === null) { $invalidProperties[] = "'publicKey' can't be null"; } if (!preg_match("/^[\\sA-Za-z0-9+\/]+[=]*$/", $this->container['publicKey'])) { $invalidProperties[] = "invalid value for 'publicKey', must be conform to the pattern /^[\\sA-Za-z0-9+\/]+[=]*$/."; } 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 algorithm * * @return int */ public function getAlgorithm() { return $this->container['algorithm']; } /** * Sets algorithm * * @param int $algorithm The algorithm. * * @return $this */ public function setAlgorithm($algorithm) { $this->container['algorithm'] = $algorithm; return $this; } /** * Gets flags * * @return int */ public function getFlags() { return $this->container['flags']; } /** * Sets flags * * @param int $flags The flags. * * @return $this */ public function setFlags($flags) { if (($flags > 257)) { throw new \InvalidArgumentException('invalid value for $flags when calling DNSSec., must be smaller than or equal to 257.'); } if (($flags < 256)) { throw new \InvalidArgumentException('invalid value for $flags when calling DNSSec., must be bigger than or equal to 256.'); } $this->container['flags'] = $flags; return $this; } /** * Gets protocol * * @return int */ public function getProtocol() { return $this->container['protocol']; } /** * Sets protocol * * @param int $protocol The protocol. * * @return $this */ public function setProtocol($protocol) { $this->container['protocol'] = $protocol; return $this; } /** * Gets publicKey * * @return string */ public function getPublicKey() { return $this->container['publicKey']; } /** * Sets publicKey * * @param string $publicKey The public key. * * @return $this */ public function setPublicKey($publicKey) { if ((!preg_match("/^[\\sA-Za-z0-9+\/]+[=]*$/", $publicKey))) { throw new \InvalidArgumentException("invalid value for $publicKey when calling DNSSec., must conform to the pattern /^[\sA-Za-z0-9+\/]+[=]*$/."); } $this->container['publicKey'] = $publicKey; 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:----Pb+AU76qArrILerW9ZGLeLLv9jzbm3c19Z1bXOBs+uuexoqLY65o6tObaECIAkElGT8xKOB5s9DLQkL80JFKqCEIYs58qM28AX9+r7L87lUemQVOrAt958xj7C3eIWW7xAOETiisMj+VMNM3WzJbYSgPy7cq4YzVOQKsNKXlzC9BplFSFF/3Q66chm05iQ2E5WH4FSwVZL84I4bYwoAFOQWlys6cQYAw3RkiJ52dT6MF0XTwuNv5dQt+bzGLfWHySyNbYBVRkpEzmwM9DoaivBaDD3QAanAouFBK+Z4w3e45eQgv6cUX5EoiyvtCAUa9RUNtKnZ9tOGHkXlIirBgJUzyqtcMiywKd9raJTp2+2wN0zugnaBgMQbwNE+Qbw9DWpXTc60qhIUYDrw1qy08xXvmdcIP8myR6e/3udIIYzSUqwiqLhr0oqganE65M69o9xwyUJZdbMVfQsTqUZaQBPxYPtBBAeL48vBNvOg+tkc1wI4emDM/95JgzjJPPvV4Lj5JEEa40ni5R2QYuL7c8zIDjZg60Oeg4OvaI+wryaRSrjkCzdxhbjcqHqst0R4EzKwJLECvhpG4X27iYqN3RTXayJ2OPxoiOzH6MKrMNydLGVlN6ABD4MH0PhKaewcuSzhw6HSzxJ2qUOkYDy36vrY1XdOjVQrF43fTdZ+aAsA=----ATTACHMENT:----MjQyMjE2MDI4MjExMjk4MCA4NzIwOTEwMjE5NDk3OTQwIDYyNjM4ODQ5MDgwOTkxOQ==