comparison Agendas/trunk/src/Agendas.Repositories.Memory/EventoRepository.cs @ 137:2d1adbaf0373

CRUD de Patrocinador
author nelopauselli
date Thu, 28 Jul 2011 09:26:24 -0300
parents 462a78196d11
children 3639803112c6
comparison
equal deleted inserted replaced
136:462a78196d11 137:2d1adbaf0373
16 public IList<Evento> GetByState(EventoState state) 16 public IList<Evento> GetByState(EventoState state)
17 { 17 {
18 return Objects.Values.Where(e => e.Estado == state.GetDescripcion()).ToList(); 18 return Objects.Values.Where(e => e.Estado == state.GetDescripcion()).ToList();
19 } 19 }
20 20
21 public void Delete(Evento evento)
22 {
23 Objects.Remove(evento.Id);
24 }
25
26 public Evento Get(Guid vanId)
27 {
28 Evento evento;
29 return Objects.TryGetValue(vanId, out evento) ? evento : null;
30 }
31
32 public IList<Evento> GetActivos() 21 public IList<Evento> GetActivos()
33 { 22 {
34 return 23 return
35 Objects.Values.Where( 24 Objects.Values.Where(
36 e => 25 e =>