예제 #1
0
        /// <summary>
        /// Executes actions that configure reader settings.
        /// </summary>
        /// <param name="readerSettings">The reader settings.</param>
        internal void ExecuteReaderSettingsConfiguration(ODataMessageReaderSettings readerSettings)
        {
            Debug.Assert(readerSettings != null, "readerSettings != null");

            if (this.messageReaderSettingsConfigurationActions.Count > 0)
            {
                MessageReaderSettingsArgs args = new MessageReaderSettingsArgs(readerSettings);
                foreach (Action <MessageReaderSettingsArgs> readerSettingsConfigurationAction in this.messageReaderSettingsConfigurationActions)
                {
                    readerSettingsConfigurationAction(args);
                }
            }
        }
        /// <summary>
        /// Executes actions that configure reader settings.
        /// </summary>
        /// <param name="readerSettings">The reader settings.</param>
        internal void ExecuteReaderSettingsConfiguration(ODataMessageReaderSettingsBase readerSettings)
        {
            Debug.Assert(readerSettings != null, "readerSettings != null");

            if (this.messageReaderSettingsConfigurationActions.Count > 0)
            {
                MessageReaderSettingsArgs args = new MessageReaderSettingsArgs(new DataServiceClientMessageReaderSettingsShim(readerSettings));
                foreach (Action<MessageReaderSettingsArgs> readerSettingsConfigurationAction in this.messageReaderSettingsConfigurationActions)
                {
                    readerSettingsConfigurationAction(args);
                }
            }
        }