Example #1
0
        public TEntity Get(TId id)
        {
            // get the entity from the actual storage
            // cast or convert the entity
            var dataItem = DataStore.Get(id);

            return(EntityMapperFactory.ResolveMapper <TDataStoreEntity, TEntity>().Map(dataItem));
        }
Example #2
0
        public IEnumerable <TEntity> Get(IEnumerable <TId> ids = null)
        {
            var dataItems = DataStore.Get(ids);

            return(EntityMapperFactory.ResolveMapper <TDataStoreEntity, TEntity>().MapMany(dataItems));
        }