Package com.google.cloud.datastore
Class BaseEntity.Builder<K extends IncompleteKey,B extends BaseEntity.Builder<K,B>>
java.lang.Object
com.google.cloud.datastore.BaseEntity.Builder<K,B>
- Direct Known Subclasses:
Entity.Builder
,FullEntity.Builder
,ProjectionEntity.Builder
- Enclosing class:
- BaseEntity<K extends IncompleteKey>
public abstract static class BaseEntity.Builder<K extends IncompleteKey,B extends BaseEntity.Builder<K,B>>
extends Object
-
Method Summary
Modifier and TypeMethodDescriptionabstract BaseEntity<K>
build()
clear()
Clears all the properties.protected K
key()
Removes a property with the givenname
.Sets a property of typeBooleanValue
.Sets a list property containing elements of typeBooleanValue
.Sets a property of typeDoubleValue
.Sets a list property containing elements of typeDoubleValue
.Sets a property of typeLongValue
.Sets a list property containing elements of typeLongValue
.Sets a property of typeBlobValue
.Sets a list property containing elements of typeBlobValue
.set
(String name, FullEntity<?> value) Sets a property of typeEntityValue
.set
(String name, FullEntity<?> first, FullEntity<?> second, FullEntity<?>... others) Sets a list property containing elements of typeEntityValue
.Sets a property of typeKeyValue
.Sets a list property containing elements of typeKeyValue
.Sets a property of typeLatLng
.Sets a list property containing elements of typeLatLng
.Sets a property.Sets a property of typeListValue
.Sets a property of typeTimestampValue
.set
(String name, com.google.cloud.Timestamp first, com.google.cloud.Timestamp second, com.google.cloud.Timestamp... others) Sets a list property containing elements of typeTimestampValue
.Sets a property of typeStringValue
.Sets a list property containing elements of typeStringValue
.Sets a property of typeListValue
.Sets the key for the entity.Sets a property of typeNullValue
.protected B
setProperties
(Map<String, Value<?>> properties)
-
Method Details
-
key
-
setProperties
-
setProperties
-
setKey
Sets the key for the entity. -
clear
Clears all the properties. -
remove
Removes a property with the givenname
. -
set
Sets a property.- Parameters:
name
- name of the propertyvalue
- value associated with the property
-
set
Sets a property of typeStringValue
.- Parameters:
name
- name of the propertyvalue
- value associated with the property
-
set
Sets a list property containing elements of typeStringValue
.- Parameters:
name
- name of the propertyfirst
- the first string in the listsecond
- the second string in the listothers
- other strings in the list
-
set
Sets a property of typeLongValue
.- Parameters:
name
- name of the propertyvalue
- value associated with the property
-
set
Sets a list property containing elements of typeLongValue
.- Parameters:
name
- name of the propertyfirst
- the first long in the listsecond
- the second long in the listothers
- other longs in the list
-
set
Sets a property of typeDoubleValue
.- Parameters:
name
- name of the propertyvalue
- value associated with the property
-
set
Sets a list property containing elements of typeDoubleValue
.- Parameters:
name
- name of the propertyfirst
- the first double in the listsecond
- the second double in the listothers
- other doubles in the list
-
set
Sets a property of typeBooleanValue
.- Parameters:
name
- name of the propertyvalue
- value associated with the property
-
set
Sets a list property containing elements of typeBooleanValue
.- Parameters:
name
- name of the propertyfirst
- the first boolean in the listsecond
- the second boolean in the listothers
- other booleans in the list
-
set
Sets a property of typeTimestampValue
.- Parameters:
name
- name of the propertyvalue
- value associated with the property
-
set
public B set(String name, com.google.cloud.Timestamp first, com.google.cloud.Timestamp second, com.google.cloud.Timestamp... others) Sets a list property containing elements of typeTimestampValue
.- Parameters:
name
- name of the propertyfirst
- the firstTimestamp
in the listsecond
- the secondTimestamp
in the listothers
- otherTimestamp
s in the list
-
set
Sets a property of typeLatLng
.- Parameters:
name
- name of the propertyvalue
- value associated with the property
-
set
Sets a list property containing elements of typeLatLng
. -
set
Sets a property of typeKeyValue
.- Parameters:
name
- name of the propertyvalue
- value associated with the property
-
set
Sets a list property containing elements of typeKeyValue
. -
set
Sets a property of typeEntityValue
.- Parameters:
name
- name of the propertyvalue
- value associated with the property
-
set
Sets a list property containing elements of typeEntityValue
.- Parameters:
name
- name of the propertyfirst
- the firstFullEntity
in the listsecond
- the secondFullEntity
in the listothers
- other entities in the list
-
set
Sets a property of typeListValue
.- Parameters:
name
- name of the propertyvalues
- list of values associated with the property
-
set
Sets a property of typeListValue
.- Parameters:
name
- name of the propertyfirst
- the first value in the listsecond
- the second value in the listothers
- other values in the list
-
set
Sets a property of typeBlobValue
.- Parameters:
name
- name of the propertyvalue
- value associated with the property
-
set
Sets a list property containing elements of typeBlobValue
. -
setNull
Sets a property of typeNullValue
.- Parameters:
name
- name of the property
-
build
-