/// <summary> /// Traduce los argumentos seleccionados del GroupBox filtro a un diccionario /// </summary> /// <returns>Arguementos para filtrar los Elementos a mostrar</returns> private Dictionary <Type, Object> ArgumentosSelccionados() { Dictionary <Type, object> argumentos = new Dictionary <Type, object>(); string nombre = ""; if (this.checkBox_Nombre.Checked) { nombre = this.textBox_Nombre.Text; } argumentos.Add(nombre.GetType(), nombre); if (this.checkBox_Tipo.Checked) { IFuente fuenteTipo; if (this.radioButton_RSS.Checked) { fuenteTipo = new FuenteRSS(); } else { fuenteTipo = new FuenteTextoFijo(); } argumentos.Add(typeof(IFuente), fuenteTipo); } if (this.checkBox_RangoFechas.Checked) { RangoFecha pRangoFecha = new RangoFecha() { FechaInicio = this.dateTimePicker_FechaDesde.Value, FechaFin = this.dateTimePicker_FechaHasta.Value }; argumentos.Add(pRangoFecha.GetType(), pRangoFecha); } return(argumentos); }
/// <summary> /// Devuelve los argumentos corresponientes para obtener los objetos del día de hoy /// </summary> /// <returns>Tipo de dato Dictionary que representa los argumentos para filtrar</returns> private Dictionary <Type, object> ArgumentosHoy() { Dictionary <Type, object> argumentos = new Dictionary <Type, object>(); argumentos.Add(typeof(string), ""); RangoFecha pRangoFecha = new RangoFecha() { FechaInicio = this.dateTimePicker_FechaDesde.Value, FechaFin = this.dateTimePicker_FechaHasta.Value }; argumentos.Add(pRangoFecha.GetType(), pRangoFecha); return(argumentos); }
/// <summary> /// Traduce los argumentos seleccionados del GroupBox filtro a un diccionario /// </summary> /// <returns>Arguementos para filtrar los Elementos a mostrar</returns> private Dictionary <Type, Object> ArgumentosSelccionados() { Dictionary <Type, object> argumentos = new Dictionary <Type, object>(); string nombre = ""; if (this.checkBox_Nombre.Checked) { nombre = this.textBox_Nombre.Text; } argumentos.Add(nombre.GetType(), nombre); if (this.checkBox_RangoFechas.Checked) { RangoFecha pRangoFecha = new RangoFecha() { FechaInicio = this.dateTimePicker_FechaDesde.Value, FechaFin = this.dateTimePicker_FechaHasta.Value }; argumentos.Add(pRangoFecha.GetType(), pRangoFecha); } return(argumentos); }