for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* ArrayAccessTrait
*
* @package php-deferred-callchain
* @author Jean Claveau
*/
namespace JClaveau\Async;
use BadMethodCallException;
* Trait gathering unused array access required methods
trait ArrayAccessTrait
{
* Unused part of the ArrayAccess interface
* @param $offset
* @param $value
* @throws \BadMethodCallException
public function offsetSet($offset, $value)
$value
If this is a false-positive, you can also ignore this issue in your code via the ignore-unused annotation
ignore-unused
public function offsetSet($offset, /** @scrutinizer ignore-unused */ $value)
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.
$offset
public function offsetSet(/** @scrutinizer ignore-unused */ $offset, $value)
throw new BadMethodCallException("not implemented");
}
public function offsetExists($offset)
public function offsetExists(/** @scrutinizer ignore-unused */ $offset)
public function offsetUnset($offset)
public function offsetUnset(/** @scrutinizer ignore-unused */ $offset)
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.