Completed
Push — master ( 3d2d99...6ac670 )
by Luke
02:45 queued 01:29
created

src/Methods/ListingMethod.php (1 issue)

Labels
Severity
1
<?php
2
3
namespace ZpgRtf\Methods;
4
5
use ZpgRtf\Objects\BranchObject;
6
use ZpgRtf\Objects\ListingObject;
7
8
/**
9
 * The listing method allows you to list, update or delete listings on the ZPG rtf.
10
 */
11
class ListingMethod extends AbstractMethod
12
{
13
    /** @var string */
14
    const UPDATE_SCHEMA = 'http://realtime-listings.webservices.zpg.co.uk/docs/v1.2/schemas/listing/update.json';
15
16
    /** @var string */
17
    const LIST_SCHEMA = 'http://realtime-listings.webservices.zpg.co.uk/docs/v1.2/schemas/listing/list.json';
18
19
    /** @var string */
20
    const DELETE_SCHEMA = 'http://realtime-listings.webservices.zpg.co.uk/docs/v1.2/schemas/listing/delete.json';
21
22
    /**
23
     * @return \GuzzleHttp\Psr7\Response
24
     */
25
    public function getList(BranchObject $branchObject)
26
    {
27
        return $this->validateAndSend(self::LIST_SCHEMA, 'listing/list', $branchObject);
28
    }
29
30
    /**
31
     * @return \GuzzleHttp\Psr7\Response
32
     */
33
    public function sendUpdate(ListingObject $listingObject)
34
    {
35
        return $this->validateAndSend(self::UPDATE_SCHEMA, 'listing/update', $listingObject);
36
    }
37
38
    /**
39
     * @return \GuzzleHttp\Psr7\Response
40
     */
41
    public function sendDelete(ListingDeleteObject $listingDeleteObject)
0 ignored issues
show
The type ZpgRtf\Methods\ListingDeleteObject was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
42
    {
43
        return $this->validateAndSend(self::DELETE_SCHEMA, 'listing/delete', $listingDeleteObject);
44
    }
45
}
46