commercetools-sdk-php-v2
The commercetools platform, import-api and PHP sdks generated from our api reference.
Loading...
Searching...
No Matches
lib
commercetools-api
src
Models
Subscription
SnsDestinationModel.php
1
<?php
2
3
declare(strict_types=1);
9
namespace
Commercetools\Api\Models\Subscription
;
10
11
use
Commercetools\Base\DateTimeImmutableCollection
;
12
use
Commercetools\Base\JsonObject
;
13
use
Commercetools\Base\JsonObjectModel
;
14
use
Commercetools\Base\MapperFactory
;
15
use stdClass;
16
20
final
class
SnsDestinationModel
extends
JsonObjectModel
implements
SnsDestination
21
{
22
public
const
DISCRIMINATOR_VALUE
=
'SNS'
;
27
protected
$type
;
28
33
protected
$accessKey
;
34
39
protected
$accessSecret
;
40
45
protected
$topicArn
;
46
51
protected
$authenticationMode
;
52
53
57
public
function
__construct
(
58
?
string
$accessKey
=
null
,
59
?
string
$accessSecret
=
null
,
60
?
string
$topicArn
=
null
,
61
?
string
$authenticationMode
=
null
,
62
?
string
$type
=
null
63
) {
64
$this->accessKey =
$accessKey
;
65
$this->accessSecret =
$accessSecret
;
66
$this->topicArn =
$topicArn
;
67
$this->authenticationMode =
$authenticationMode
;
68
$this->type =
$type
??
self::DISCRIMINATOR_VALUE
;
69
}
70
75
public
function
getType
()
76
{
77
if
(is_null($this->type)) {
79
$data = $this->
raw
(self::FIELD_TYPE);
80
if
(is_null($data)) {
81
return
null
;
82
}
83
$this->type = (string) $data;
84
}
85
86
return
$this->type
;
87
}
88
95
public
function
getAccessKey
()
96
{
97
if
(is_null($this->accessKey)) {
99
$data = $this->
raw
(self::FIELD_ACCESS_KEY);
100
if
(is_null($data)) {
101
return
null
;
102
}
103
$this->accessKey = (string) $data;
104
}
105
106
return
$this->accessKey
;
107
}
108
115
public
function
getAccessSecret
()
116
{
117
if
(is_null($this->accessSecret)) {
119
$data = $this->
raw
(self::FIELD_ACCESS_SECRET);
120
if
(is_null($data)) {
121
return
null
;
122
}
123
$this->accessSecret = (string) $data;
124
}
125
126
return
$this->accessSecret
;
127
}
128
135
public
function
getTopicArn
()
136
{
137
if
(is_null($this->topicArn)) {
139
$data = $this->
raw
(self::FIELD_TOPIC_ARN);
140
if
(is_null($data)) {
141
return
null
;
142
}
143
$this->topicArn = (string) $data;
144
}
145
146
return
$this->topicArn
;
147
}
148
155
public
function
getAuthenticationMode
()
156
{
157
if
(is_null($this->authenticationMode)) {
159
$data = $this->
raw
(self::FIELD_AUTHENTICATION_MODE);
160
if
(is_null($data)) {
161
return
null
;
162
}
163
$this->authenticationMode = (string) $data;
164
}
165
166
return
$this->authenticationMode
;
167
}
168
169
173
public
function
setAccessKey
(?
string
$accessKey
): void
174
{
175
$this->accessKey =
$accessKey
;
176
}
177
181
public
function
setAccessSecret
(?
string
$accessSecret
): void
182
{
183
$this->accessSecret =
$accessSecret
;
184
}
185
189
public
function
setTopicArn
(?
string
$topicArn
): void
190
{
191
$this->topicArn =
$topicArn
;
192
}
193
197
public
function
setAuthenticationMode
(?
string
$authenticationMode
): void
198
{
199
$this->authenticationMode =
$authenticationMode
;
200
}
201
}
Commercetools\Api\Models\Subscription\SnsDestinationModel
Definition
SnsDestinationModel.php:21
Commercetools\Api\Models\Subscription\SnsDestinationModel\setAccessKey
setAccessKey(?string $accessKey)
Definition
SnsDestinationModel.php:173
Commercetools\Api\Models\Subscription\SnsDestinationModel\getTopicArn
getTopicArn()
Definition
SnsDestinationModel.php:135
Commercetools\Api\Models\Subscription\SnsDestinationModel\getAccessSecret
getAccessSecret()
Definition
SnsDestinationModel.php:115
Commercetools\Api\Models\Subscription\SnsDestinationModel\getAccessKey
getAccessKey()
Definition
SnsDestinationModel.php:95
Commercetools\Api\Models\Subscription\SnsDestinationModel\setTopicArn
setTopicArn(?string $topicArn)
Definition
SnsDestinationModel.php:189
Commercetools\Api\Models\Subscription\SnsDestinationModel\$authenticationMode
$authenticationMode
Definition
SnsDestinationModel.php:51
Commercetools\Api\Models\Subscription\SnsDestinationModel\$accessKey
$accessKey
Definition
SnsDestinationModel.php:33
Commercetools\Api\Models\Subscription\SnsDestinationModel\$topicArn
$topicArn
Definition
SnsDestinationModel.php:45
Commercetools\Api\Models\Subscription\SnsDestinationModel\getType
getType()
Definition
SnsDestinationModel.php:75
Commercetools\Api\Models\Subscription\SnsDestinationModel\getAuthenticationMode
getAuthenticationMode()
Definition
SnsDestinationModel.php:155
Commercetools\Api\Models\Subscription\SnsDestinationModel\$accessSecret
$accessSecret
Definition
SnsDestinationModel.php:39
Commercetools\Api\Models\Subscription\SnsDestinationModel\__construct
__construct(?string $accessKey=null, ?string $accessSecret=null, ?string $topicArn=null, ?string $authenticationMode=null, ?string $type=null)
Definition
SnsDestinationModel.php:57
Commercetools\Api\Models\Subscription\SnsDestinationModel\DISCRIMINATOR_VALUE
const DISCRIMINATOR_VALUE
Definition
SnsDestinationModel.php:22
Commercetools\Api\Models\Subscription\SnsDestinationModel\$type
$type
Definition
SnsDestinationModel.php:27
Commercetools\Api\Models\Subscription\SnsDestinationModel\setAuthenticationMode
setAuthenticationMode(?string $authenticationMode)
Definition
SnsDestinationModel.php:197
Commercetools\Api\Models\Subscription\SnsDestinationModel\setAccessSecret
setAccessSecret(?string $accessSecret)
Definition
SnsDestinationModel.php:181
Commercetools\Base\BaseJsonObject\raw
raw(string $field)
Definition
BaseJsonObject.php:57
Commercetools\Base\DateTimeImmutableCollection
Definition
DateTimeImmutableCollection.php:21
Commercetools\Base\JsonObjectModel
Definition
JsonObjectModel.php:15
Commercetools\Base\MapperFactory
Definition
MapperFactory.php:16
Commercetools\Api\Models\Subscription\SnsDestination
Definition
SnsDestination.php:15
Commercetools\Base\JsonObject
Definition
JsonObject.php:15
Commercetools\Api\Models\Subscription
Definition
AzureEventGridDestination.php:9
Generated by
1.9.8