@@ -162,7 +162,7 @@ public function hasCycle()
162162 */
163163 public function isLoop ()
164164 {
165- return (count ($ this ->walk ->getEdges ()) === 1 && $ this ->isCycle ());
165+ return (\ count ($ this ->walk ->getEdges ()) === 1 && $ this ->isCycle ());
166166 }
167167
168168 /**
@@ -214,11 +214,11 @@ public function hasLoop()
214214 public function isDigon ()
215215 {
216216 // exactly 2 edges
217- return (count ($ this ->walk ->getEdges ()) === 2 &&
217+ return (\ count ($ this ->walk ->getEdges ()) === 2 &&
218218 // no duplicate edges
219219 !$ this ->hasArrayDuplicates ($ this ->walk ->getEdges ()->getVector ()) &&
220220 // exactly two distinct vertices
221- count ($ this ->walk ->getVertices ()->getVerticesDistinct ()) === 2 &&
221+ \ count ($ this ->walk ->getVertices ()->getVerticesDistinct ()) === 2 &&
222222 // this is actually a cycle
223223 $ this ->isCycle ());
224224 }
@@ -238,9 +238,9 @@ public function isDigon()
238238 public function isTriangle ()
239239 {
240240 // exactly 3 (implicitly distinct) edges
241- return (count ($ this ->walk ->getEdges ()) === 3 &&
241+ return (\ count ($ this ->walk ->getEdges ()) === 3 &&
242242 // exactly three distinct vertices
243- count ($ this ->walk ->getVertices ()->getVerticesDistinct ()) === 3 &&
243+ \ count ($ this ->walk ->getVertices ()->getVerticesDistinct ()) === 3 &&
244244 // this is actually a cycle
245245 $ this ->isCycle ());
246246 }
@@ -347,7 +347,7 @@ private function hasArrayDuplicates($array)
347347 $ compare = array ();
348348 foreach ($ array as $ element ) {
349349 // duplicate element found
350- if (in_array ($ element , $ compare , true )) {
350+ if (\ in_array ($ element , $ compare , true )) {
351351 return true ;
352352 } else {
353353 // add element to temporary array to check for duplicates
@@ -368,7 +368,7 @@ private function hasArrayDuplicates($array)
368368 private function isArrayContentsEqual ($ a , $ b )
369369 {
370370 foreach ($ b as $ one ) {
371- $ pos = array_search ($ one , $ a , true );
371+ $ pos = \ array_search ($ one , $ a , true );
372372 if ($ pos === false ) {
373373 return false ;
374374 } else {
0 commit comments