Skip to content

Commit e0a408f

Browse files
1 parent ab8fbbb commit e0a408f

5 files changed

Lines changed: 228 additions & 0 deletions

File tree

src/StorageBatchOperations/BucketOperation.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,8 @@ class BucketOperation extends \Google\Collection
9898
* @var string
9999
*/
100100
public $state;
101+
protected $updateObjectCustomContextType = UpdateObjectCustomContext::class;
102+
protected $updateObjectCustomContextDataType = '';
101103

102104
/**
103105
* The bucket name of the objects to be transformed in the BucketOperation.
@@ -330,6 +332,22 @@ public function getState()
330332
{
331333
return $this->state;
332334
}
335+
/**
336+
* Update object custom context.
337+
*
338+
* @param UpdateObjectCustomContext $updateObjectCustomContext
339+
*/
340+
public function setUpdateObjectCustomContext(UpdateObjectCustomContext $updateObjectCustomContext)
341+
{
342+
$this->updateObjectCustomContext = $updateObjectCustomContext;
343+
}
344+
/**
345+
* @return UpdateObjectCustomContext
346+
*/
347+
public function getUpdateObjectCustomContext()
348+
{
349+
return $this->updateObjectCustomContext;
350+
}
333351
}
334352

335353
// Adding a class alias for backwards compatibility with the previous class name.
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
<?php
2+
/*
3+
* Copyright 2014 Google Inc.
4+
*
5+
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
6+
* use this file except in compliance with the License. You may obtain a copy of
7+
* the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13+
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14+
* License for the specific language governing permissions and limitations under
15+
* the License.
16+
*/
17+
18+
namespace Google\Service\StorageBatchOperations;
19+
20+
class CustomContextUpdates extends \Google\Collection
21+
{
22+
protected $collection_key = 'keysToClear';
23+
/**
24+
* Optional. Custom contexts to clear by key. A key cannot be present in both
25+
* `updates` and `keys_to_clear`.
26+
*
27+
* @var string[]
28+
*/
29+
public $keysToClear;
30+
protected $updatesType = ObjectCustomContextPayload::class;
31+
protected $updatesDataType = 'map';
32+
33+
/**
34+
* Optional. Custom contexts to clear by key. A key cannot be present in both
35+
* `updates` and `keys_to_clear`.
36+
*
37+
* @param string[] $keysToClear
38+
*/
39+
public function setKeysToClear($keysToClear)
40+
{
41+
$this->keysToClear = $keysToClear;
42+
}
43+
/**
44+
* @return string[]
45+
*/
46+
public function getKeysToClear()
47+
{
48+
return $this->keysToClear;
49+
}
50+
/**
51+
* Optional. Insert or update the existing custom contexts.
52+
*
53+
* @param ObjectCustomContextPayload[] $updates
54+
*/
55+
public function setUpdates($updates)
56+
{
57+
$this->updates = $updates;
58+
}
59+
/**
60+
* @return ObjectCustomContextPayload[]
61+
*/
62+
public function getUpdates()
63+
{
64+
return $this->updates;
65+
}
66+
}
67+
68+
// Adding a class alias for backwards compatibility with the previous class name.
69+
class_alias(CustomContextUpdates::class, 'Google_Service_StorageBatchOperations_CustomContextUpdates');

src/StorageBatchOperations/Job.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,8 @@ class Job extends \Google\Collection
115115
* @var string
116116
*/
117117
public $state;
118+
protected $updateObjectCustomContextType = UpdateObjectCustomContext::class;
119+
protected $updateObjectCustomContextDataType = '';
118120

119121
/**
120122
* Specifies a list of buckets and their objects to be transformed.
@@ -384,6 +386,22 @@ public function getState()
384386
{
385387
return $this->state;
386388
}
389+
/**
390+
* Update object custom context.
391+
*
392+
* @param UpdateObjectCustomContext $updateObjectCustomContext
393+
*/
394+
public function setUpdateObjectCustomContext(UpdateObjectCustomContext $updateObjectCustomContext)
395+
{
396+
$this->updateObjectCustomContext = $updateObjectCustomContext;
397+
}
398+
/**
399+
* @return UpdateObjectCustomContext
400+
*/
401+
public function getUpdateObjectCustomContext()
402+
{
403+
return $this->updateObjectCustomContext;
404+
}
387405
}
388406

389407
// Adding a class alias for backwards compatibility with the previous class name.
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
<?php
2+
/*
3+
* Copyright 2014 Google Inc.
4+
*
5+
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
6+
* use this file except in compliance with the License. You may obtain a copy of
7+
* the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13+
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14+
* License for the specific language governing permissions and limitations under
15+
* the License.
16+
*/
17+
18+
namespace Google\Service\StorageBatchOperations;
19+
20+
class ObjectCustomContextPayload extends \Google\Model
21+
{
22+
/**
23+
* The value of the object custom context. If set, `value` must NOT be an
24+
* empty string since it is a required field in custom context. If unset,
25+
* `value` will be ignored and no changes will be made to the `value` field of
26+
* the custom context payload.
27+
*
28+
* @var string
29+
*/
30+
public $value;
31+
32+
/**
33+
* The value of the object custom context. If set, `value` must NOT be an
34+
* empty string since it is a required field in custom context. If unset,
35+
* `value` will be ignored and no changes will be made to the `value` field of
36+
* the custom context payload.
37+
*
38+
* @param string $value
39+
*/
40+
public function setValue($value)
41+
{
42+
$this->value = $value;
43+
}
44+
/**
45+
* @return string
46+
*/
47+
public function getValue()
48+
{
49+
return $this->value;
50+
}
51+
}
52+
53+
// Adding a class alias for backwards compatibility with the previous class name.
54+
class_alias(ObjectCustomContextPayload::class, 'Google_Service_StorageBatchOperations_ObjectCustomContextPayload');
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
<?php
2+
/*
3+
* Copyright 2014 Google Inc.
4+
*
5+
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
6+
* use this file except in compliance with the License. You may obtain a copy of
7+
* the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13+
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14+
* License for the specific language governing permissions and limitations under
15+
* the License.
16+
*/
17+
18+
namespace Google\Service\StorageBatchOperations;
19+
20+
class UpdateObjectCustomContext extends \Google\Model
21+
{
22+
/**
23+
* If set, must be set to true and all existing object custom contexts will be
24+
* deleted.
25+
*
26+
* @var bool
27+
*/
28+
public $clearAll;
29+
protected $customContextUpdatesType = CustomContextUpdates::class;
30+
protected $customContextUpdatesDataType = '';
31+
32+
/**
33+
* If set, must be set to true and all existing object custom contexts will be
34+
* deleted.
35+
*
36+
* @param bool $clearAll
37+
*/
38+
public function setClearAll($clearAll)
39+
{
40+
$this->clearAll = $clearAll;
41+
}
42+
/**
43+
* @return bool
44+
*/
45+
public function getClearAll()
46+
{
47+
return $this->clearAll;
48+
}
49+
/**
50+
* A collection of updates to apply to specific custom contexts. Use this to
51+
* add, update or delete individual contexts by key.
52+
*
53+
* @param CustomContextUpdates $customContextUpdates
54+
*/
55+
public function setCustomContextUpdates(CustomContextUpdates $customContextUpdates)
56+
{
57+
$this->customContextUpdates = $customContextUpdates;
58+
}
59+
/**
60+
* @return CustomContextUpdates
61+
*/
62+
public function getCustomContextUpdates()
63+
{
64+
return $this->customContextUpdates;
65+
}
66+
}
67+
68+
// Adding a class alias for backwards compatibility with the previous class name.
69+
class_alias(UpdateObjectCustomContext::class, 'Google_Service_StorageBatchOperations_UpdateObjectCustomContext');

0 commit comments

Comments
 (0)