public function current()
    {
        if ($this->mode & self::CURRENT_AS_RESOURCE) {
            return current($this->resources);
        }

        if ($this->mode & self::CURRENT_AS_PATH) {
            return current($this->resources)->getPath();
        }

        return current($this->resources)->getName();
    }
public function current()
    {
        if ($this->mode & self::CURRENT_AS_RESOURCE) {
            return current($this->resources);
        }

        if ($this->mode & self::CURRENT_AS_PATH) {
            return current($this->resources)->getPath();
        }

        return current($this->resources)->getName();
    }
public function current ( ) { if ( $ this -> mode & self :: CURRENT_AS_RESOURCE ) { return current ( $ this -> resources ) ; } if ( $ this -> mode & self :: CURRENT_AS_PATH ) { return current ( $ this -> resources ) -> getPath ( ) ; } return current ( $ this -> resources ) -> getName ( ) ; }
Returns the current value of the iterator.

@return PuliResource|string The current value as configured in
{@link __construct}.
Returns the current value of the iterator .