Cleanup the models
This commit is contained in:
@ -16,7 +16,7 @@
|
||||
* Play perudo with your friends through the api!
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
*
|
||||
*
|
||||
* Generated by: https://github.com/swagger-api/swagger-codegen.git
|
||||
* Swagger Codegen version: 3.0.30
|
||||
*/
|
||||
@ -39,44 +39,44 @@ use \Swagger\Client\ObjectSerializer;
|
||||
* @author Swagger Codegen team
|
||||
* @link https://github.com/swagger-api/swagger-codegen
|
||||
*/
|
||||
class PlayerCode implements ModelInterface, ArrayAccess
|
||||
{
|
||||
class PlayerCode implements ModelInterface, ArrayAccess {
|
||||
const DISCRIMINATOR = null;
|
||||
|
||||
/**
|
||||
* The original name of the model.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
* The original name of the model.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected static $swaggerModelName = 'PlayerCode';
|
||||
|
||||
/**
|
||||
* Array of property to type mappings. Used for (de)serialization
|
||||
*
|
||||
* @var string[]
|
||||
*/
|
||||
* Array of property to type mappings. Used for (de)serialization
|
||||
*
|
||||
* @var string[]
|
||||
*/
|
||||
protected static $swaggerTypes = [
|
||||
'player' => '\Swagger\Client\Model\Player',
|
||||
'code' => 'string',
|
||||
'errors' => 'string[]' ];
|
||||
'player' => Player::class,
|
||||
'code' => 'string',
|
||||
'errors' => 'string[]',
|
||||
];
|
||||
|
||||
/**
|
||||
* Array of property to format mappings. Used for (de)serialization
|
||||
*
|
||||
* @var string[]
|
||||
*/
|
||||
* Array of property to format mappings. Used for (de)serialization
|
||||
*
|
||||
* @var string[]
|
||||
*/
|
||||
protected static $swaggerFormats = [
|
||||
'player' => null,
|
||||
'code' => null,
|
||||
'errors' => null ];
|
||||
'code' => null,
|
||||
'errors' => null,
|
||||
];
|
||||
|
||||
/**
|
||||
* Array of property to type mappings. Used for (de)serialization
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public static function swaggerTypes()
|
||||
{
|
||||
public static function swaggerTypes() {
|
||||
return self::$swaggerTypes;
|
||||
}
|
||||
|
||||
@ -85,8 +85,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public static function swaggerFormats()
|
||||
{
|
||||
public static function swaggerFormats() {
|
||||
return self::$swaggerFormats;
|
||||
}
|
||||
|
||||
@ -98,8 +97,9 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*/
|
||||
protected static $attributeMap = [
|
||||
'player' => 'player',
|
||||
'code' => 'code',
|
||||
'errors' => 'errors' ];
|
||||
'code' => 'code',
|
||||
'errors' => 'errors',
|
||||
];
|
||||
|
||||
/**
|
||||
* Array of attributes to setter functions (for deserialization of responses)
|
||||
@ -108,8 +108,9 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*/
|
||||
protected static $setters = [
|
||||
'player' => 'setPlayer',
|
||||
'code' => 'setCode',
|
||||
'errors' => 'setErrors' ];
|
||||
'code' => 'setCode',
|
||||
'errors' => 'setErrors',
|
||||
];
|
||||
|
||||
/**
|
||||
* Array of attributes to getter functions (for serialization of requests)
|
||||
@ -118,8 +119,9 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*/
|
||||
protected static $getters = [
|
||||
'player' => 'getPlayer',
|
||||
'code' => 'getCode',
|
||||
'errors' => 'getErrors' ];
|
||||
'code' => 'getCode',
|
||||
'errors' => 'getErrors',
|
||||
];
|
||||
|
||||
/**
|
||||
* Array of attributes where the key is the local name,
|
||||
@ -127,8 +129,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public static function attributeMap()
|
||||
{
|
||||
public static function attributeMap() {
|
||||
return self::$attributeMap;
|
||||
}
|
||||
|
||||
@ -137,8 +138,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public static function setters()
|
||||
{
|
||||
public static function setters() {
|
||||
return self::$setters;
|
||||
}
|
||||
|
||||
@ -147,8 +147,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public static function getters()
|
||||
{
|
||||
public static function getters() {
|
||||
return self::$getters;
|
||||
}
|
||||
|
||||
@ -157,13 +156,10 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getModelName()
|
||||
{
|
||||
public function getModelName() {
|
||||
return self::$swaggerModelName;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Associative array for storing property values
|
||||
*
|
||||
@ -177,11 +173,10 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
* @param mixed[] $data Associated array of property values
|
||||
* initializing the model
|
||||
*/
|
||||
public function __construct(array $data = null)
|
||||
{
|
||||
$this->container['player'] = isset($data['player']) ? $data['player'] : null;
|
||||
$this->container['code'] = isset($data['code']) ? $data['code'] : null;
|
||||
$this->container['errors'] = isset($data['errors']) ? $data['errors'] : null;
|
||||
public function __construct(array $data = null) {
|
||||
$this->container['player'] = $data['player'] ?? null;
|
||||
$this->container['code'] = $data['code'] ?? null;
|
||||
$this->container['errors'] = $data['errors'] ?? null;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -189,8 +184,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return array invalid properties with reasons
|
||||
*/
|
||||
public function listInvalidProperties()
|
||||
{
|
||||
public function listInvalidProperties() {
|
||||
$invalidProperties = [];
|
||||
|
||||
return $invalidProperties;
|
||||
@ -202,19 +196,16 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return bool True if all properties are valid
|
||||
*/
|
||||
public function valid()
|
||||
{
|
||||
public function valid() {
|
||||
return count($this->listInvalidProperties()) === 0;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Gets player
|
||||
*
|
||||
* @return \Swagger\Client\Model\Player
|
||||
*/
|
||||
public function getPlayer()
|
||||
{
|
||||
public function getPlayer() {
|
||||
return $this->container['player'];
|
||||
}
|
||||
|
||||
@ -225,8 +216,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return $this
|
||||
*/
|
||||
public function setPlayer($player)
|
||||
{
|
||||
public function setPlayer($player) {
|
||||
$this->container['player'] = $player;
|
||||
|
||||
return $this;
|
||||
@ -237,8 +227,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getCode()
|
||||
{
|
||||
public function getCode() {
|
||||
return $this->container['code'];
|
||||
}
|
||||
|
||||
@ -249,8 +238,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return $this
|
||||
*/
|
||||
public function setCode($code)
|
||||
{
|
||||
public function setCode($code) {
|
||||
$this->container['code'] = $code;
|
||||
|
||||
return $this;
|
||||
@ -261,8 +249,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return string[]
|
||||
*/
|
||||
public function getErrors()
|
||||
{
|
||||
public function getErrors() {
|
||||
return $this->container['errors'];
|
||||
}
|
||||
|
||||
@ -273,12 +260,12 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return $this
|
||||
*/
|
||||
public function setErrors($errors)
|
||||
{
|
||||
public function setErrors($errors) {
|
||||
$this->container['errors'] = $errors;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns true if offset exists. False otherwise.
|
||||
*
|
||||
@ -286,8 +273,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function offsetExists($offset)
|
||||
{
|
||||
public function offsetExists($offset) {
|
||||
return isset($this->container[$offset]);
|
||||
}
|
||||
|
||||
@ -298,8 +284,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
public function offsetGet($offset)
|
||||
{
|
||||
public function offsetGet($offset) {
|
||||
return isset($this->container[$offset]) ? $this->container[$offset] : null;
|
||||
}
|
||||
|
||||
@ -311,8 +296,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function offsetSet($offset, $value)
|
||||
{
|
||||
public function offsetSet($offset, $value) {
|
||||
if (is_null($offset)) {
|
||||
$this->container[] = $value;
|
||||
} else {
|
||||
@ -327,8 +311,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function offsetUnset($offset)
|
||||
{
|
||||
public function offsetUnset($offset) {
|
||||
unset($this->container[$offset]);
|
||||
}
|
||||
|
||||
@ -337,8 +320,7 @@ class PlayerCode implements ModelInterface, ArrayAccess
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function __toString()
|
||||
{
|
||||
public function __toString() {
|
||||
if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
|
||||
return json_encode(
|
||||
ObjectSerializer::sanitizeForSerialization($this),
|
||||
|
Reference in New Issue
Block a user