Ejemplo n.º 1
0
        /// <summary>
        /// Adds a converter (to sanatize the initial response) for a given type to the list of converters.
        /// </summary>
        /// <param name="type">The type which should use the converter.</param>
        /// <param name="function">The delegate to your converter.</param>
        /// <returns>The current instance.</returns>
        public AjaxRequestOptions AddConverter(AjaxDataType type, AjaxFilterHandler function)
        {
            if (filters.ContainsKey(type))
            {
                filters[type] = function;
            }
            else
            {
                filters.Add(type, function);
            }

            return(this);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Adds a converter (to sanatize the initial response) for a given type to the list of converters.
        /// </summary>
        /// <param name="type">The type which should use the converter.</param>
        /// <param name="function">The delegate to your converter.</param>
        /// <returns>The current instance.</returns>
        public AjaxRequestOptions AddConverter(AjaxDataType type, AjaxFilterHandler function)
        {
            if (filters.ContainsKey(type))
                filters[type] = function;
            else
                filters.Add(type, function);

            return this;
        }