Skip to content

Commit f3d9937

Browse files
committed
Add typehints
1 parent 72b93b8 commit f3d9937

31 files changed

+144
-144
lines changed

kms/src/create_key_asymmetric_decrypt.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@
2525
use Google\Cloud\Kms\V1\KeyManagementServiceClient;
2626

2727
function create_key_asymmetric_decrypt_sample(
28-
$projectId = 'my-project',
29-
$locationId = 'us-east1',
30-
$keyRingId = 'my-key-ring',
31-
$id = 'my-asymmetric-decrypt-key'
28+
string $projectId = 'my-project',
29+
string $locationId = 'us-east1',
30+
string $keyRingId = 'my-key-ring',
31+
string $id = 'my-asymmetric-decrypt-key'
3232
) {
3333
// Create the Cloud KMS client.
3434
$client = new KeyManagementServiceClient();

kms/src/create_key_asymmetric_sign.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@
2525
use Google\Cloud\Kms\V1\KeyManagementServiceClient;
2626

2727
function create_key_asymmetric_sign_sample(
28-
$projectId = 'my-project',
29-
$locationId = 'us-east1',
30-
$keyRingId = 'my-key-ring',
31-
$id = 'my-asymmetric-signing-key'
28+
string $projectId = 'my-project',
29+
string $locationId = 'us-east1',
30+
string $keyRingId = 'my-key-ring',
31+
string $id = 'my-asymmetric-signing-key'
3232
) {
3333
// Create the Cloud KMS client.
3434
$client = new KeyManagementServiceClient();

kms/src/create_key_hsm.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@
2626
use Google\Cloud\Kms\V1\ProtectionLevel;
2727

2828
function create_key_hsm_sample(
29-
$projectId = 'my-project',
30-
$locationId = 'us-east1',
31-
$keyRingId = 'my-key-ring',
32-
$id = 'my-hsm-key'
29+
string $projectId = 'my-project',
30+
string $locationId = 'us-east1',
31+
string $keyRingId = 'my-key-ring',
32+
string $id = 'my-hsm-key'
3333
) {
3434
// Create the Cloud KMS client.
3535
$client = new KeyManagementServiceClient();

kms/src/create_key_labels.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@
2525
use Google\Cloud\Kms\V1\KeyManagementServiceClient;
2626

2727
function create_key_labels_sample(
28-
$projectId = 'my-project',
29-
$locationId = 'us-east1',
30-
$keyRingId = 'my-key-ring',
31-
$id = 'my-key-with-labels'
28+
string $projectId = 'my-project',
29+
string $locationId = 'us-east1',
30+
string $keyRingId = 'my-key-ring',
31+
string $id = 'my-key-with-labels'
3232
) {
3333
// Create the Cloud KMS client.
3434
$client = new KeyManagementServiceClient();

kms/src/create_key_ring.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@
2222
use Google\Cloud\Kms\V1\KeyRing;
2323

2424
function create_key_ring_sample(
25-
$projectId = 'my-project',
26-
$locationId = 'us-east1',
27-
$id = 'my-key-ring'
25+
string $projectId = 'my-project',
26+
string $locationId = 'us-east1',
27+
string $id = 'my-key-ring'
2828
) {
2929
// Create the Cloud KMS client.
3030
$client = new KeyManagementServiceClient();

kms/src/create_key_rotation_schedule.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@
2727
use Google\Protobuf\Timestamp;
2828

2929
function create_key_rotation_schedule_sample(
30-
$projectId = 'my-project',
31-
$locationId = 'us-east1',
32-
$keyRingId = 'my-key-ring',
33-
$id = 'my-key-with-rotation-schedule'
30+
string $projectId = 'my-project',
31+
string $locationId = 'us-east1',
32+
string $keyRingId = 'my-key-ring',
33+
string $id = 'my-key-with-rotation-schedule'
3434
) {
3535
// Create the Cloud KMS client.
3636
$client = new KeyManagementServiceClient();

kms/src/create_key_symmetric_encrypt_decrypt.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@
2525
use Google\Cloud\Kms\V1\KeyManagementServiceClient;
2626

2727
function create_key_symmetric_encrypt_decrypt_sample(
28-
$projectId = 'my-project',
29-
$locationId = 'us-east1',
30-
$keyRingId = 'my-key-ring',
31-
$id = 'my-symmetric-key'
28+
string $projectId = 'my-project',
29+
string $locationId = 'us-east1',
30+
string $keyRingId = 'my-key-ring',
31+
string $id = 'my-symmetric-key'
3232
) {
3333
// Create the Cloud KMS client.
3434
$client = new KeyManagementServiceClient();

kms/src/create_key_version.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222
use Google\Cloud\Kms\V1\KeyManagementServiceClient;
2323

2424
function create_key_version_sample(
25-
$projectId = 'my-project',
26-
$locationId = 'us-east1',
27-
$keyRingId = 'my-key-ring',
28-
$keyId = 'my-key'
25+
string $projectId = 'my-project',
26+
string $locationId = 'us-east1',
27+
string $keyRingId = 'my-key-ring',
28+
string $keyId = 'my-key'
2929
) {
3030
// Create the Cloud KMS client.
3131
$client = new KeyManagementServiceClient();

kms/src/decrypt_asymmetric.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@
2121
use Google\Cloud\Kms\V1\KeyManagementServiceClient;
2222

2323
function decrypt_asymmetric_sample(
24-
$projectId = 'my-project',
25-
$locationId = 'us-east1',
26-
$keyRingId = 'my-key-ring',
27-
$keyId = 'my-key',
28-
$versionId = '123',
29-
$ciphertext = '...'
24+
string $projectId = 'my-project',
25+
string $locationId = 'us-east1',
26+
string $keyRingId = 'my-key-ring',
27+
string $keyId = 'my-key',
28+
string $versionId = '123',
29+
string $ciphertext = '...'
3030
) {
3131
// Create the Cloud KMS client.
3232
$client = new KeyManagementServiceClient();

kms/src/decrypt_symmetric.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@
2121
use Google\Cloud\Kms\V1\KeyManagementServiceClient;
2222

2323
function decrypt_symmetric_sample(
24-
$projectId = 'my-project',
25-
$locationId = 'us-east1',
26-
$keyRingId = 'my-key-ring',
27-
$keyId = 'my-key',
28-
$ciphertext = '...'
24+
string $projectId = 'my-project',
25+
string $locationId = 'us-east1',
26+
string $keyRingId = 'my-key-ring',
27+
string $keyId = 'my-key',
28+
string $ciphertext = '...'
2929
) {
3030
// Create the Cloud KMS client.
3131
$client = new KeyManagementServiceClient();

0 commit comments

Comments
 (0)