Skip to content

Commit 6e6fd0a

Browse files
authored
fix: updates all storage sample region tags (GoogleCloudPlatform#1035)
1 parent 1ccdf6d commit 6e6fd0a

35 files changed

+70
-70
lines changed

storage/src/add_bucket_acl.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START add_bucket_acl]
26+
# [START storage_add_bucket_owner]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -45,4 +45,4 @@ function add_bucket_acl($bucketName, $entity, $role, $options = [])
4545
$acl->add($entity, $role, $options);
4646
printf('Added %s (%s) to gs://%s ACL' . PHP_EOL, $entity, $role, $bucketName);
4747
}
48-
# [END add_bucket_acl]
48+
# [END storage_add_bucket_owner]

storage/src/add_bucket_conditional_iam_binding.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START add_bucket_conditional_iam_binding]
26+
# [START storage_add_bucket_conditional_iam_binding]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -71,4 +71,4 @@ function add_bucket_conditional_iam_binding($bucketName, $role, $members, $title
7171
printf(' Description: %s' . PHP_EOL, $description);
7272
printf(' Expression: %s' . PHP_EOL, $expression);
7373
}
74-
# [END add_bucket_conditional_iam_binding]
74+
# [END storage_add_bucket_conditional_iam_binding]

storage/src/add_bucket_default_acl.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START add_bucket_default_acl]
26+
# [START storage_add_bucket_default_owner]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -45,4 +45,4 @@ function add_bucket_default_acl($bucketName, $entity, $role, $options = [])
4545
$acl->add($entity, $role, $options);
4646
printf('Added %s (%s) to gs://%s default ACL' . PHP_EOL, $entity, $role, $bucketName);
4747
}
48-
# [END add_bucket_default_acl]
48+
# [END storage_add_bucket_default_owner]

storage/src/add_bucket_iam_member.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START add_bucket_iam_member]
26+
# [START storage_add_bucket_iam_member]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -56,4 +56,4 @@ function add_bucket_iam_member($bucketName, $role, $members)
5656
printf(' %s' . PHP_EOL, $member);
5757
}
5858
}
59-
# [END add_bucket_iam_member]
59+
# [END storage_add_bucket_iam_member]

storage/src/add_bucket_label.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START add_bucket_label]
26+
# [START storage_add_bucket_label]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -41,4 +41,4 @@ function add_bucket_label($bucketName, $labelName, $labelValue)
4141
$bucket->update(['labels' => $newLabels]);
4242
printf('Added label %s (%s) to %s' . PHP_EOL, $labelName, $labelValue, $bucketName);
4343
}
44-
# [END add_bucket_label]
44+
# [END storage_add_bucket_label]

storage/src/add_object_acl.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START add_object_acl]
26+
# [START storage_add_file_owner]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -47,4 +47,4 @@ function add_object_acl($bucketName, $objectName, $entity, $role, $options = [])
4747
$acl->add($entity, $role, $options);
4848
printf('Added %s (%s) to gs://%s/%s ACL' . PHP_EOL, $entity, $role, $bucketName, $objectName);
4949
}
50-
# [END add_object_acl]
50+
# [END storage_add_file_owner]

storage/src/copy_object.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START copy_object]
26+
# [START storage_copy_file]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -44,4 +44,4 @@ function copy_object($bucketName, $objectName, $newBucketName, $newObjectName)
4444
printf('Copied gs://%s/%s to gs://%s/%s' . PHP_EOL,
4545
$bucketName, $objectName, $newBucketName, $newObjectName);
4646
}
47-
# [END copy_object]
47+
# [END storage_copy_file]

storage/src/create_bucket.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START create_bucket]
26+
# [START storage_create_bucket]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -39,4 +39,4 @@ function create_bucket($bucketName, $options = [])
3939
$bucket = $storage->createBucket($bucketName, $options);
4040
printf('Bucket created: %s' . PHP_EOL, $bucket->name());
4141
}
42-
# [END create_bucket]
42+
# [END storage_create_bucket]

storage/src/delete_bucket.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START delete_bucket]
26+
# [START storage_delete_bucket]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -40,4 +40,4 @@ function delete_bucket($bucketName)
4040
$bucket->delete();
4141
printf('Bucket deleted: %s' . PHP_EOL, $bucket->name());
4242
}
43-
# [END delete_bucket]
43+
# [END storage_delete_bucket]

storage/src/delete_bucket_acl.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START delete_bucket_acl]
26+
# [START storage_remove_bucket_owner]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -43,4 +43,4 @@ function delete_bucket_acl($bucketName, $entity, $options = [])
4343
$acl->delete($entity, $options);
4444
printf('Deleted %s from gs://%s ACL' . PHP_EOL, $entity, $bucketName);
4545
}
46-
# [END delete_bucket_acl]
46+
# [END storage_remove_bucket_owner]

storage/src/delete_bucket_default_acl.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START delete_bucket_default_acl]
26+
# [START storage_remove_bucket_default_owner]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -43,4 +43,4 @@ function delete_bucket_default_acl($bucketName, $entity, $options = [])
4343
$acl->delete($entity, $options);
4444
printf('Deleted %s from gs://%s default ACL' . PHP_EOL, $entity, $bucketName);
4545
}
46-
# [END delete_bucket_default_acl]
46+
# [END storage_remove_bucket_default_owner]

storage/src/delete_object.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START delete_object]
26+
# [START storage_delete_file]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -43,4 +43,4 @@ function delete_object($bucketName, $objectName, $options = [])
4343
$object->delete();
4444
printf('Deleted gs://%s/%s' . PHP_EOL, $bucketName, $objectName);
4545
}
46-
# [END delete_object]
46+
# [END storage_delete_file]

storage/src/delete_object_acl.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START delete_object_acl]
26+
# [START storage_remove_file_owner]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -45,4 +45,4 @@ function delete_object_acl($bucketName, $objectName, $entity, $options = [])
4545
$acl->delete($entity, $options);
4646
printf('Deleted %s from gs://%s/%s ACL' . PHP_EOL, $entity, $bucketName, $objectName);
4747
}
48-
# [END delete_object_acl]
48+
# [END storage_remove_file_owner]

storage/src/disable_requester_pays.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START disable_requester_pays]
26+
# [START storage_disable_requester_pays]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -47,4 +47,4 @@ function disable_requester_pays($projectId, $bucketName)
4747
]);
4848
printf('Requester pays has been disabled for %s' . PHP_EOL, $bucketName);
4949
}
50-
# [END disable_requester_pays]
50+
# [END storage_disable_requester_pays]

storage/src/download_encrypted_object.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START download_encrypted_object]
26+
# [START storage_download_encrypted_file]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -47,4 +47,4 @@ function download_encrypted_object($bucketName, $objectName, $destination, $base
4747
printf('Encrypted object gs://%s/%s downloaded to %s' . PHP_EOL,
4848
$bucketName, $objectName, basename($destination));
4949
}
50-
# [END download_encrypted_object]
50+
# [END storage_download_encrypted_file]

storage/src/download_file_requester_pays.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START download_file_requester_pays]
26+
# [START storage_download_file_requester_pays]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -48,4 +48,4 @@ function download_file_requester_pays($projectId, $bucketName, $objectName, $des
4848
printf('Downloaded gs://%s/%s to %s using requester-pays requests.' . PHP_EOL,
4949
$bucketName, $objectName, basename($destination));
5050
}
51-
# [END download_file_requester_pays]
51+
# [END storage_download_file_requester_pays]

storage/src/download_object.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START download_object]
26+
# [START storage_download_file]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -44,4 +44,4 @@ function download_object($bucketName, $objectName, $destination)
4444
printf('Downloaded gs://%s/%s to %s' . PHP_EOL,
4545
$bucketName, $objectName, basename($destination));
4646
}
47-
# [END download_object]
47+
# [END storage_download_file]

storage/src/enable_requester_pays.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START enable_requester_pays]
26+
# [START storage_enable_requester_pays]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -47,4 +47,4 @@ function enable_requester_pays($projectId, $bucketName)
4747
]);
4848
printf('Requester pays has been enabled for %s' . PHP_EOL, $bucketName);
4949
}
50-
# [END enable_requester_pays]
50+
# [END storage_enable_requester_pays]

storage/src/generate_encryption_key.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START generate_encryption_key]
26+
# [START storage_generate_encryption_key]
2727

2828
/**
2929
* Generate a base64 encoded encryption key for Google Cloud Storage.
@@ -36,4 +36,4 @@ function generate_encryption_key()
3636
$encodedKey = base64_encode($key);
3737
printf('Your encryption key: %s' . PHP_EOL, $encodedKey);
3838
}
39-
# [END generate_encryption_key]
39+
# [END storage_generate_encryption_key]

storage/src/get_bucket_acl.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START get_bucket_acl]
26+
# [START storage_print_bucket_acl]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -42,4 +42,4 @@ function get_bucket_acl($bucketName)
4242
printf('%s: %s' . PHP_EOL, $item['entity'], $item['role']);
4343
}
4444
}
45-
# [END get_bucket_acl]
45+
# [END storage_print_bucket_acl]

storage/src/get_bucket_labels.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START get_bucket_labels]
26+
# [START storage_get_bucket_labels]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -42,4 +42,4 @@ function get_bucket_labels($bucketName)
4242
}
4343
}
4444
}
45-
# [END get_bucket_labels]
45+
# [END storage_get_bucket_labels]

storage/src/get_object_acl.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START get_object_acl]
26+
# [START storage_print_file_acl]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -44,4 +44,4 @@ function get_object_acl($bucketName, $objectName)
4444
printf('%s: %s' . PHP_EOL, $item['entity'], $item['role']);
4545
}
4646
}
47-
# [END get_object_acl]
47+
# [END storage_print_file_acl]

storage/src/get_requester_pays_status.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START get_requester_pays_status]
26+
# [START storage_get_requester_pays_status]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -48,4 +48,4 @@ function get_requester_pays_status($projectId, $bucketName)
4848
printf('Requester Pays is disabled for %s' . PHP_EOL, $bucketName);
4949
}
5050
}
51-
# [END get_requester_pays_status]
51+
# [END storage_get_requester_pays_status]

storage/src/list_buckets.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START list_buckets]
26+
# [START storage_list_buckets]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -38,4 +38,4 @@ function list_buckets()
3838
printf('Bucket: %s' . PHP_EOL, $bucket->name());
3939
}
4040
}
41-
# [END list_buckets]
41+
# [END storage_list_buckets]

storage/src/list_objects.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START list_objects]
26+
# [START storage_list_files]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -41,4 +41,4 @@ function list_objects($bucketName)
4141
printf('Object: %s' . PHP_EOL, $object->name());
4242
}
4343
}
44-
# [END list_objects]
44+
# [END storage_list_files]

storage/src/list_objects_with_prefix.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
namespace Google\Cloud\Samples\Storage;
2525

26-
# [START list_objects_with_prefix]
26+
# [START storage_list_files_with_prefix]
2727
use Google\Cloud\Storage\StorageClient;
2828

2929
/**
@@ -42,4 +42,4 @@ function list_objects_with_prefix($bucketName, $prefix)
4242
printf('Object: %s' . PHP_EOL, $object->name());
4343
}
4444
}
45-
# [END list_objects_with_prefix]
45+
# [END storage_list_files_with_prefix]

0 commit comments

Comments
 (0)