AbstractCart::clear()
last analyzed

Size

Total Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 1
nc 1
1
<?php
2
3
namespace App\Http\Cart;
4
5
/**
6
 * Abstract class to store datas in sessions
7
 * Class AbstractCart.
8
 */
9
abstract class AbstractCart
10
{
11
    /**
12
     * @param ItemInterface $item
13
     */
14
    abstract public function add(ItemInterface $item);
15
16
    /**
17
     * @param ItemInterface $item
18
     */
19
    abstract public function remove(ItemInterface $item);
20
21
    /**
22
     * @return array
23
     */
24
    abstract public function clear();
25
26
    /**
27
     * @return array
28
     */
29
    abstract public function all();
30
31
    /**
32
     * @return \ArrayIterator
33
     */
34
    abstract public function count();
35
36
    /**
37
     * @param array $total
0 ignored issues
show
Bug introduced by
There is no parameter named $total. Was it maybe removed?

This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.

Consider the following example. The parameter $italy is not defined by the method finale(...).

/**
 * @param array $germany
 * @param array $island
 * @param array $italy
 */
function finale($germany, $island) {
    return "2:1";
}

The most likely cause is that the parameter was removed, but the annotation was not.

Loading history...
38
     */
39
    abstract public function emptycart();
40
}
41