Ejemplo n.º 1
0
        /// <summary>Configures stored procedure used to insert entities.</summary>
        /// <returns> The same configuration instance so that multiple calls can be chained. </returns>
        /// <param name="modificationStoredProcedureConfigurationAction">A lambda expression that performs configuration for the stored procedure.</param>
        public ConventionModificationStoredProceduresConfiguration Insert(
            Action <ConventionInsertModificationStoredProcedureConfiguration> modificationStoredProcedureConfigurationAction)
        {
            Check.NotNull <Action <ConventionInsertModificationStoredProcedureConfiguration> >(modificationStoredProcedureConfigurationAction, nameof(modificationStoredProcedureConfigurationAction));
            ConventionInsertModificationStoredProcedureConfiguration procedureConfiguration = new ConventionInsertModificationStoredProcedureConfiguration(this._type);

            modificationStoredProcedureConfigurationAction(procedureConfiguration);
            this._configuration.Insert(procedureConfiguration.Configuration);
            return(this);
        }
        /// <summary>Configures stored procedure used to insert entities.</summary>
        /// <returns> The same configuration instance so that multiple calls can be chained. </returns>
        /// <param name="modificationStoredProcedureConfigurationAction">A lambda expression that performs configuration for the stored procedure.</param>
        public ConventionModificationStoredProceduresConfiguration Insert(
            Action <ConventionInsertModificationStoredProcedureConfiguration> modificationStoredProcedureConfigurationAction)
        {
            Check.NotNull(modificationStoredProcedureConfigurationAction, "modificationStoredProcedureConfigurationAction");

            var modificationStoredProcedureConfiguration
                = new ConventionInsertModificationStoredProcedureConfiguration(_type);

            modificationStoredProcedureConfigurationAction(modificationStoredProcedureConfiguration);

            _configuration.Insert(modificationStoredProcedureConfiguration.Configuration);

            return(this);
        }
        /// <summary>Configures stored procedure used to insert entities.</summary>
        /// <returns> The same configuration instance so that multiple calls can be chained. </returns>
        /// <param name="modificationStoredProcedureConfigurationAction">A lambda expression that performs configuration for the stored procedure.</param>
        public ConventionModificationStoredProceduresConfiguration Insert(
            Action<ConventionInsertModificationStoredProcedureConfiguration> modificationStoredProcedureConfigurationAction)
        {
            Check.NotNull(modificationStoredProcedureConfigurationAction, "modificationStoredProcedureConfigurationAction");

            var modificationStoredProcedureConfiguration
                = new ConventionInsertModificationStoredProcedureConfiguration(_type);

            modificationStoredProcedureConfigurationAction(modificationStoredProcedureConfiguration);

            _configuration.Insert(modificationStoredProcedureConfiguration.Configuration);

            return this;
        }