Repository

A base interface describing the basic operations that can be performed on a database.

Members

Functions

close
void close()

Closes the database.

find
Optional!Entity find(PrimaryKeyType!Entity id)

Finds an entity by its primary key.

findAll
Entity[] findAll()

Returns a list of all entities in the repository.

remove
void remove(PrimaryKeyType!Entity id)

Removes an entity by its primary key.

remove
void remove(Entity entity)

Removes an entity.

save
Entity save(Entity entity)

Saves the entity in the repository. This should be called to add a new entity or to update a modified entity.

Meta