Package dev.morphia.mapping.experimental
Class SetReference<T>
- java.lang.Object
-
- dev.morphia.mapping.experimental.MorphiaReference<C>
-
- dev.morphia.mapping.experimental.CollectionReference<Set<T>>
-
- dev.morphia.mapping.experimental.SetReference<T>
-
- Type Parameters:
T
-
public class SetReference<T> extends CollectionReference<Set<T>>
Developer note.This is an internal item. Its function and presence are subject to change without warning. Its use is highly discouraged.
-
-
Constructor Summary
Constructors Constructor Description SetReference(Datastore datastore, EntityModel entityModel, List ids)
SetReference(Set<T> values)
Creates an instance with prepopulated values.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Set<T>
get()
Gets the referenced entities.protected void
setValues(List ids)
-
Methods inherited from class dev.morphia.mapping.experimental.CollectionReference
getIds, getType
-
Methods inherited from class dev.morphia.mapping.experimental.MorphiaReference
equals, hashCode, ignoreMissing, ignoreMissing, isResolved, resolve, toString, wrap
-
-
-
-
Constructor Detail
-
SetReference
public SetReference(Datastore datastore, EntityModel entityModel, List ids)
- Parameters:
datastore
- the datastore to useentityModel
- the entity's mapped classids
- the IDs
Developer note.This is an internal item. Its function and presence are subject to change without warning. Its use is highly discouraged.
-
-
Method Detail
-
setValues
protected void setValues(List ids)
-
get
public Set<T> get()
Description copied from class:CollectionReference
Gets the referenced entities. This may require at least one request to the server.- Specified by:
get
in classCollectionReference<Set<T>>
- Returns:
- the referenced entities
-
-