-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add CommandSource to CommandEventData (#24421)
* Add CommandSource to CommandEventData * Create constructor overload for CommandEventData and its subclasses * Move CommandSource to RelationalCommandParameterObject * Make CommandSource virtual * Updated interceptor tests to assert CommandSource property * Add CommandSource to CommandCreating event * Comment CommandSource assertion * Comment all CommandSource assertions * Obsolete constructor overloads that do not have CommandSource parameter * Change command source values
- Loading branch information
Showing
28 changed files
with
581 additions
and
82 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
// Copyright (c) .NET Foundation. All rights reserved. | ||
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. | ||
|
||
using System.Data.Common; | ||
|
||
namespace Microsoft.EntityFrameworkCore.Diagnostics | ||
{ | ||
/// <summary> | ||
/// Enum used by <see cref="CommandEventData" />, and subclasses to indicate the | ||
/// source of the <see cref="DbCommand" /> being used to execute the command. | ||
/// </summary> | ||
public enum CommandSource | ||
{ | ||
/// <summary> | ||
/// Unknown | ||
/// </summary> | ||
Unknown, | ||
|
||
/// <summary> | ||
/// Linq Query | ||
/// </summary> | ||
LinqQuery, | ||
|
||
/// <summary> | ||
/// Save Changes | ||
/// </summary> | ||
SaveChanges, | ||
|
||
/// <summary> | ||
/// Migrations | ||
/// </summary> | ||
Migrations, | ||
|
||
/// <summary> | ||
/// FromSqlQuery | ||
/// </summary> | ||
FromSqlQuery, | ||
|
||
/// <summary> | ||
/// ExecuteSqlRaw | ||
/// </summary> | ||
ExecuteSqlRaw, | ||
|
||
/// <summary> | ||
/// ValueGenerator | ||
/// </summary> | ||
ValueGenerator, | ||
|
||
/// <summary> | ||
/// Scaffolding | ||
/// </summary> | ||
Scaffolding, | ||
|
||
/// <summary> | ||
/// BulkUpdate | ||
/// </summary> | ||
BulkUpdate | ||
} | ||
} |
Oops, something went wrong.