forked from loafle/openapi-generator-original
update sample code, update test case
This commit is contained in:
@@ -51,12 +51,12 @@ class InlineResponse200 implements ArrayAccess
|
||||
* @var string[]
|
||||
*/
|
||||
static $swaggerTypes = array(
|
||||
'photo_urls' => 'string[]',
|
||||
'name' => 'string',
|
||||
'tags' => '\Swagger\Client\Model\Tag[]',
|
||||
'id' => 'int',
|
||||
'category' => 'object',
|
||||
'tags' => '\Swagger\Client\Model\Tag[]',
|
||||
'status' => 'string'
|
||||
'status' => 'string',
|
||||
'name' => 'string',
|
||||
'photo_urls' => 'string[]'
|
||||
);
|
||||
|
||||
static function swaggerTypes() {
|
||||
@@ -68,12 +68,12 @@ class InlineResponse200 implements ArrayAccess
|
||||
* @var string[]
|
||||
*/
|
||||
static $attributeMap = array(
|
||||
'photo_urls' => 'photoUrls',
|
||||
'name' => 'name',
|
||||
'tags' => 'tags',
|
||||
'id' => 'id',
|
||||
'category' => 'category',
|
||||
'tags' => 'tags',
|
||||
'status' => 'status'
|
||||
'status' => 'status',
|
||||
'name' => 'name',
|
||||
'photo_urls' => 'photoUrls'
|
||||
);
|
||||
|
||||
static function attributeMap() {
|
||||
@@ -85,12 +85,12 @@ class InlineResponse200 implements ArrayAccess
|
||||
* @var string[]
|
||||
*/
|
||||
static $setters = array(
|
||||
'photo_urls' => 'setPhotoUrls',
|
||||
'name' => 'setName',
|
||||
'tags' => 'setTags',
|
||||
'id' => 'setId',
|
||||
'category' => 'setCategory',
|
||||
'tags' => 'setTags',
|
||||
'status' => 'setStatus'
|
||||
'status' => 'setStatus',
|
||||
'name' => 'setName',
|
||||
'photo_urls' => 'setPhotoUrls'
|
||||
);
|
||||
|
||||
static function setters() {
|
||||
@@ -102,12 +102,12 @@ class InlineResponse200 implements ArrayAccess
|
||||
* @var string[]
|
||||
*/
|
||||
static $getters = array(
|
||||
'photo_urls' => 'getPhotoUrls',
|
||||
'name' => 'getName',
|
||||
'tags' => 'getTags',
|
||||
'id' => 'getId',
|
||||
'category' => 'getCategory',
|
||||
'tags' => 'getTags',
|
||||
'status' => 'getStatus'
|
||||
'status' => 'getStatus',
|
||||
'name' => 'getName',
|
||||
'photo_urls' => 'getPhotoUrls'
|
||||
);
|
||||
|
||||
static function getters() {
|
||||
@@ -116,16 +116,10 @@ class InlineResponse200 implements ArrayAccess
|
||||
|
||||
|
||||
/**
|
||||
* $photo_urls
|
||||
* @var string[]
|
||||
* $tags
|
||||
* @var \Swagger\Client\Model\Tag[]
|
||||
*/
|
||||
protected $photo_urls;
|
||||
|
||||
/**
|
||||
* $name
|
||||
* @var string
|
||||
*/
|
||||
protected $name;
|
||||
protected $tags;
|
||||
|
||||
/**
|
||||
* $id
|
||||
@@ -139,18 +133,24 @@ class InlineResponse200 implements ArrayAccess
|
||||
*/
|
||||
protected $category;
|
||||
|
||||
/**
|
||||
* $tags
|
||||
* @var \Swagger\Client\Model\Tag[]
|
||||
*/
|
||||
protected $tags;
|
||||
|
||||
/**
|
||||
* $status pet status in the store
|
||||
* @var string
|
||||
*/
|
||||
protected $status;
|
||||
|
||||
/**
|
||||
* $name
|
||||
* @var string
|
||||
*/
|
||||
protected $name;
|
||||
|
||||
/**
|
||||
* $photo_urls
|
||||
* @var string[]
|
||||
*/
|
||||
protected $photo_urls;
|
||||
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
@@ -159,54 +159,33 @@ class InlineResponse200 implements ArrayAccess
|
||||
public function __construct(array $data = null)
|
||||
{
|
||||
if ($data != null) {
|
||||
$this->photo_urls = $data["photo_urls"];
|
||||
$this->name = $data["name"];
|
||||
$this->tags = $data["tags"];
|
||||
$this->id = $data["id"];
|
||||
$this->category = $data["category"];
|
||||
$this->tags = $data["tags"];
|
||||
$this->status = $data["status"];
|
||||
$this->name = $data["name"];
|
||||
$this->photo_urls = $data["photo_urls"];
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets photo_urls
|
||||
* @return string[]
|
||||
* Gets tags
|
||||
* @return \Swagger\Client\Model\Tag[]
|
||||
*/
|
||||
public function getPhotoUrls()
|
||||
public function getTags()
|
||||
{
|
||||
return $this->photo_urls;
|
||||
return $this->tags;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets photo_urls
|
||||
* @param string[] $photo_urls
|
||||
* Sets tags
|
||||
* @param \Swagger\Client\Model\Tag[] $tags
|
||||
* @return $this
|
||||
*/
|
||||
public function setPhotoUrls($photo_urls)
|
||||
public function setTags($tags)
|
||||
{
|
||||
|
||||
$this->photo_urls = $photo_urls;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets name
|
||||
* @return string
|
||||
*/
|
||||
public function getName()
|
||||
{
|
||||
return $this->name;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets name
|
||||
* @param string $name
|
||||
* @return $this
|
||||
*/
|
||||
public function setName($name)
|
||||
{
|
||||
|
||||
$this->name = $name;
|
||||
$this->tags = $tags;
|
||||
return $this;
|
||||
}
|
||||
|
||||
@@ -252,27 +231,6 @@ class InlineResponse200 implements ArrayAccess
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets tags
|
||||
* @return \Swagger\Client\Model\Tag[]
|
||||
*/
|
||||
public function getTags()
|
||||
{
|
||||
return $this->tags;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets tags
|
||||
* @param \Swagger\Client\Model\Tag[] $tags
|
||||
* @return $this
|
||||
*/
|
||||
public function setTags($tags)
|
||||
{
|
||||
|
||||
$this->tags = $tags;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets status
|
||||
* @return string
|
||||
@@ -297,6 +255,48 @@ class InlineResponse200 implements ArrayAccess
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets name
|
||||
* @return string
|
||||
*/
|
||||
public function getName()
|
||||
{
|
||||
return $this->name;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets name
|
||||
* @param string $name
|
||||
* @return $this
|
||||
*/
|
||||
public function setName($name)
|
||||
{
|
||||
|
||||
$this->name = $name;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets photo_urls
|
||||
* @return string[]
|
||||
*/
|
||||
public function getPhotoUrls()
|
||||
{
|
||||
return $this->photo_urls;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets photo_urls
|
||||
* @param string[] $photo_urls
|
||||
* @return $this
|
||||
*/
|
||||
public function setPhotoUrls($photo_urls)
|
||||
{
|
||||
|
||||
$this->photo_urls = $photo_urls;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns true if offset exists. False otherwise.
|
||||
* @param integer $offset Offset
|
||||
|
||||
@@ -51,7 +51,8 @@ class Name implements ArrayAccess
|
||||
* @var string[]
|
||||
*/
|
||||
static $swaggerTypes = array(
|
||||
'name' => 'int'
|
||||
'name' => 'int',
|
||||
'snake_case' => 'int'
|
||||
);
|
||||
|
||||
static function swaggerTypes() {
|
||||
@@ -63,7 +64,8 @@ class Name implements ArrayAccess
|
||||
* @var string[]
|
||||
*/
|
||||
static $attributeMap = array(
|
||||
'name' => 'name'
|
||||
'name' => 'name',
|
||||
'snake_case' => 'snake_case'
|
||||
);
|
||||
|
||||
static function attributeMap() {
|
||||
@@ -75,7 +77,8 @@ class Name implements ArrayAccess
|
||||
* @var string[]
|
||||
*/
|
||||
static $setters = array(
|
||||
'name' => 'setName'
|
||||
'name' => 'setName',
|
||||
'snake_case' => 'setSnakeCase'
|
||||
);
|
||||
|
||||
static function setters() {
|
||||
@@ -87,7 +90,8 @@ class Name implements ArrayAccess
|
||||
* @var string[]
|
||||
*/
|
||||
static $getters = array(
|
||||
'name' => 'getName'
|
||||
'name' => 'getName',
|
||||
'snake_case' => 'getSnakeCase'
|
||||
);
|
||||
|
||||
static function getters() {
|
||||
@@ -101,6 +105,12 @@ class Name implements ArrayAccess
|
||||
*/
|
||||
protected $name;
|
||||
|
||||
/**
|
||||
* $snake_case
|
||||
* @var int
|
||||
*/
|
||||
protected $snake_case;
|
||||
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
@@ -110,6 +120,7 @@ class Name implements ArrayAccess
|
||||
{
|
||||
if ($data != null) {
|
||||
$this->name = $data["name"];
|
||||
$this->snake_case = $data["snake_case"];
|
||||
}
|
||||
}
|
||||
|
||||
@@ -134,6 +145,27 @@ class Name implements ArrayAccess
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets snake_case
|
||||
* @return int
|
||||
*/
|
||||
public function getSnakeCase()
|
||||
{
|
||||
return $this->snake_case;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets snake_case
|
||||
* @param int $snake_case
|
||||
* @return $this
|
||||
*/
|
||||
public function setSnakeCase($snake_case)
|
||||
{
|
||||
|
||||
$this->snake_case = $snake_case;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns true if offset exists. False otherwise.
|
||||
* @param integer $offset Offset
|
||||
|
||||
Reference in New Issue
Block a user