Skip to content

Commit

Permalink
Removed AdjustBatch
Browse files Browse the repository at this point in the history
  • Loading branch information
gliljas committed Jan 6, 2025
1 parent 6bc9761 commit cdf3a4f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 28 deletions.
15 changes: 0 additions & 15 deletions src/NHibernate/Driver/DriverBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -332,7 +332,6 @@ public virtual void AdjustCommand(DbCommand command)
#if NET6_0_OR_GREATER
public void PrepareBatch(DbBatch batch)
{
AdjustBatch(batch);
OnBeforePrepare(batch);

if (SupportsPreparingCommands && prepareSql)
Expand All @@ -350,20 +349,6 @@ protected virtual void OnBeforePrepare(DbBatch command)
{
}

/// <summary>
/// Override to make any adjustments to each DbBatch object before it added to the batcher.
/// </summary>
/// <param name="batch">The batch.</param>
/// <remarks>
/// This method is similar to the <see cref="OnBeforePrepare"/> but, instead be called just before execute the command (that can be a batch)
/// is executed before add each single command to the batcher and before <see cref="OnBeforePrepare"/> .
/// If you have to adjust parameters values/type (when the command is full filled) this is a good place where do it.
/// </remarks>
public virtual void AdjustBatch(DbBatch batch)
{

}

public virtual DbBatch CreateBatch()
{
throw new NotImplementedException();
Expand Down
10 changes: 0 additions & 10 deletions src/NHibernate/Driver/IDriver.cs
Original file line number Diff line number Diff line change
Expand Up @@ -177,16 +177,6 @@ public interface IDriver
/// </summary>
bool CanCreateBatch => false;

/// <summary>
/// Make any adjustments to each <see cref="DbBatch"/> object before it is added to the batcher.
/// </summary>
/// <param name="dbBatch">The batch.</param>
/// <remarks>
/// This method should be executed before adding each single batch to the batcher.
/// If you have to adjust parameters values/type (when the command is fullfilled) this is a good place to do it.
/// </remarks>
void AdjustBatch(DbBatch dbBatch) => throw new NotImplementedException();

/// <summary>
/// Prepare the <paramref name="dbBatch" /> by calling <see cref="DbBatch.Prepare()" />.
/// May be a no-op if the driver does not support preparing commands, or for any other reason.
Expand Down
6 changes: 3 additions & 3 deletions src/NHibernate/Driver/ReflectionBasedDriver.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ public abstract class ReflectionBasedDriver : DriverBase
{
protected const string ReflectionTypedProviderExceptionMessageTemplate =
"The DbCommand and DbConnection implementation in the assembly {0} could not be found. "
+ "Ensure that the assembly {0} is located in the application directory or in the Global "
+ "Assembly Cache. If the assembly is in the GAC, use <qualifyAssembly/> element in the "
+ "application configuration file to specify the full name of the assembly.";
+ "Ensure that the assembly {0} is located in the application directory or in the Global "
+ "Assembly Cache. If the assembly is in the GAC, use <qualifyAssembly/> element in the "
+ "application configuration file to specify the full name of the assembly.";

private readonly IDriveConnectionCommandProvider connectionCommandProvider;

Expand Down

0 comments on commit cdf3a4f

Please sign in to comment.