src/Uploading/MoveStrategy.php
public function setFilePermissions($permissions)
    {
        if (! is_int($permissions)) {
            throw new InvalidArgumentException(sprintf(
                'Invalid file permissins provided; must be an '
                . 'integer, "%s" received.',
                is_object($permissions) ? get_class($permissions)
                                        : gettype($permissions)
            ));
        }
        if (! (0b100000000 & $permissions)) {
            throw new InvalidArgumentException(sprintf(
                'Invalid file permissions "%s" provided. '
                . 'Files will not available for reading.',
                decoct($permissions)
            ));
        }
        if (! (0b010000000 & $permissions)) {
            throw new InvalidArgumentException(sprintf(
                'Invalid file permissions "%s" provided. '
                . 'Files will not available for writing.',
                decoct($permissions)
            ));
        }
        if (0b001000000 & $permissions) {
            throw new InvalidArgumentException(sprintf(
                'Invalid file permissions "%s" provided. '
                . 'Files will be executable.',
                decoct($permissions)
            ));
        }
        $this->filePermissions = $permissions;
    }
public function setFilePermissions($permissions)
    {
        if (! is_int($permissions)) {
            throw new InvalidArgumentException(sprintf(
                'Invalid file permissins provided; must be an '
                . 'integer, "%s" received.',
                is_object($permissions) ? get_class($permissions)
                                        : gettype($permissions)
            ));
        }
        if (! (0b100000000 & $permissions)) {
            throw new InvalidArgumentException(sprintf(
                'Invalid file permissions "%s" provided. '
                . 'Files will not available for reading.',
                decoct($permissions)
            ));
        }
        if (! (0b010000000 & $permissions)) {
            throw new InvalidArgumentException(sprintf(
                'Invalid file permissions "%s" provided. '
                . 'Files will not available for writing.',
                decoct($permissions)
            ));
        }
        if (0b001000000 & $permissions) {
            throw new InvalidArgumentException(sprintf(
                'Invalid file permissions "%s" provided. '
                . 'Files will be executable.',
                decoct($permissions)
            ));
        }
        $this->filePermissions = $permissions;
    }
public function setFilePermissions ( $ permissions ) { if ( ! is_int ( $ permissions ) ) { throw new InvalidArgumentException ( sprintf ( 'Invalid file permissins provided; must be an ' . 'integer, "%s" received.' , is_object ( $ permissions ) ? get_class ( $ permissions ) : gettype ( $ permissions ) ) ) ; } if ( ! ( 0b100000000 & $ permissions ) ) { throw new InvalidArgumentException ( sprintf ( 'Invalid file permissions "%s" provided. ' . 'Files will not available for reading.' , decoct ( $ permissions ) ) ) ; } if ( ! ( 0b010000000 & $ permissions ) ) { throw new InvalidArgumentException ( sprintf ( 'Invalid file permissions "%s" provided. ' . 'Files will not available for writing.' , decoct ( $ permissions ) ) ) ; } if ( 0b001000000 & $ permissions ) { throw new InvalidArgumentException ( sprintf ( 'Invalid file permissions "%s" provided. ' . 'Files will be executable.' , decoct ( $ permissions ) ) ) ; } $ this -> filePermissions = $ permissions ; }
Sets the file permissions.

If the upload options contains the "file_permissions" key, this method
will be called automatically.

@param int $permissions The permissions of files in the new location

@throws \InvalidArgumentException

- If specified permissions are non integer
- If specified permissions are not readable
- If specified permissions are not writable
- If specified permissions are executable
Sets the file permissions .