1 | <?php |
||
21 | class Transifex |
||
22 | { |
||
23 | /** |
||
24 | * Options for the Transifex object. |
||
25 | * |
||
26 | * @var array |
||
27 | */ |
||
28 | protected $options; |
||
29 | |||
30 | /** |
||
31 | * The HTTP client object to use in sending HTTP requests. |
||
32 | * |
||
33 | * @var ClientInterface |
||
34 | */ |
||
35 | protected $client; |
||
36 | |||
37 | /** |
||
38 | * @param array $options Transifex options array. |
||
39 | * @param ClientInterface $client The HTTP client object. |
||
40 | */ |
||
41 | 1 | public function __construct(array $options = [], ClientInterface $client = null) |
|
52 | |||
53 | /** |
||
54 | * Factory method to fetch API objects. |
||
55 | * |
||
56 | * @param string $name Name of the API object to retrieve. |
||
57 | * |
||
58 | * @return TransifexObject |
||
59 | * |
||
60 | * @throws \InvalidArgumentException |
||
61 | */ |
||
62 | 5 | public function get(string $name) : TransifexObject |
|
83 | |||
84 | /** |
||
85 | * Get an option from the Transifex instance. |
||
86 | * |
||
87 | * @param string $key The name of the option to get. |
||
88 | * @param mixed $default The default value if the option is not set. |
||
89 | * |
||
90 | * @return mixed The option value. |
||
91 | */ |
||
92 | 1 | public function getOption(string $key, $default = null) |
|
96 | |||
97 | /** |
||
98 | * Set an option for the Transifex instance. |
||
99 | * |
||
100 | * @param string $key The name of the option to set. |
||
101 | * @param mixed $value The option value to set. |
||
102 | * |
||
103 | * @return $this |
||
104 | */ |
||
105 | 1 | public function setOption(string $key, $value) : Transifex |
|
111 | } |
||
112 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..