@@ 372-388 (lines=17) @@ | ||
369 | * |
|
370 | * @return $this |
|
371 | */ |
|
372 | public function addQueryParameterError( |
|
373 | $name, |
|
374 | $title, |
|
375 | $detail = null, |
|
376 | $status = null, |
|
377 | $idx = null, |
|
378 | LinkInterface $aboutLink = null, |
|
379 | $code = null, |
|
380 | $meta = null |
|
381 | ) { |
|
382 | $source = [Error::SOURCE_PARAMETER => $name]; |
|
383 | $error = new Error($idx, $aboutLink, $status, $code, $title, $detail, $source, $meta); |
|
384 | ||
385 | $this->add($error); |
|
386 | ||
387 | return $this; |
|
388 | } |
|
389 | ||
390 | /** @noinspection PhpTooManyParametersInspection |
|
391 | * @param string $title |
|
@@ 402-418 (lines=17) @@ | ||
399 | * |
|
400 | * @return $this |
|
401 | */ |
|
402 | protected function addResourceError( |
|
403 | $title, |
|
404 | $pointer, |
|
405 | $detail = null, |
|
406 | $status = null, |
|
407 | $idx = null, |
|
408 | LinkInterface $aboutLink = null, |
|
409 | $code = null, |
|
410 | $meta = null |
|
411 | ) { |
|
412 | $source = [Error::SOURCE_POINTER => $pointer]; |
|
413 | $error = new Error($idx, $aboutLink, $status, $code, $title, $detail, $source, $meta); |
|
414 | ||
415 | $this->add($error); |
|
416 | ||
417 | return $this; |
|
418 | } |
|
419 | ||
420 | /** |
|
421 | * @return string |