GoogleCloudSamples.QuickStart.PrintBucketAcl C# (CSharp) Method

PrintBucketAcl() private method

private PrintBucketAcl ( string bucketName ) : void
bucketName string
return void
        private void PrintBucketAcl(string bucketName)
        {
            var storage = StorageClient.Create();
            var bucket = storage.GetBucket(bucketName, new GetBucketOptions()
            {
                Projection = Projection.Full
            });
            if (bucket.Acl != null)
                foreach (var acl in bucket.Acl)
                {
                    Console.WriteLine($"{acl.Role}:{acl.Entity}");
                }
        }