/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void SchemaConfiguredWarning( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Model.Validation> diagnostics, [NotNull] IEntityType entityType, [NotNull] string schema) { var definition = SqliteResources.LogSchemaConfigured(diagnostics); var warningBehavior = definition.GetLogBehavior(diagnostics); if (warningBehavior != WarningBehavior.Ignore) { definition.Log( diagnostics, warningBehavior, entityType.DisplayName(), schema); } if (diagnostics.DiagnosticSource.IsEnabled(definition.EventId.Name)) { diagnostics.DiagnosticSource.Write( definition.EventId.Name, new EntityTypeSchemaEventData( definition, SchemaConfiguredWarning, entityType, schema)); } }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void SequenceConfiguredWarning( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Model.Validation> diagnostics, [NotNull] ISequence sequence) { var definition = SqliteResources.LogSequenceConfigured(diagnostics); var warningBehavior = definition.GetLogBehavior(diagnostics); if (warningBehavior != WarningBehavior.Ignore) { definition.Log( diagnostics, warningBehavior, sequence.Name); } if (diagnostics.DiagnosticSource.IsEnabled(definition.EventId.Name)) { diagnostics.DiagnosticSource.Write( definition.EventId.Name, new SequenceEventData( definition, SequenceConfiguredWarning, sequence)); } }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void SchemasNotSupportedWarning( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Scaffolding> diagnostics) { var definition = SqliteResources.LogUsingSchemaSelectionsWarning(diagnostics); if (diagnostics.ShouldLog(definition)) { definition.Log(diagnostics); } // No DiagnosticsSource events because these are purely design-time messages }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void ForeignKeyReferencesMissingTableWarning( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Scaffolding> diagnostics, [CanBeNull] string foreignKeyName) { var definition = SqliteResources.LogForeignKeyScaffoldErrorPrincipalTableNotFound(diagnostics); if (diagnostics.ShouldLog(definition)) { definition.Log(diagnostics, foreignKeyName); } // No DiagnosticsSource events because these are purely design-time messages }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void MissingTableWarning( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Scaffolding> diagnostics, [CanBeNull] string tableName) { var definition = SqliteResources.LogMissingTable(diagnostics); if (diagnostics.ShouldLog(definition)) { definition.Log(diagnostics, tableName); } // No DiagnosticsSource events because these are purely design-time messages }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void TableFound( this IDiagnosticsLogger <DbLoggerCategory.Scaffolding> diagnostics, string?tableName) { var definition = SqliteResources.LogFoundTable(diagnostics); if (diagnostics.ShouldLog(definition)) { definition.Log(diagnostics, tableName); } // No DiagnosticsSource events because these are purely design-time messages }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void UniqueConstraintFound( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Scaffolding> diagnostics, [CanBeNull] string uniqueConstraintName, [CanBeNull] string tableName) { var definition = SqliteResources.LogFoundUniqueConstraint(diagnostics); if (diagnostics.ShouldLog(definition)) { definition.Log(diagnostics, uniqueConstraintName, tableName); } // No DiagnosticsSource events because these are purely design-time messages }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void SchemasNotSupportedWarning( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Scaffolding> diagnostics) { var definition = SqliteResources.LogUsingSchemaSelectionsWarning(diagnostics); var warningBehavior = definition.GetLogBehavior(diagnostics); if (warningBehavior != WarningBehavior.Ignore) { definition.Log(diagnostics, warningBehavior); } // No DiagnosticsSource events because these are purely design-time messages }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void ForeignKeyPrincipalColumnMissingWarning( this IDiagnosticsLogger <DbLoggerCategory.Scaffolding> diagnostics, string?foreignKeyName, string?tableName, string?principalColumnName, string?principalTableName) { var definition = SqliteResources.LogPrincipalColumnNotFound(diagnostics); if (diagnostics.ShouldLog(definition)) { definition.Log(diagnostics, foreignKeyName, tableName, principalColumnName, principalTableName); } // No DiagnosticsSource events because these are purely design-time messages }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void ForeignKeyFound( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Scaffolding> diagnostics, [CanBeNull] string tableName, long id, [CanBeNull] string principalTableName, [CanBeNull] string deleteAction) { var definition = SqliteResources.LogFoundForeignKey(diagnostics); if (diagnostics.ShouldLog(definition)) { definition.Log(diagnostics, tableName, id, principalTableName, deleteAction); } // No DiagnosticsSource events because these are purely design-time messages }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void ColumnFound( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Scaffolding> diagnostics, [CanBeNull] string tableName, [CanBeNull] string columnName, [CanBeNull] string dataTypeName, bool notNull, [CanBeNull] string defaultValue) { var definition = SqliteResources.LogFoundColumn(diagnostics); if (diagnostics.ShouldLog(definition)) { definition.Log(diagnostics, tableName, columnName, dataTypeName, notNull, defaultValue); } // No DiagnosticsSource events because these are purely design-time messages }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void MissingTableWarning( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Scaffolding> diagnostics, [CanBeNull] string tableName) { var definition = SqliteResources.LogMissingTable(diagnostics); var warningBehavior = definition.GetLogBehavior(diagnostics); if (warningBehavior != WarningBehavior.Ignore) { definition.Log( diagnostics, warningBehavior, tableName); } // No DiagnosticsSource events because these are purely design-time messages }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void SequenceConfiguredWarning( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Model.Validation> diagnostics, [NotNull] IReadOnlySequence sequence) { var definition = SqliteResources.LogSequenceConfigured(diagnostics); if (diagnostics.ShouldLog(definition)) { definition.Log(diagnostics, sequence.Name); } if (diagnostics.NeedsEventData(definition, out var diagnosticSourceEnabled, out var simpleLogEnabled)) { var eventData = new SequenceEventData( definition, SequenceConfiguredWarning, sequence); diagnostics.DispatchEventData(definition, eventData, diagnosticSourceEnabled, simpleLogEnabled); } }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void UnexpectedConnectionTypeWarning( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Infrastructure> diagnostics, [NotNull] Type connectionType) { var definition = SqliteResources.LogUnexpectedConnectionType(diagnostics); if (diagnostics.ShouldLog(definition)) { definition.Log(diagnostics, connectionType.ShortDisplayName()); } if (diagnostics.NeedsEventData(definition, out var diagnosticSourceEnabled, out var simpleLogEnabled)) { var eventData = new UnexpectedConnectionTypeEventData( definition, UnexpectedConnectionTypeWarning, connectionType); diagnostics.DispatchEventData(definition, eventData, diagnosticSourceEnabled, simpleLogEnabled); } }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void ForeignKeyPrincipalColumnMissingWarning( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Scaffolding> diagnostics, [CanBeNull] string foreignKeyName, [CanBeNull] string tableName, [CanBeNull] string principalColumnName, [CanBeNull] string principalTableName) { var definition = SqliteResources.LogPrincipalColumnNotFound(diagnostics); var warningBehavior = definition.GetLogBehavior(diagnostics); if (warningBehavior != WarningBehavior.Ignore) { definition.Log( diagnostics, warningBehavior, foreignKeyName, tableName, principalColumnName, principalTableName); } // No DiagnosticsSource events because these are purely design-time messages }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void TableRebuildPendingWarning( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Migrations> diagnostics, [NotNull] Type operationType, [NotNull] string tableName) { var definition = SqliteResources.LogTableRebuildPendingWarning(diagnostics); if (diagnostics.ShouldLog(definition)) { definition.Log(diagnostics, operationType.ShortDisplayName(), tableName); } if (diagnostics.NeedsEventData(definition, out var diagnosticSourceEnabled, out var simpleLogEnabled)) { var eventData = new TableRebuildEventData( definition, TableRebuildPendingWarning, operationType, tableName); diagnostics.DispatchEventData(definition, eventData, diagnosticSourceEnabled, simpleLogEnabled); } }
/// <summary> /// This is an internal API that supports the Entity Framework Core infrastructure and not subject to /// the same compatibility standards as public APIs. It may be changed or removed without notice in /// any release. You should only use it directly in your code with extreme caution and knowing that /// doing so can result in application failures when updating to a new Entity Framework Core release. /// </summary> public static void SchemaConfiguredWarning( [NotNull] this IDiagnosticsLogger <DbLoggerCategory.Model.Validation> diagnostics, [NotNull] IEntityType entityType, [NotNull] string schema) { var definition = SqliteResources.LogSchemaConfigured(diagnostics); if (diagnostics.ShouldLog(definition)) { definition.Log(diagnostics, entityType.DisplayName(), schema); } if (diagnostics.NeedsEventData(definition, out var diagnosticSourceEnabled, out var simpleLogEnabled)) { var eventData = new EntityTypeSchemaEventData( definition, SchemaConfiguredWarning, entityType, schema); diagnostics.DispatchEventData(definition, eventData, diagnosticSourceEnabled, simpleLogEnabled); } }