Commit Graph

24 Commits

Author SHA1 Message Date
Arne Jørgensen
65d677c385 Set discriminator property in constructor
When using inheritance let the constructor set the discriminator
property to the model name.

This avoids redundant and error prone stuff like:

```
  $animal = new \Swagger\Client\Model\Dog();
  $animal->setClassName('Dog');
```
2016-04-09 21:05:18 +02:00
wing328
02ac7d93c5 minor php code improvement 2016-04-09 17:59:28 +08:00
Arne Jørgensen
0196cdd558 [PHP] Use parent constructor when inheriting 2016-03-28 11:30:27 +02:00
Arne Jørgensen
64454a16e0 Add inheritance in the PHP client model 2016-03-18 00:48:49 +01:00
wing328
9fd4f39c8c update tostring to use sanitizeforserialization 2016-01-18 21:27:29 +08:00
Ron
3a2ad9e2e4 Happy new year! 2016-01-06 16:04:16 -08:00
wing328
4b656c516f add default value to php model 2015-12-08 15:59:46 +08:00
wing328
f154e407d2 update coding style based on CodeSniffer 2015-07-13 15:26:12 +08:00
wing328
71a22141bf add enum support for model property 2015-07-13 15:24:11 +08:00
wing328
259b31ccd4 temporary folder setting 2015-07-13 15:21:38 +08:00
wing328
fcd0b31d7d add file response for php 2015-07-13 15:09:09 +08:00
Tony Tam
07d5365c5c merged from #902, rebuilt client 2015-06-25 10:17:28 -07:00
Branden Cash
8ed690cad0 Better namespace support, so that your not limited to only having a single vendor space, you can have \Vendor\Package\Model as a namespace. Also updates with proper phpdoc comments so that IDE code hinting can function properly. 2015-06-18 11:41:14 -07:00
William Cheng
436db1f8e7 add __toString and update php sample 2015-06-17 19:00:29 +08:00
wing328
50ae9659ad rollback php template 2015-06-09 12:37:30 +08:00
Ron
1c2d0656b0 Code reformatting 2015-06-07 11:56:08 -04:00
Ron
96107193e9 updated reverb references 2015-06-07 11:18:49 -04:00
wing328
3811a5a209 resolve conflict during rebase 2015-04-06 18:03:15 +08:00
William Cheng
ab8d62214a add attributemap to php model, update php petstore sample 2015-03-19 20:58:22 +08:00
James Ebentier
24842d4a29 PHP Models: fixing an issue with commas being where they shouldn't 2015-03-13 10:53:42 -07:00
James Ebentier
0854ca5ce5 PHP Models: updating the models generated for PHP styling 2015-03-13 10:53:19 -07:00
James Ebentier
6ca34e362d PHP Models: updating the models generated for PHP to be array accessable and have a simple constructor 2015-03-13 10:51:45 -07:00
Tony Tam
da8176e170 updated templates 2015-02-15 22:19:26 -08:00
Tony Tam
6bb2e4ccb4 moved to modules per #411 2015-02-05 07:17:38 -08:00