The version of the entity, a strictly positive number that monotonically increases with changes to the entity. This field is set forFULLentity results. Formissingentities inLookupResponse, this is the version of the snapshot that was used to look up the entity, and it is always set except for eventually consistent reads.
The version of the entity, a strictly positive number that monotonically
increases with changes to the entity.
This field is set forFULLentity results.
Formissingentities inLookupResponse, this is the version of the snapshot that was used to look
up the entity, and it is always set except for eventually consistent reads.
Returns
Type
Description
int|string
setVersion
The version of the entity, a strictly positive number that monotonically
increases with changes to the entity.
This field is set forFULLentity results.
Formissingentities inLookupResponse, this is the version of the snapshot that was used to look
up the entity, and it is always set except for eventually consistent reads.
Parameter
Name
Description
var
int|string
Returns
Type
Description
$this
getCreateTime
The time at which the entity was created.
This field is set forFULLentity results.
If this entity is missing, this field will not be set.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# Cloud Datastore V1 Client - Class EntityResult (1.33.1)\n\nVersion latestkeyboard_arrow_down\n\n- [1.33.1 (latest)](/php/docs/reference/cloud-datastore/latest/V1.EntityResult)\n- [1.33.0](/php/docs/reference/cloud-datastore/1.33.0/V1.EntityResult)\n- [1.32.3](/php/docs/reference/cloud-datastore/1.32.3/V1.EntityResult)\n- [1.31.0](/php/docs/reference/cloud-datastore/1.31.0/V1.EntityResult)\n- [1.30.0](/php/docs/reference/cloud-datastore/1.30.0/V1.EntityResult)\n- [1.29.2](/php/docs/reference/cloud-datastore/1.29.2/V1.EntityResult)\n- [1.28.2](/php/docs/reference/cloud-datastore/1.28.2/V1.EntityResult)\n- [1.26.0](/php/docs/reference/cloud-datastore/1.26.0/V1.EntityResult)\n- [1.25.0](/php/docs/reference/cloud-datastore/1.25.0/V1.EntityResult)\n- [1.24.4](/php/docs/reference/cloud-datastore/1.24.4/V1.EntityResult)\n- [1.23.0](/php/docs/reference/cloud-datastore/1.23.0/V1.EntityResult)\n- [1.22.1](/php/docs/reference/cloud-datastore/1.22.1/V1.EntityResult)\n- [1.21.2](/php/docs/reference/cloud-datastore/1.21.2/V1.EntityResult)\n- [1.19.0](/php/docs/reference/cloud-datastore/1.19.0/V1.EntityResult)\n- [1.18.1](/php/docs/reference/cloud-datastore/1.18.1/V1.EntityResult)\n- [1.17.1](/php/docs/reference/cloud-datastore/1.17.1/V1.EntityResult) \nReference documentation and code samples for the Cloud Datastore V1 Client class EntityResult.\n\nThe result of fetching an entity from Datastore.\n\nGenerated from protobuf message `google.datastore.v1.EntityResult`\n\nNamespace\n---------\n\nGoogle \\\\ Cloud \\\\ Datastore \\\\ V1\n\nMethods\n-------\n\n### __construct\n\nConstructor.\n\n### getEntity\n\nThe resulting entity.\n\n### hasEntity\n\n### clearEntity\n\n### setEntity\n\nThe resulting entity.\n\n### getVersion\n\nThe version of the entity, a strictly positive number that monotonically\nincreases with changes to the entity.\n\nThis field is set for\n[`FULL`](/php/docs/reference/cloud-datastore/latest/V1.EntityResult.ResultType#_Google_Cloud_Datastore_V1_EntityResult_ResultType__FULL) entity results.\nFor [missing](/php/docs/reference/cloud-datastore/latest/V1.LookupResponse#_Google_Cloud_Datastore_V1_LookupResponse__getMissing__) entities in\n`LookupResponse`, this is the version of the snapshot that was used to look\nup the entity, and it is always set except for eventually consistent reads.\n\n### setVersion\n\nThe version of the entity, a strictly positive number that monotonically\nincreases with changes to the entity.\n\nThis field is set for\n[`FULL`](/php/docs/reference/cloud-datastore/latest/V1.EntityResult.ResultType#_Google_Cloud_Datastore_V1_EntityResult_ResultType__FULL) entity results.\nFor [missing](/php/docs/reference/cloud-datastore/latest/V1.LookupResponse#_Google_Cloud_Datastore_V1_LookupResponse__getMissing__) entities in\n`LookupResponse`, this is the version of the snapshot that was used to look\nup the entity, and it is always set except for eventually consistent reads.\n\n### getCreateTime\n\nThe time at which the entity was created.\n\nThis field is set for\n[`FULL`](/php/docs/reference/cloud-datastore/latest/V1.EntityResult.ResultType#_Google_Cloud_Datastore_V1_EntityResult_ResultType__FULL) entity results.\nIf this entity is missing, this field will not be set.\n\n### hasCreateTime\n\n### clearCreateTime\n\n### setCreateTime\n\nThe time at which the entity was created.\n\nThis field is set for\n[`FULL`](/php/docs/reference/cloud-datastore/latest/V1.EntityResult.ResultType#_Google_Cloud_Datastore_V1_EntityResult_ResultType__FULL) entity results.\nIf this entity is missing, this field will not be set.\n\n### getUpdateTime\n\nThe time at which the entity was last changed.\n\nThis field is set for\n[`FULL`](/php/docs/reference/cloud-datastore/latest/V1.EntityResult.ResultType#_Google_Cloud_Datastore_V1_EntityResult_ResultType__FULL) entity results.\nIf this entity is missing, this field will not be set.\n\n### hasUpdateTime\n\n### clearUpdateTime\n\n### setUpdateTime\n\nThe time at which the entity was last changed.\n\nThis field is set for\n[`FULL`](/php/docs/reference/cloud-datastore/latest/V1.EntityResult.ResultType#_Google_Cloud_Datastore_V1_EntityResult_ResultType__FULL) entity results.\nIf this entity is missing, this field will not be set.\n\n### getCursor\n\nA cursor that points to the position after the result entity.\n\nSet only when the `EntityResult` is part of a `QueryResultBatch` message.\n\n### setCursor\n\nA cursor that points to the position after the result entity.\n\nSet only when the `EntityResult` is part of a `QueryResultBatch` message."]]