mirror of
https://github.com/retailcrm/mailgun-php.git
synced 2025-02-06 08:19:25 +03:00
Make all model constructors private (#512)
This commit is contained in:
parent
e32031f671
commit
7020c01cca
@ -126,7 +126,7 @@ final class Event
|
||||
* @param string $id
|
||||
* @param float $timestamp
|
||||
*/
|
||||
public function __construct($event, $id, $timestamp)
|
||||
private function __construct($event, $id, $timestamp)
|
||||
{
|
||||
$this->event = $event;
|
||||
$this->id = $id;
|
||||
|
@ -29,7 +29,7 @@ final class EventResponse implements ApiResponse, PagingProvider
|
||||
* @param Event[] $items
|
||||
* @param array $paging
|
||||
*/
|
||||
public function __construct(array $items, array $paging)
|
||||
private function __construct(array $items, array $paging)
|
||||
{
|
||||
$this->items = $items;
|
||||
$this->paging = $paging;
|
||||
|
@ -29,7 +29,7 @@ final class IndexResponse implements ApiResponse, PagingProvider
|
||||
* @param Tag[] $items
|
||||
* @param array $paging
|
||||
*/
|
||||
public function __construct(array $items, array $paging)
|
||||
private function __construct(array $items, array $paging)
|
||||
{
|
||||
$this->items = $items;
|
||||
$this->paging = $paging;
|
||||
|
@ -37,7 +37,7 @@ final class Tag
|
||||
* @param \DateTime $firstSeen
|
||||
* @param \DateTime $lastSeen
|
||||
*/
|
||||
public function __construct($tag, $description, \DateTime $firstSeen = null, \DateTime $lastSeen = null)
|
||||
private function __construct($tag, $description, \DateTime $firstSeen = null, \DateTime $lastSeen = null)
|
||||
{
|
||||
$this->tag = $tag;
|
||||
$this->description = $description;
|
||||
|
@ -32,7 +32,7 @@ abstract class BaseResponse implements ApiResponse
|
||||
* @param array $webhook
|
||||
* @param string $message
|
||||
*/
|
||||
public function __construct(array $webhook, $message)
|
||||
private function __construct(array $webhook, $message)
|
||||
{
|
||||
$this->webhook = $webhook;
|
||||
$this->message = $message;
|
||||
|
@ -24,7 +24,7 @@ class ShowResponse implements ApiResponse
|
||||
/**
|
||||
* @param array $webhook
|
||||
*/
|
||||
public function __construct(array $webhook)
|
||||
private function __construct(array $webhook)
|
||||
{
|
||||
$this->webhook = $webhook;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user