public function offsetGet($offset)
    {
        try {
            $res = $this
                ->seekToOffset($offset)
                ->current();
        } catch (OutOfRangeException $e) {
            $res = null;
            trigger_error("Undefined offset: '$offset'", E_USER_NOTICE);
        }
        return $res;
    }