/// <summary>
        /// Gets the provider as editable.
        /// </summary>
        /// <returns></returns>
        /// <exception cref="System.NotSupportedException"></exception>
        protected IEditableProvider <T> GetProviderAsEditable()
        {
            IEditableProvider <T> ret = null;

            if (this.Provider != null)
            {
                ret = this.Provider as IEditableProvider <T>;
            }
            else
            {
                ret = this.ProviderAsync as IEditableProvider <T>;
            }

            return(ret);
        }
        /// <summary>
        /// Gets the provider as editable.
        /// </summary>
        /// <returns></returns>
        /// <exception cref="System.NotSupportedException"></exception>
        protected IEditableProvider <T> GetProviderAsEditable()
        {
            IEditableProvider <T> ret = null;

            if (this.Provider != null)
            {
                ret = this.Provider as IEditableProvider <T>;
            }
            else
            {
                ret = this.ProviderAsync as IEditableProvider <T>;
            }

            if (ret == null)
            {
                throw new NotSupportedException();
            }

            return(ret);
        }