klyn.data.memory.MemoryRepository.MemoryRepository
constructor

    public MemoryRepository(values as IList<T>):

Description

Creates a validated read-only repository.

Parameters

Parameter | Description
--- | ---
`values` | Existing entity rows wrapped by the repository.

Throws

- EntityMappingException if T has no unique mapped `@Id` property.
- DuplicateIdentityException on the first duplicate identity.

Example

    repository = MemoryRepository<User, Int>(users)