fork download
  1. <?php
  2.  
  3. namespace JsonApi;
  4.  
  5. class ErrorObject
  6. {
  7. public function __construct(
  8. $status = false
  9. , $code = false
  10. , $title = 'Unknown error'
  11. , $detail = false
  12. , $source = false
  13. , $meta = false
  14. , $id = false
  15. , $links = false
  16. ) {
  17. $id ? $this->id = (string)$id : false;
  18. $links ? $this->links = $links : false;
  19. $status ? $this->status = (string)$status : false;
  20. $code ? $this->code = (string)$code : false;
  21. $title ? $this->title = $title : false;
  22. $detail ? $this->detail = $detail : false;
  23. $source ? $this->source = $source : false;
  24. $meta ? $this->meta = $meta : false;
  25. }
  26. }
  27.  
Success #stdin #stdout 0.01s 52488KB
stdin
Standard input is empty
stdout
Standard output is empty