commercetools-sdk-php-v2
The commercetools platform, import-api and PHP sdks generated from our api reference.
lib
commercetools-api
src
Models
Product
TermFacetResultBuilder.php
1
<?php
2
3
declare(strict_types=1);
9
namespace
Commercetools\Api\Models\Product
;
10
11
use
Commercetools\Base\Builder
;
12
use
Commercetools\Base\DateTimeImmutableCollection
;
13
use
Commercetools\Base\JsonObject
;
14
use
Commercetools\Base\JsonObjectModel
;
15
use
Commercetools\Base\MapperFactory
;
16
use stdClass;
17
21
final
class
TermFacetResultBuilder
implements
Builder
22
{
27
private
$dataType;
28
33
private
$missing;
34
39
private
$total;
40
45
private
$other;
46
51
private
$terms;
52
57
public
function
getDataType
()
58
{
59
return
$this->dataType;
60
}
61
66
public
function
getMissing
()
67
{
68
return
$this->missing;
69
}
70
75
public
function
getTotal
()
76
{
77
return
$this->total;
78
}
79
84
public
function
getOther
()
85
{
86
return
$this->other;
87
}
88
93
public
function
getTerms
()
94
{
95
return
$this->terms;
96
}
97
102
public
function
withDataType
(?
string
$dataType)
103
{
104
$this->dataType = $dataType;
105
106
return
$this;
107
}
108
113
public
function
withMissing
(?
int
$missing)
114
{
115
$this->missing = $missing;
116
117
return
$this;
118
}
119
124
public
function
withTotal
(?
int
$total)
125
{
126
$this->total = $total;
127
128
return
$this;
129
}
130
135
public
function
withOther
(?
int
$other)
136
{
137
$this->other = $other;
138
139
return
$this;
140
}
141
146
public
function
withTerms
(?
FacetTermCollection
$terms)
147
{
148
$this->terms = $terms;
149
150
return
$this;
151
}
152
153
154
public
function
build
():
TermFacetResult
155
{
156
return
new
TermFacetResultModel
(
157
$this->dataType,
158
$this->missing,
159
$this->total,
160
$this->other,
161
$this->terms
162
);
163
}
164
165
public
static
function
of
():
TermFacetResultBuilder
166
{
167
return
new
self
();
168
}
169
}
Commercetools\Api\Models\Product\FacetTermCollection
Definition:
FacetTermCollection.php:22
Commercetools\Api\Models\Product\TermFacetResultBuilder
Definition:
TermFacetResultBuilder.php:22
Commercetools\Api\Models\Product\TermFacetResultBuilder\withTerms
withTerms(?FacetTermCollection $terms)
Definition:
TermFacetResultBuilder.php:146
Commercetools\Api\Models\Product\TermFacetResultBuilder\withTotal
withTotal(?int $total)
Definition:
TermFacetResultBuilder.php:124
Commercetools\Api\Models\Product\TermFacetResultBuilder\build
build()
Definition:
TermFacetResultBuilder.php:154
Commercetools\Api\Models\Product\TermFacetResultBuilder\getTotal
getTotal()
Definition:
TermFacetResultBuilder.php:75
Commercetools\Api\Models\Product\TermFacetResultBuilder\of
static of()
Definition:
TermFacetResultBuilder.php:165
Commercetools\Api\Models\Product\TermFacetResultBuilder\getTerms
getTerms()
Definition:
TermFacetResultBuilder.php:93
Commercetools\Api\Models\Product\TermFacetResultBuilder\withMissing
withMissing(?int $missing)
Definition:
TermFacetResultBuilder.php:113
Commercetools\Api\Models\Product\TermFacetResultBuilder\getDataType
getDataType()
Definition:
TermFacetResultBuilder.php:57
Commercetools\Api\Models\Product\TermFacetResultBuilder\withDataType
withDataType(?string $dataType)
Definition:
TermFacetResultBuilder.php:102
Commercetools\Api\Models\Product\TermFacetResultBuilder\withOther
withOther(?int $other)
Definition:
TermFacetResultBuilder.php:135
Commercetools\Api\Models\Product\TermFacetResultBuilder\getMissing
getMissing()
Definition:
TermFacetResultBuilder.php:66
Commercetools\Api\Models\Product\TermFacetResultBuilder\getOther
getOther()
Definition:
TermFacetResultBuilder.php:84
Commercetools\Api\Models\Product\TermFacetResultModel
Definition:
TermFacetResultModel.php:21
Commercetools\Base\DateTimeImmutableCollection
Definition:
DateTimeImmutableCollection.php:21
Commercetools\Base\JsonObjectModel
Definition:
JsonObjectModel.php:15
Commercetools\Base\MapperFactory
Definition:
MapperFactory.php:16
Commercetools\Api\Models\Product\TermFacetResult
Definition:
TermFacetResult.php:15
Commercetools\Base\Builder
Definition:
Builder.php:16
Commercetools\Base\JsonObject
Definition:
JsonObject.php:15
Commercetools\Api\Models\Product
Definition:
AttributeAccessor.php:4
Generated by
1.9.1