Mercurial > altnet-hispano
comparison Agendas/trunk/src/Agendas.Factories/AgendaFactory.cs @ 19:74eb4577d447
HttpContext identity provider
Requerimiento de autenticación para registrar un nuevo evento o modificar uno existente
author | nelo@MTEySS.neluz.int |
---|---|
date | Mon, 14 Mar 2011 00:35:43 -0300 |
parents | 08b9e96132a5 |
children | 41b283d27e3e |
comparison
equal
deleted
inserted
replaced
18:8ed4a806ebe0 | 19:74eb4577d447 |
---|---|
3 | 3 |
4 namespace Agendas.Factories | 4 namespace Agendas.Factories |
5 { | 5 { |
6 public static class AgendaFactory | 6 public static class AgendaFactory |
7 { | 7 { |
8 private static readonly Agenda Agenda = new Agenda(null, null, null, new EventoRepository()); | 8 private static Agenda _agenda; |
9 private static ISeguridad _seguridad; | |
9 | 10 |
10 public static Agenda GetAgenda() | 11 public static Agenda GetAgenda() |
11 { | 12 { |
12 return Agenda; | 13 if (_agenda==null) |
14 _agenda = new Agenda(null, null, _seguridad, new EventoRepository()); | |
15 | |
16 return _agenda; | |
13 } | 17 } |
18 | |
19 public static void SetIdentityProvider(ISeguridad seguridad) | |
20 { | |
21 _seguridad = seguridad; | |
22 } | |
14 } | 23 } |
15 } | 24 } |