Class Entity (2.13.6)

public final class Entity extends FullEntity<Key>

An entity is the Google Cloud Datastore persistent data object for a specific key. An entity will always have a complete Key.

Inheritance

java.lang.Object > BaseEntity > FullEntity > Entity

Static Methods

calculateSerializedSize(BaseEntity<? extends IncompleteKey> entity)

public static int calculateSerializedSize(BaseEntity<? extends IncompleteKey> entity)

Returns the size in bytes of the protobuf form of the provided entity.

Parameter
NameDescription
entityBaseEntity<? extends com.google.cloud.datastore.IncompleteKey>

object whose size is measured.

Returns
TypeDescription
int

fromPb(Entity entityPb)

public static Entity fromPb(Entity entityPb)
Parameter
NameDescription
entityPbEntity
Returns
TypeDescription
Entity

newBuilder(Entity copyFrom)

public static Entity.Builder newBuilder(Entity copyFrom)
Parameter
NameDescription
copyFromEntity
Returns
TypeDescription
Entity.Builder

newBuilder(Key key)

public static Entity.Builder newBuilder(Key key)
Parameter
NameDescription
keyKey
Returns
TypeDescription
Entity.Builder

newBuilder(Key key, FullEntity<?> copyFrom)

public static Entity.Builder newBuilder(Key key, FullEntity<?> copyFrom)
Parameters
NameDescription
keyKey
copyFromFullEntity<?>
Returns
TypeDescription
Entity.Builder