Set the visibility for the given path.

@param  string  $path
@param  string  $visibility
@return bool
480198
public function setVisibility($path, $visibility)
    {
        return $this->driver->setVisibility($path, $this->parseVisibility($visibility));
    }
764095
public static function getVisibilityModifier($visibility)
	{
		if(is_integer($visibility))
		{
			$visibility = self::getVisibilityString($visibility);
		}
		
		switch(strtolower($visibility))
		{
			case self::VISIBILITY_PRIVATE:
				return self::IS_PRIVATE;
			case self::VISIBILITY_PROTECTED:
				return self::IS_PROTECTED;
			case self::VISIBILITY_PUBLIC:
			case 'var':
				return self::IS_PUBLIC;
		}
		
		throw new \InvalidArgumentException('Unsupported visibility: "' . $visibility . '" must be one of "public", "var", "private", "protected"');
	}
99238
public function limitMaximumSetVisibility(string $visibility): self
    {
        $this->generate_set = Generate::getMostLimitedVisibility($this->generate_set, $visibility);

        return $this;
    }
1091302
public function setPath( $path )
    {
        // Validate $path, it cant be null and must exist
        if ( ! is_string( $path ) ){ throw new InvalidPathException( 'Path must be of type string' ); }
        if ( is_null( $path ) ){ throw new InvalidPathException( 'Path can not be null' ); }
        if ( ! file_exists( $path )){ throw new InvalidPathException( '('. $path .') is invalid' ); }

        $this->path = $path;
    }
1041844
public function setPath($path)
    {
        if (!file_exists($path))
        {
            mkdir($path, 0777, true);
        }

        $this->path = $path;
    }
838205
public function setCachePath($path) {
		$path = rtrim($path, DIRECTORY_SEPARATOR);
		$path = realpath($path);
		
		if ($path === false) {
			throw new NoPath('Invalid path: "' . func_get_arg(0) . '"');
		}
		
		if (! is_dir($path)) {
			throw new NoPath('Path must be a directory: "' . $path . '"');
		}
		
		if (! is_writeable($path)) {
			throw new NoPath('Path must be a writable: "' . $path . '"');
		}
		
		$this->path = $path;
	}
173199
public function setPath($path)
    {
        if ($this->path) {
            $this->old_paths[] = $this->path;
        }
        $this->path = $path;

        return $this;
    }
81427
protected function getRawVisibility($path)
    {
        try {
            $acl = $this->getObject($path)->acl()->get(['entity' => 'allUsers']);
            return $acl['role'] === Acl::ROLE_READER ?
                AdapterInterface::VISIBILITY_PUBLIC :
                AdapterInterface::VISIBILITY_PRIVATE;
        } catch (NotFoundException $e) {
            // object may not have an acl entry, so handle that gracefully
            return AdapterInterface::VISIBILITY_PRIVATE;
        }
    }
1202991
public function setPath( $path )
	{
#		if( $path && !file_exists( $path ) )
#			throw new RuntimeException( 'Invalid path' );
		$path	= str_replace( DIRECTORY_SEPARATOR, "/", $path );
		$path	= preg_replace( "@(.+)/$@", "\\1", $path )."/";
		$this->path	= $path;
	}
1145987
protected function _setPreviewDir($path = null) {
		$path = (string)$path;
		if (file_exists($path)) {
			$this->_pathPreviewDir = $path;
		}
	}
499620
public function setMutatorVisibility($visibility)
    {
        $visibility = strtolower($visibility);
        if (!in_array($visibility, self::$validVisibilities)) {
            $visibility = self::DEFAULT_VISIBILITY;
        }

        $this->mutatorVisibility = $visibility;
    }
96197
public function getVisibility($path)
    {
        $meta = $this->client->getObjectAcl([
            'Bucket' => $this->getBucket(),
            'Key'    => $path,
        ]);

        foreach ($meta->get('Grants') as $grant) {
            if (isset($grant['Grantee']['URI'])
                && $grant['Permission'] === 'READ'
                && strpos($grant['Grantee']['URI'], 'global/AllUsers') !== false
            ) {
                return ['visibility' => AdapterInterface::VISIBILITY_PUBLIC];
            }
        }

        return ['visibility' => AdapterInterface::VISIBILITY_PRIVATE];
    }
150343
public static function addViewPath( $path )
    {
        self::$_viewPaths = array_merge(
            Option::clean( self::$_viewPaths ),
            array($path)
        );

        self::$_twigLoader = new \Twig_Loader_Filesystem( self::$_viewPaths );
        self::$_twigEnvironment = new \Twig_Environment( self::$_twigLoader );
    }
1052851
public function setDefaultVisibility(string $visibility): void
    {
        if (null === $this->get) {
            $this->get = $visibility;
        }

        if (null === $this->set) {
            $this->set = $visibility;
        }

        if (null === $this->add) {
            $this->add = $visibility;
        }

        if (null !== $this->remove) {
            return;
        }

        $this->remove = $visibility;
    }
1194479
public function setPath($path)
    {
        if (!is_string($path)) {
            $path = $this->app->url($path);
        }
        $this->path = $path.'#';

        return $this;
    }
949911
public function update_visibility($visible = null) {
        if (is_bool($visible)) {
            $this->_visible = $visible;
        } else {
            $this->_visible = !$this->_visible;
        }
        return $this->update_visible();
    }
342349
public function setPath($path)
    {
        if ($path) {
            $this->not_cleared_path = $path;
            $this->doClearPath();
        } else {
            $this->path = '';
        }

        return $this;
    }