Reference documentation and code samples for the Compute V1 Client class Metadata.
A metadata key/value entry.
Generated from protobuf message google.cloud.compute.v1.Metadata
Namespace
Google \ Cloud \ Compute \ V1Methods
__construct
Constructor.
Parameters | |
---|---|
Name | Description |
data |
array
Optional. Data for populating the Message object. |
↳ fingerprint |
string
Specifies a fingerprint for this request, which is essentially a hash of the metadata's contents and used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update metadata. You must always provide an up-to-date fingerprint hash in order to update or change metadata, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve the resource. |
↳ items |
array<Items>
Array of key/value pairs. The total size of all keys and values must be less than 512 KB. |
↳ kind |
string
[Output Only] Type of the resource. Always compute#metadata for metadata. |
getFingerprint
Specifies a fingerprint for this request, which is essentially a hash of the metadata's contents and used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update metadata. You must always provide an up-to-date fingerprint hash in order to update or change metadata, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve the resource.
Returns | |
---|---|
Type | Description |
string |
hasFingerprint
clearFingerprint
setFingerprint
Specifies a fingerprint for this request, which is essentially a hash of the metadata's contents and used for optimistic locking. The fingerprint is initially generated by Compute Engine and changes after every request to modify or update metadata. You must always provide an up-to-date fingerprint hash in order to update or change metadata, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve the resource.
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |
getItems
Array of key/value pairs. The total size of all keys and values must be less than 512 KB.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setItems
Array of key/value pairs. The total size of all keys and values must be less than 512 KB.
Parameter | |
---|---|
Name | Description |
var |
array<Items>
|
Returns | |
---|---|
Type | Description |
$this |
getKind
[Output Only] Type of the resource. Always compute#metadata for metadata.
Returns | |
---|---|
Type | Description |
string |
hasKind
clearKind
setKind
[Output Only] Type of the resource. Always compute#metadata for metadata.
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |