public class CollectionTranslatorFactory extends Object implements TranslatorFactory<Collection<Object>>
Translator which can load things into a collection field. Might be embedded items, might not.
Note that empty or null collections are not stored in the datastore, and null values for the collection field are ignored when they are loaded from the Entity. This is because the datastore doesn't store empty collections, and storing null fields will confuse filtering for actual nulls in the collection contents.
Modifier and Type | Class and Description |
---|---|
static class |
CollectionTranslatorFactory.CollectionListNodeTranslator |
Constructor and Description |
---|
CollectionTranslatorFactory() |
public Translator<Collection<Object>> create(Path path, Property property, Type type, CreateContext ctx)
create
in interface TranslatorFactory<Collection<Object>>
path
- current path to this part of the tree, important for logging and exceptionsproperty
- is the property we are inspecting to create a translator fortype
- is the generic type of the field (or field component). For example, examining a field of type
ListCopyright © 2014. All rights reserved.