root/trunk/eCard/eCardMVC/Platnosci.Core/Interface/IRepository.cs @ 866

Wersja 866, 0.9 KB (wprowadzona przez alina, 16 years temu)

re #215

Line 
1using System;
2using System.Collections.Generic;
3using System.Linq;
4using System.Linq.Expressions;
5using System.Text;
6
7namespace Platnosci.Core.Interface
8{
9    public interface IRepository<T> where T : IIdentifiable
10    {
11        int Count();
12
13        int Count(Expression<Func<T, bool>> expression);
14
15        void Insert(T entity);
16
17        void Delete(T entity);
18
19        void Update(T entity);
20
21        T FindOne(int id);
22
23        T FindOne(Expression<Func<T, bool>> expression);
24
25        bool TryFindOne(Expression<Func<T, bool>> expression, out T entity);
26
27        bool Exists(Expression<Func<T, bool>> expression);
28
29        IList<T> FindAll();
30
31        IList<T> FindAll(Expression<Func<T, bool>> expression);
32
33        IQueryable<T> Find();
34
35        IQueryable<T> Find(int id);
36
37        IQueryable<T> Find(Expression<Func<T, bool>> expression);
38    }
39}
Notatka: Zobacz TracBrowser aby uzyskać więcej informacji.