public function move($direction)
    {
        if ($direction === self::DIR_FORWARD) {
            return $this->next();
        } elseif ($direction === self::DIR_BACKWARD) {
            return $this->prev();
        }

        throw new InvalidArgumentException(sprintf('Unknown direction %s', $direction));
    }
public function move($direction)
    {
        if ($direction === self::DIR_FORWARD) {
            return $this->next();
        } elseif ($direction === self::DIR_BACKWARD) {
            return $this->prev();
        }

        throw new InvalidArgumentException(sprintf('Unknown direction %s', $direction));
    }
public function move ( $ direction ) { if ( $ direction === self :: DIR_FORWARD ) { return $ this -> next ( ) ; } elseif ( $ direction === self :: DIR_BACKWARD ) { return $ this -> prev ( ) ; } throw new InvalidArgumentException ( sprintf ( 'Unknown direction %s' , $ direction ) ) ; }
Moves the positon based on a direction.

@param int $direction

@return void
Moves the positon based on a direction .