Package org.bson.codecs.pojo
Interface InstanceCreator<T>
- Type Parameters:
T
- the type of the class
public interface InstanceCreator<T>
Provides access for setting data and the creation of a class instances.
- Since:
- 3.5
-
Method Summary
Modifier and TypeMethodDescriptionReturns the new instance of the class.<S> void
set
(S value, PropertyModel<S> propertyModel) Sets a value for the given PropertyModel
-
Method Details
-
set
Sets a value for the given PropertyModel- Type Parameters:
S
- the PropertyModel's type- Parameters:
value
- the new value for the propertypropertyModel
- the PropertyModel representing the property to set the value for.
-
getInstance
T getInstance()Returns the new instance of the class.Note: This will be called after all the values have been set.
- Returns:
- the new class instance.
-