ParcelService::potentialAction()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 4
Ratio 100 %

Importance

Changes 0
Metric Value
dl 4
loc 4
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
1
<?php
2
3
namespace Spatie\SchemaOrg;
4
5
use \Spatie\SchemaOrg\Contracts\ParcelServiceContract;
6
use \Spatie\SchemaOrg\Contracts\DeliveryMethodContract;
7
use \Spatie\SchemaOrg\Contracts\EnumerationContract;
8
use \Spatie\SchemaOrg\Contracts\IntangibleContract;
9
use \Spatie\SchemaOrg\Contracts\ThingContract;
10
11
/**
12
 * A private parcel service as the delivery mode available for a certain offer.
13
 * 
14
 * Commonly used values:
15
 * 
16
 * * http://purl.org/goodrelations/v1#DHL
17
 * * http://purl.org/goodrelations/v1#FederalExpress
18
 * * http://purl.org/goodrelations/v1#UPS
19
 *
20
 * @see http://schema.org/ParcelService
21
 *
22
 */
23 View Code Duplication
class ParcelService extends BaseType implements ParcelServiceContract, DeliveryMethodContract, EnumerationContract, IntangibleContract, ThingContract
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
24
{
25
    /**
26
     * An additional type for the item, typically used for adding more specific
27
     * types from external vocabularies in microdata syntax. This is a
28
     * relationship between something and a class that the thing is in. In RDFa
29
     * syntax, it is better to use the native RDFa syntax - the 'typeof'
30
     * attribute - for multiple types. Schema.org tools may have only weaker
31
     * understanding of extra types, in particular those defined externally.
32
     *
33
     * @param string|string[] $additionalType
34
     *
35
     * @return static
36
     *
37
     * @see http://schema.org/additionalType
38
     */
39
    public function additionalType($additionalType)
40
    {
41
        return $this->setProperty('additionalType', $additionalType);
42
    }
43
44
    /**
45
     * An alias for the item.
46
     *
47
     * @param string|string[] $alternateName
48
     *
49
     * @return static
50
     *
51
     * @see http://schema.org/alternateName
52
     */
53
    public function alternateName($alternateName)
54
    {
55
        return $this->setProperty('alternateName', $alternateName);
56
    }
57
58
    /**
59
     * A description of the item.
60
     *
61
     * @param string|string[] $description
62
     *
63
     * @return static
64
     *
65
     * @see http://schema.org/description
66
     */
67
    public function description($description)
68
    {
69
        return $this->setProperty('description', $description);
70
    }
71
72
    /**
73
     * A sub property of description. A short description of the item used to
74
     * disambiguate from other, similar items. Information from other properties
75
     * (in particular, name) may be necessary for the description to be useful
76
     * for disambiguation.
77
     *
78
     * @param string|string[] $disambiguatingDescription
79
     *
80
     * @return static
81
     *
82
     * @see http://schema.org/disambiguatingDescription
83
     */
84
    public function disambiguatingDescription($disambiguatingDescription)
85
    {
86
        return $this->setProperty('disambiguatingDescription', $disambiguatingDescription);
87
    }
88
89
    /**
90
     * The identifier property represents any kind of identifier for any kind of
91
     * [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides
92
     * dedicated properties for representing many of these, either as textual
93
     * strings or as URL (URI) links. See [background
94
     * notes](/docs/datamodel.html#identifierBg) for more details.
95
     *
96
     * @param \Spatie\SchemaOrg\Contracts\PropertyValueContract|\Spatie\SchemaOrg\Contracts\PropertyValueContract[]|string|string[] $identifier
97
     *
98
     * @return static
99
     *
100
     * @see http://schema.org/identifier
101
     */
102
    public function identifier($identifier)
103
    {
104
        return $this->setProperty('identifier', $identifier);
105
    }
106
107
    /**
108
     * An image of the item. This can be a [[URL]] or a fully described
109
     * [[ImageObject]].
110
     *
111
     * @param \Spatie\SchemaOrg\Contracts\ImageObjectContract|\Spatie\SchemaOrg\Contracts\ImageObjectContract[]|string|string[] $image
112
     *
113
     * @return static
114
     *
115
     * @see http://schema.org/image
116
     */
117
    public function image($image)
118
    {
119
        return $this->setProperty('image', $image);
120
    }
121
122
    /**
123
     * Indicates a page (or other CreativeWork) for which this thing is the main
124
     * entity being described. See [background
125
     * notes](/docs/datamodel.html#mainEntityBackground) for details.
126
     *
127
     * @param \Spatie\SchemaOrg\Contracts\CreativeWorkContract|\Spatie\SchemaOrg\Contracts\CreativeWorkContract[]|string|string[] $mainEntityOfPage
128
     *
129
     * @return static
130
     *
131
     * @see http://schema.org/mainEntityOfPage
132
     */
133
    public function mainEntityOfPage($mainEntityOfPage)
134
    {
135
        return $this->setProperty('mainEntityOfPage', $mainEntityOfPage);
136
    }
137
138
    /**
139
     * The name of the item.
140
     *
141
     * @param string|string[] $name
142
     *
143
     * @return static
144
     *
145
     * @see http://schema.org/name
146
     */
147
    public function name($name)
148
    {
149
        return $this->setProperty('name', $name);
150
    }
151
152
    /**
153
     * Indicates a potential Action, which describes an idealized action in
154
     * which this thing would play an 'object' role.
155
     *
156
     * @param \Spatie\SchemaOrg\Contracts\ActionContract|\Spatie\SchemaOrg\Contracts\ActionContract[] $potentialAction
157
     *
158
     * @return static
159
     *
160
     * @see http://schema.org/potentialAction
161
     */
162
    public function potentialAction($potentialAction)
163
    {
164
        return $this->setProperty('potentialAction', $potentialAction);
165
    }
166
167
    /**
168
     * URL of a reference Web page that unambiguously indicates the item's
169
     * identity. E.g. the URL of the item's Wikipedia page, Wikidata entry, or
170
     * official website.
171
     *
172
     * @param string|string[] $sameAs
173
     *
174
     * @return static
175
     *
176
     * @see http://schema.org/sameAs
177
     */
178
    public function sameAs($sameAs)
179
    {
180
        return $this->setProperty('sameAs', $sameAs);
181
    }
182
183
    /**
184
     * A CreativeWork or Event about this Thing.
185
     *
186
     * @param \Spatie\SchemaOrg\Contracts\CreativeWorkContract|\Spatie\SchemaOrg\Contracts\CreativeWorkContract[]|\Spatie\SchemaOrg\Contracts\EventContract|\Spatie\SchemaOrg\Contracts\EventContract[] $subjectOf
187
     *
188
     * @return static
189
     *
190
     * @see http://schema.org/subjectOf
191
     */
192
    public function subjectOf($subjectOf)
193
    {
194
        return $this->setProperty('subjectOf', $subjectOf);
195
    }
196
197
    /**
198
     * URL of the item.
199
     *
200
     * @param string|string[] $url
201
     *
202
     * @return static
203
     *
204
     * @see http://schema.org/url
205
     */
206
    public function url($url)
207
    {
208
        return $this->setProperty('url', $url);
209
    }
210
211
}
212