Пример #1
0
 /// <summary>
 ///     This API supports the Entity Framework Core infrastructure and is not intended to be used
 ///     directly from your code. This API may change or be removed in future releases.
 /// </summary>
 protected virtual void MergeAnnotationsFrom([NotNull] ConventionalAnnotatable annotatable)
 {
     foreach (var annotation in annotatable.GetAnnotations())
     {
         HasAnnotation(
             annotation.Name,
             annotation.Value,
             annotation.GetConfigurationSource(),
             canOverrideSameSource: false);
     }
 }
Пример #2
0
 /// <summary>
 ///     This API supports the Entity Framework Core infrastructure and is not intended to be used
 ///     directly from your code. This API may change or be removed in future releases.
 /// </summary>
 public virtual void MergeAnnotationsFrom(
     [NotNull] ConventionalAnnotatable annotatable,
     ConfigurationSource minimalConfigurationSource)
 {
     foreach (var annotation in annotatable.GetAnnotations())
     {
         var configurationSource = annotation.GetConfigurationSource();
         if (configurationSource.Overrides(minimalConfigurationSource))
         {
             HasAnnotation(
                 annotation.Name,
                 annotation.Value,
                 configurationSource,
                 canOverrideSameSource: false);
         }
     }
 }
Пример #3
0
 /// <summary>
 ///     This API supports the Entity Framework Core infrastructure and is not intended to be used
 ///     directly from your code. This API may change or be removed in future releases.
 /// </summary>
 protected InternalMetadataBuilder([NotNull] ConventionalAnnotatable metadata)
 {
     Metadata = metadata;
 }
Пример #4
0
 /// <summary>
 ///     This API supports the Entity Framework Core infrastructure and is not intended to be used
 ///     directly from your code. This API may change or be removed in future releases.
 /// </summary>
 public virtual void MergeAnnotationsFrom([NotNull] ConventionalAnnotatable annotatable)
 => MergeAnnotationsFrom(annotatable, ConfigurationSource.Explicit);