To create an entity manager instance and use the methods bellow:
let manager = wetland.getManager(); `
Returns an entity repository instance for provided entity.
Note: If you're planning on doing work with the unit of work (
EntityManager.createScope()) you must use the scope to get the repository.
Repositories fetched from the entity manager are a more performant way of querying the database, but they're never linked to a scope. If all you're planning on doing is fetching data or performing simple queries, this method is for you.
The queries performed on a repository fetched from the EntityManager do run in an internal scope, so they're safe to use in for example APIs.
Get the mapping for provided entity. Can be an instance, constructor or the name of the entity.