Class: Google::Apis::DatastoreV1beta2::Entity
- Inherits:
-
Object
- Object
- Google::Apis::DatastoreV1beta2::Entity
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/datastore_v1beta2/classes.rb,
generated/google/apis/datastore_v1beta2/representations.rb,
generated/google/apis/datastore_v1beta2/representations.rb
Overview
An entity.
Instance Attribute Summary collapse
-
#key ⇒ Google::Apis::DatastoreV1beta2::Key
A unique identifier for an entity.
-
#properties ⇒ Hash<String,Google::Apis::DatastoreV1beta2::Property>
The entity's properties.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Entity
constructor
A new instance of Entity.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ Entity
Returns a new instance of Entity.
223 224 225 |
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 223 def initialize(**args) update!(**args) end |
Instance Attribute Details
#key ⇒ Google::Apis::DatastoreV1beta2::Key
A unique identifier for an entity.
Corresponds to the JSON property key
216 217 218 |
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 216 def key @key end |
#properties ⇒ Hash<String,Google::Apis::DatastoreV1beta2::Property>
The entity's properties.
Corresponds to the JSON property properties
221 222 223 |
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 221 def properties @properties end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
228 229 230 231 |
# File 'generated/google/apis/datastore_v1beta2/classes.rb', line 228 def update!(**args) @key = args[:key] if args.key?(:key) @properties = args[:properties] if args.key?(:properties) end |