annotate Agendas/trunk/src/Agendas.Twitter/TwitterStringHelper.cs @ 228:9f61e8555114

Nombrando a todos los ponentes en los twitter y partiendo los mensajes que superan el máximo permitido
author nelopauselli
date Wed, 28 Sep 2011 18:51:53 -0300
parents c4c60e034103
children e5959f3405e0
rev   line source
217
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
1 using System;
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
2 using AltNetHispano.Agendas.Domain;
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
3
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
4 namespace AltNetHispano.Agendas.Twitter
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
5 {
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
6 public static class TwitterStringHelper
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
7 {
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
8 public static string TipoEvento(TipoEvento tipo)
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
9 {
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
10 switch (tipo)
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
11 {
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
12 case Domain.TipoEvento.Van:
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
13 return "La VAN";
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
14 case Domain.TipoEvento.Cafe:
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
15 return "El " + tipo;
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
16 case Domain.TipoEvento.GrupoEstudio:
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
17 return "El Grupo de estudio";
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
18 default:
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
19 return string.Empty;
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
20 }
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
21 }
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
22
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
23 public static string Ponente(Persona ponente)
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
24 {
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
25 return "@"+ponente.Twitter;
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
26 }
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
27
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
28 public static string Hora(DateTime fechaInicio)
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
29 {
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
30 return fechaInicio.Minute == 0 ? fechaInicio.Hour + "GMT" : fechaInicio.Hour + ":" + fechaInicio.Minute + "GMT";
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
31 }
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
32 }
c4c60e034103 sugerencia de recordatorios
nelopauselli
parents:
diff changeset
33 }