comparison Agendas/trunk/src/Agendas.Domain/EventoPublicadoState.cs @ 101:9bfdd5bf3ad2

Manejo de estados de los Eventos mediante state pattern (primer version)
author jorge.rowies
date Sun, 05 Jun 2011 11:10:32 -0300
parents
children 23325dddddcc
comparison
equal deleted inserted replaced
100:cc91817a4206 101:9bfdd5bf3ad2
1 using AltNetHispano.Agendas.Domain.Exceptions;
2
3 namespace AltNetHispano.Agendas.Domain
4 {
5 public class EventoPublicadoState : EventoState
6 {
7 private readonly Evento _evento;
8
9 public EventoPublicadoState(Evento evento)
10 {
11 _evento = evento;
12 _evento.AddTrack(new Track(_evento, Accion.Publicar));
13 }
14
15 public override void Promover(Accion accion)
16 {
17 throw new AccionNoSoportadaException(this.GetType(), accion);
18 }
19 }
20 }