src/Shared/EntityFramework/ModelConfiguration/Edm/MetadataPropertyExtensions.cs
// <summary>
// Removes an annotation from a set of properties.
// </summary>
// <param name="metadataProperties">The properties.</param>
// <param name="name">The name of the annotation.</param>
Removes an annotation from a set of properties.
Removes an annotation from a set of properties .
public static void RemoveAnnotation(this ICollection<MetadataProperty> metadataProperties, string name)
        {
            DebugCheck.NotNull(metadataProperties);
            DebugCheck.NotEmpty(name);
            var property =
                metadataProperties.SingleOrDefault(p => p.Name.Equals(name, StringComparison.Ordinal));
            if (property != null)
            {
                Debug.Assert(property.IsAnnotation);
                metadataProperties.Remove(property);
            }
        }
public static void RemoveAnnotation ( this ICollection < MetadataProperty > metadataProperties , string name ) { DebugCheck . NotNull ( metadataProperties ) ; DebugCheck . NotEmpty ( name ) ; var property = metadataProperties . SingleOrDefault ( p => p . Name . Equals ( name , StringComparison . Ordinal ) ) ; if ( property != null ) { Debug . Assert ( property . IsAnnotation ) ; metadataProperties . Remove ( property ) ; } }
Removes an annotation from a set of properties.
Removes an annotation from a set of properties .
ICollection<MetadataProperty>
this
name
string
The name of the annotation.
The name of the annotation .
metadataProperties
None