annotate 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
rev   line source
15
08b9e96132a5 Persistimos los eventos de la agenda
nelo@MTEySS.neluz.int
parents:
diff changeset
1 using Agendas.Repositories.Memory;
08b9e96132a5 Persistimos los eventos de la agenda
nelo@MTEySS.neluz.int
parents:
diff changeset
2 using AltNetHispano.Agendas.Domain;
08b9e96132a5 Persistimos los eventos de la agenda
nelo@MTEySS.neluz.int
parents:
diff changeset
3
08b9e96132a5 Persistimos los eventos de la agenda
nelo@MTEySS.neluz.int
parents:
diff changeset
4 namespace Agendas.Factories
08b9e96132a5 Persistimos los eventos de la agenda
nelo@MTEySS.neluz.int
parents:
diff changeset
5 {
08b9e96132a5 Persistimos los eventos de la agenda
nelo@MTEySS.neluz.int
parents:
diff changeset
6 public static class AgendaFactory
08b9e96132a5 Persistimos los eventos de la agenda
nelo@MTEySS.neluz.int
parents:
diff changeset
7 {
19
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
8 private static Agenda _agenda;
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
9 private static ISeguridad _seguridad;
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
10
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
11 public static Agenda GetAgenda()
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
12 {
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
13 if (_agenda==null)
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
14 _agenda = new Agenda(null, null, _seguridad, new EventoRepository());
15
08b9e96132a5 Persistimos los eventos de la agenda
nelo@MTEySS.neluz.int
parents:
diff changeset
15
19
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
16 return _agenda;
15
08b9e96132a5 Persistimos los eventos de la agenda
nelo@MTEySS.neluz.int
parents:
diff changeset
17 }
19
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
18
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
19 public static void SetIdentityProvider(ISeguridad seguridad)
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
20 {
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
21 _seguridad = seguridad;
74eb4577d447 HttpContext identity provider
nelo@MTEySS.neluz.int
parents: 15
diff changeset
22 }
15
08b9e96132a5 Persistimos los eventos de la agenda
nelo@MTEySS.neluz.int
parents:
diff changeset
23 }
08b9e96132a5 Persistimos los eventos de la agenda
nelo@MTEySS.neluz.int
parents:
diff changeset
24 }