Search Results for

    Show / Hide Table of Contents

    Class NullableAttribute

    Explicitly specifies that associated column could contain NULL values. Overrides default nullability flag from current mapping schema for property/field type. Has lower priority over CanBeNull. Using this attribute, you can allow NULL values for identity columns.

    Inheritance
    System.Object
    MappingAttribute
    NullableAttribute
    NotNullAttribute
    Namespace: LinqToDB.Mapping
    Assembly: linq2db.dll
    Syntax
    public class NullableAttribute : MappingAttribute

    Constructors

    | Improve this Doc View Source

    NullableAttribute()

    Creates attribute isntance.

    Declaration
    public NullableAttribute()
    | Improve this Doc View Source

    NullableAttribute(Boolean)

    Creates attribute isntance.

    Declaration
    public NullableAttribute(bool isNullable)
    Parameters
    Type Name Description
    System.Boolean isNullable

    Nullability flag for current column.

    | Improve this Doc View Source

    NullableAttribute(String, Boolean)

    Creates attribute isntance.

    Declaration
    public NullableAttribute(string configuration, bool isNullable)
    Parameters
    Type Name Description
    System.String configuration

    Mapping schema configuration name. See Configuration.

    System.Boolean isNullable

    Nullability flag for current column.

    Properties

    | Improve this Doc View Source

    CanBeNull

    Gets or sets nullability flag for current column. Default value: true.

    Declaration
    public bool CanBeNull { get; set; }
    Property Value
    Type Description
    System.Boolean
    | Improve this Doc View Source

    Configuration

    Gets or sets mapping schema configuration name, for which this attribute should be taken into account. ProviderName for standard names. Attributes with null or empty string Configuration value applied to all configurations (if no attribute found for current configuration).

    Declaration
    public string? Configuration { get; set; }
    Property Value
    Type Description
    System.Nullable<System.String>

    Methods

    | Improve this Doc View Source

    GetObjectID()

    Declaration
    public override string GetObjectID()
    Returns
    Type Description
    System.String
    Overrides
    MappingAttribute.GetObjectID()

    Extension Methods

    Map.DeepCopy<T>(T)
    Sql.IsDistinctFrom<T>(T, T)
    Sql.IsNotDistinctFrom<T>(T, T)
    SqlExtensions.In<T>(T, IEnumerable<T>)
    SqlExtensions.In<T>(T, IQueryable<T>)
    SqlExtensions.In<T>(T, T[])
    SqlExtensions.In<T>(T, T, T)
    SqlExtensions.In<T>(T, T, T, T)
    SqlExtensions.NotIn<T>(T, IEnumerable<T>)
    SqlExtensions.NotIn<T>(T, IQueryable<T>)
    SqlExtensions.NotIn<T>(T, T[])
    SqlExtensions.NotIn<T>(T, T, T)
    SqlExtensions.NotIn<T>(T, T, T, T)
    • Improve this Doc
    • View Source
    In This Article
    Back to top Copyright © 2011-2022 linq2db.com

    Generated by DocFX