File tree Expand file tree Collapse file tree 7 files changed +21
-19
lines changed Expand file tree Collapse file tree 7 files changed +21
-19
lines changed Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ class Article extends Api
1414
1515 /**
1616 * @see Swader\Diffbot\Entity\Article::getSentiment()
17- * @param $bool
17+ * @param bool|mixed $bool
1818 * @return $this
1919 */
2020 public function setSentiment ($ bool )
Original file line number Diff line number Diff line change @@ -137,7 +137,7 @@ public function setUrlCrawlPatterns(array $pattern = null)
137137 * The use of a urlCrawlRegEx will allow Crawlbot to spider outside of the
138138 * seed domain; it will follow all matching URLs regardless of domain.
139139 *
140- * @param $regex
140+ * @param string $regex
141141 * @return $this
142142 */
143143 public function setUrlCrawlRegEx ($ regex )
@@ -172,7 +172,7 @@ public function setUrlProcessPatterns(array $pattern = null)
172172 * Specify a regular expression to limit pages processed to those URLs that
173173 * match your expression. This will override any urlProcessPattern value.
174174 *
175- * @param $regex
175+ * @param string $regex
176176 * @return $this
177177 */
178178 public function setUrlProcessRegEx ($ regex )
@@ -262,7 +262,7 @@ public function setMaxToProcess($input = 100000)
262262 * X-Crawl-Status in the headers, and the full JSON response in the
263263 * POST body.
264264 *
265- * @param $string
265+ * @param string $string
266266 * @return $this
267267 * @throws InvalidArgumentException
268268 */
@@ -309,11 +309,12 @@ public function setCrawlDelay($input = 0.25)
309309 *
310310 * @param int|float $input
311311 * @return $this
312+ * @throws \InvalidArgumentException
312313 */
313314 public function setRepeat ($ input )
314315 {
315316 if (!is_numeric ($ input ) || !$ input ) {
316- throw new InvalidArgumentException ('Only positive numbers allowed. ' );
317+ throw new \ InvalidArgumentException ('Only positive numbers allowed. ' );
317318 }
318319 $ this ->otherOptions ['repeat ' ] = (float )$ input ;
319320
Original file line number Diff line number Diff line change @@ -32,7 +32,7 @@ public function setMaxPages($max = 1)
3232
3333 /**
3434 * @see Swader\Diffbot\Entity\Discussion::getSentiment()
35- * @param $bool
35+ * @param bool|mixed $bool
3636 * @return $this
3737 */
3838 public function setSentiment ($ bool )
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ class Image extends Api
1515 /**
1616 * Tells the API call to return the mentions field
1717 * @see https://www.diffbot.com/dev/docs/image/
18- * @param $bool
18+ * @param bool|mixed $bool
1919 * @return $this
2020 */
2121 public function setMentions ($ bool )
@@ -27,7 +27,7 @@ public function setMentions($bool)
2727 /**
2828 * Sets the API call to return the faces field
2929 * @see https://www.diffbot.com/dev/docs/image/
30- * @param $bool
30+ * @param bool|mixed $bool
3131 * @return $this
3232 */
3333 public function setFaces ($ bool )
@@ -39,7 +39,7 @@ public function setFaces($bool)
3939 /**
4040 * Sets the API call to return the ocr field.
4141 * @see https://www.diffbot.com/dev/docs/image/
42- * @param $bool
42+ * @param bool|mixed $bool
4343 * @return $this
4444 */
4545 public function setOcr ($ bool )
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ public function setDiscussion($bool = true)
2727
2828 /**
2929 * @see Swader\Diffbot\Entity\Product::getColors()
30- * @param $bool
30+ * @param bool|mixed $bool
3131 * @return $this
3232 */
3333 public function setColors ($ bool )
@@ -39,7 +39,7 @@ public function setColors($bool)
3939
4040 /**
4141 * @see Swader\Diffbot\Entity\Product::getSize()
42- * @param $bool
42+ * @param bool|mixed $bool
4343 * @return $this
4444 */
4545 public function setSize ($ bool )
@@ -51,7 +51,7 @@ public function setSize($bool)
5151
5252 /**
5353 * @see Swader\Diffbot\Entity\Product::isAvailable()
54- * @param $bool
54+ * @param bool|mixed $bool
5555 * @return $this
5656 */
5757 public function setAvailability ($ bool )
Original file line number Diff line number Diff line change 55use Swader \Diffbot \Abstracts \Api ;
66use Swader \Diffbot \Entity \SearchInfo ;
77use Swader \Diffbot \Traits \DiffbotAware ;
8+ use Swader \Diffbot \Entity \EntityIterator ;
89
910/**
1011 * Class Search
@@ -32,7 +33,7 @@ class Search extends Api
3233 /**
3334 * Search query.
3435 * @see https://www.diffbot.com/dev/docs/search/#query
35- * @param string $q
36+ * @param string string $q
3637 */
3738 public function __construct ($ q )
3839 {
@@ -129,7 +130,7 @@ public function buildUrl()
129130 *
130131 * @todo: remove error avoidance when issue 12 is fixed: https://github.com/Swader/diffbot-php-client/issues/12
131132 * @param bool $info
132- * @return \Swader\Diffbot\Entity\ EntityIterator|SearchInfo
133+ * @return EntityIterator|SearchInfo
133134 */
134135 public function call ($ info = false )
135136 {
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ trait StandardApi {
1111
1212 /**
1313 * Makes the API call return the links field, common to all standard API types
14- * @param $bool
14+ * @param bool|mixed $bool
1515 * @return $this
1616 */
1717 public function setLinks ($ bool )
@@ -22,7 +22,7 @@ public function setLinks($bool)
2222
2323 /**
2424 * Makes the API call return the meta field, common to all standard API types
25- * @param $bool
25+ * @param bool|mixed $bool
2626 * @return $this
2727 */
2828 public function setMeta ($ bool )
@@ -33,7 +33,7 @@ public function setMeta($bool)
3333
3434 /**
3535 * Makes the API call return the querystring field, common to all standard API types
36- * @param $bool
36+ * @param bool|mixed $bool
3737 * @return $this
3838 */
3939 public function setQuerystring ($ bool )
@@ -44,12 +44,12 @@ public function setQuerystring($bool)
4444
4545 /**
4646 * Makes the API call return the breadcrumb field, common to all standard API types
47- * @param $bool
47+ * @param bool|mixed $bool
4848 * @return $this
4949 */
5050 public function setBreadcrumb ($ bool )
5151 {
5252 $ this ->fieldSettings ['breadcrumb ' ] = (bool )$ bool ;
5353 return $ this ;
5454 }
55- }
55+ }
You can’t perform that action at this time.
0 commit comments