TimeframeService

class Firstred\PostNL\Service\TimeframeService
Parent:

Firstred\PostNL\Service\AbstractCacheableService

Implements:

Firstred\PostNL\Service\TimeframeServiceInterface

Used traits:

Firstred\PostNL\Service\ResponseProcessor\ResponseProcessorSettersTrait

Summary

Methods

Properties

protected static property Firstred\PostNL\Service\TimeframeService::$requestBuilder
protected static property Firstred\PostNL\Service\TimeframeService::$responseProcessor

Methods

public Firstred\PostNL\Service\TimeframeService::__construct($apiKey, $sandbox, $httpClient, $requestFactory, $streamFactory, $cache=null, \\DateInterval|\\DateTimeInterface|int $ttl=null)
Parameters:
  • $apiKey (ParagonIE\HiddenString\HiddenString)

  • $sandbox (bool)

  • $httpClient (Firstred\PostNL\HttpClient\HttpClientInterface)

  • $requestFactory (Psr\Http\Message\RequestFactoryInterface)

  • $streamFactory (Psr\Http\Message\StreamFactoryInterface)

  • $cache (Psr\Cache\CacheItemPoolInterface | null)

  • $ttl (DateInterval | \DateTimeInterface | int | null)

public Firstred\PostNL\Service\TimeframeService::getTimeframes($getTimeframes)
Get timeframes via REST.
Parameters:
Returns:

\Firstred\PostNL\Entity\Response\ResponseTimeframes

Throws:

\Firstred\PostNL\Exception\HttpClientException

Throws:

\Firstred\PostNL\Exception\NotSupportedException

Throws:

\Firstred\PostNL\Exception\InvalidArgumentException

Throws:

\Psr\Cache\InvalidArgumentException

Throws:

\Firstred\PostNL\Exception\ResponseException

Throws:

\Firstred\PostNL\Exception\CifDownException

Throws:

\Firstred\PostNL\Exception\CifException

Throws:

\Firstred\PostNL\Exception\DeserializationException

Throws:

\Firstred\PostNL\Exception\InvalidConfigurationException

Throws:

\Firstred\PostNL\Exception\HttpClientException

Throws:

\Firstred\PostNL\Exception\NotSupportedException

Throws:

\Firstred\PostNL\Exception\InvalidArgumentException

Throws:

\Psr\Cache\InvalidArgumentException

Throws:

\Firstred\PostNL\Exception\ResponseException

Throws:

\Firstred\PostNL\Exception\CifDownException

Throws:

\Firstred\PostNL\Exception\CifException

Throws:

\Firstred\PostNL\Exception\DeserializationException

Throws:

\Firstred\PostNL\Exception\InvalidConfigurationException

Throws:

\Firstred\PostNL\Exception\HttpClientException

Throws:

\Firstred\PostNL\Exception\NotSupportedException

Throws:

\Firstred\PostNL\Exception\InvalidArgumentException

Throws:

\Psr\Cache\InvalidArgumentException

Throws:

\Firstred\PostNL\Exception\ResponseException

Throws:

\Firstred\PostNL\Exception\CifDownException

Throws:

\Firstred\PostNL\Exception\CifException

Throws:

\Firstred\PostNL\Exception\DeserializationException

Throws:

\Firstred\PostNL\Exception\InvalidConfigurationException

Throws:

\Firstred\PostNL\Exception\HttpClientException

Throws:

\Firstred\PostNL\Exception\NotSupportedException

Throws:

\Firstred\PostNL\Exception\InvalidArgumentException

Throws:

\Psr\Cache\InvalidArgumentException

Throws:

\Firstred\PostNL\Exception\ResponseException

Throws:

\Firstred\PostNL\Exception\CifDownException

Throws:

\Firstred\PostNL\Exception\CifException

Throws:

\Firstred\PostNL\Exception\DeserializationException

Throws:

\Firstred\PostNL\Exception\InvalidConfigurationException

Throws:

\Firstred\PostNL\Exception\HttpClientException

Throws:

\Firstred\PostNL\Exception\NotSupportedException

Throws:

\Firstred\PostNL\Exception\InvalidArgumentException

Throws:

\Psr\Cache\InvalidArgumentException

Throws:

\Firstred\PostNL\Exception\ResponseException

Throws:

\Firstred\PostNL\Exception\CifDownException

Throws:

\Firstred\PostNL\Exception\CifException

Throws:

\Firstred\PostNL\Exception\DeserializationException

Throws:

\Firstred\PostNL\Exception\InvalidConfigurationException

Throws:

\Firstred\PostNL\Exception\HttpClientException

Throws:

\Firstred\PostNL\Exception\NotSupportedException

Throws:

\Firstred\PostNL\Exception\InvalidArgumentException

Throws:

\Psr\Cache\InvalidArgumentException

Throws:

\Firstred\PostNL\Exception\ResponseException

Throws:

\Firstred\PostNL\Exception\CifDownException

Throws:

\Firstred\PostNL\Exception\CifException

Throws:

\Firstred\PostNL\Exception\DeserializationException

Throws:

\Firstred\PostNL\Exception\InvalidConfigurationException

Throws:

\Firstred\PostNL\Exception\HttpClientException

Throws:

\Firstred\PostNL\Exception\NotSupportedException

Throws:

\Firstred\PostNL\Exception\InvalidArgumentException

Throws:

\Psr\Cache\InvalidArgumentException

Throws:

\Firstred\PostNL\Exception\ResponseException

Throws:

\Firstred\PostNL\Exception\CifDownException

Throws:

\Firstred\PostNL\Exception\CifException

Throws:

\Firstred\PostNL\Exception\DeserializationException

Throws:

\Firstred\PostNL\Exception\InvalidConfigurationException

Throws:

\Firstred\PostNL\Exception\HttpClientException

Throws:

\Firstred\PostNL\Exception\NotSupportedException

Throws:

\Firstred\PostNL\Exception\InvalidArgumentException

Throws:

\Psr\Cache\InvalidArgumentException

Throws:

\Firstred\PostNL\Exception\ResponseException

Throws:

\Firstred\PostNL\Exception\CifDownException

Throws:

\Firstred\PostNL\Exception\CifException

Throws:

\Firstred\PostNL\Exception\DeserializationException

Throws:

\Firstred\PostNL\Exception\InvalidConfigurationException

Throws:

\Firstred\PostNL\Exception\HttpClientException

Throws:

\Firstred\PostNL\Exception\NotSupportedException

Throws:

\Firstred\PostNL\Exception\InvalidArgumentException

Throws:

\Psr\Cache\InvalidArgumentException

Throws:

\Firstred\PostNL\Exception\ResponseException

Throws:

\Firstred\PostNL\Exception\CifDownException

Throws:

\Firstred\PostNL\Exception\CifException

Throws:

\Firstred\PostNL\Exception\DeserializationException

Throws:

\Firstred\PostNL\Exception\InvalidConfigurationException

Since:

1.0.0

public Firstred\PostNL\Service\TimeframeService::setApiKey($apiKey)
Parameters:
  • $apiKey (ParagonIE\HiddenString\HiddenString)

Returns:

static

Since:

2.0.0

public Firstred\PostNL\Service\TimeframeService::setSandbox($sandbox)
Parameters:
  • $sandbox (bool)

Returns:

static

Since:

2.0.0

public Firstred\PostNL\Service\TimeframeService::setRequestFactory($requestFactory)
Parameters:
  • $requestFactory (Psr\Http\Message\RequestFactoryInterface)

Returns:

static

Since:

2.0.0

public Firstred\PostNL\Service\TimeframeService::setStreamFactory($streamFactory)
Parameters:
  • $streamFactory (Psr\Http\Message\StreamFactoryInterface)

Returns:

static

Since:

2.0.0