abstract fun new(id: K, factory: () -> T): T Creates a new entity in storage with the given identifier.
Return
The created entity.
The unique identifier for the entity.
A lambda that produces the initial entity when called.
if an entity with the given id already exists.