Class: Google::Apis::DatastoreV1::EntityResult
- Inherits:
-
Object
- Object
- Google::Apis::DatastoreV1::EntityResult
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/datastore_v1/classes.rb,
generated/google/apis/datastore_v1/representations.rb,
generated/google/apis/datastore_v1/representations.rb
Overview
The result of fetching an entity from Datastore.
Instance Attribute Summary collapse
-
#cursor ⇒ String
A cursor that points to the position after the result entity.
-
#entity ⇒ Google::Apis::DatastoreV1::Entity
A Datastore data object.
-
#version ⇒ String
The version of the entity, a strictly positive number that monotonically increases with changes to the entity.
Instance Method Summary collapse
-
#initialize(**args) ⇒ EntityResult
constructor
A new instance of EntityResult.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ EntityResult
Returns a new instance of EntityResult
288 289 290 |
# File 'generated/google/apis/datastore_v1/classes.rb', line 288 def initialize(**args) update!(**args) end |
Instance Attribute Details
#cursor ⇒ String
A cursor that points to the position after the result entity.
Set only when the EntityResult is part of a QueryResultBatch message.
Corresponds to the JSON property cursor
NOTE: Values are automatically base64 encoded/decoded in the client library.
286 287 288 |
# File 'generated/google/apis/datastore_v1/classes.rb', line 286 def cursor @cursor end |
#entity ⇒ Google::Apis::DatastoreV1::Entity
A Datastore data object.
An entity is limited to 1 megabyte when stored. That roughly
corresponds to a limit of 1 megabyte for the serialized form of this
message.
Corresponds to the JSON property entity
279 280 281 |
# File 'generated/google/apis/datastore_v1/classes.rb', line 279 def entity @entity end |
#version ⇒ String
The version of the entity, a strictly positive number that monotonically
increases with changes to the entity.
This field is set for FULL entity
results.
For missing entities in LookupResponse, 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.
Corresponds to the JSON property version
271 272 273 |
# File 'generated/google/apis/datastore_v1/classes.rb', line 271 def version @version end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
293 294 295 296 297 |
# File 'generated/google/apis/datastore_v1/classes.rb', line 293 def update!(**args) @version = args[:version] if args.key?(:version) @entity = args[:entity] if args.key?(:entity) @cursor = args[:cursor] if args.key?(:cursor) end |