for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Germania\FormValidator;
use Psr\Container\ContainerInterface;
class InputContainer implements ContainerInterface, \ArrayAccess
{
/**
* @var array
*/
public $data;
* @param array $data Optional array
public function __construct( array $data = array() )
$this->data = $data;
}
* @implements ContainerInterface
public function get( $offset )
if ($this->offsetExists( $offset )) {
return $this->data[ $offset ];
throw new NotFoundException;
public function has( $offset )
return $this->offsetExists( $offset );
* @implements ArrayAccess
public function offsetExists($offset)
return isset($this->data[ $offset ]);
public function offsetSet($offset, $value)
$this->data[ $offset ] = $value;
public function offsetGet($offset)
return $this->offsetExists( $offset ) ? $this->data[ $offset ] : null;
public function offsetUnset($offset)
if ($this->offsetExists($offset)) {
unset($this->data[ $offset ]);