RelationalTypeMapperExtensions.GetMapping Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
GetMapping(IRelationalTypeMapper, IProperty) |
Obsolete.
Gets the relational database type for a given property, throwing if no mapping is found. |
GetMapping(IRelationalTypeMapper, String) |
Obsolete.
Gets the mapping that represents the given database type, throwing if no mapping is found. Note that sometimes the same store type can have different mappings; this method returns the default. |
GetMapping(IRelationalTypeMapper, Type) |
Obsolete.
Gets the relational database type for a given .NET type, throwing if no mapping is found. |
GetMapping(IRelationalTypeMapper, IProperty)
Caution
Use IRelationalTypeMappingSource instead.
Gets the relational database type for a given property, throwing if no mapping is found.
public static Microsoft.EntityFrameworkCore.Storage.RelationalTypeMapping GetMapping (this Microsoft.EntityFrameworkCore.Storage.IRelationalTypeMapper typeMapper, Microsoft.EntityFrameworkCore.Metadata.IProperty property);
[System.Obsolete("Use IRelationalTypeMappingSource instead.")]
public static Microsoft.EntityFrameworkCore.Storage.RelationalTypeMapping GetMapping (this Microsoft.EntityFrameworkCore.Storage.IRelationalTypeMapper typeMapper, Microsoft.EntityFrameworkCore.Metadata.IProperty property);
static member GetMapping : Microsoft.EntityFrameworkCore.Storage.IRelationalTypeMapper * Microsoft.EntityFrameworkCore.Metadata.IProperty -> Microsoft.EntityFrameworkCore.Storage.RelationalTypeMapping
[<System.Obsolete("Use IRelationalTypeMappingSource instead.")>]
static member GetMapping : Microsoft.EntityFrameworkCore.Storage.IRelationalTypeMapper * Microsoft.EntityFrameworkCore.Metadata.IProperty -> Microsoft.EntityFrameworkCore.Storage.RelationalTypeMapping
<Extension()>
Public Function GetMapping (typeMapper As IRelationalTypeMapper, property As IProperty) As RelationalTypeMapping
Parameters
- typeMapper
- IRelationalTypeMapper
The type mapper.
- property
- IProperty
The property to get the mapping for.
Returns
The type mapping to be used.
- Attributes
Applies to
GetMapping(IRelationalTypeMapper, String)
Caution
Use IRelationalTypeMappingSource instead.
Gets the mapping that represents the given database type, throwing if no mapping is found.
Note that sometimes the same store type can have different mappings; this method returns the default.
public static Microsoft.EntityFrameworkCore.Storage.RelationalTypeMapping GetMapping (this Microsoft.EntityFrameworkCore.Storage.IRelationalTypeMapper typeMapper, string typeName);
[System.Obsolete("Use IRelationalTypeMappingSource instead.")]
public static Microsoft.EntityFrameworkCore.Storage.RelationalTypeMapping GetMapping (this Microsoft.EntityFrameworkCore.Storage.IRelationalTypeMapper typeMapper, string typeName);
static member GetMapping : Microsoft.EntityFrameworkCore.Storage.IRelationalTypeMapper * string -> Microsoft.EntityFrameworkCore.Storage.RelationalTypeMapping
[<System.Obsolete("Use IRelationalTypeMappingSource instead.")>]
static member GetMapping : Microsoft.EntityFrameworkCore.Storage.IRelationalTypeMapper * string -> Microsoft.EntityFrameworkCore.Storage.RelationalTypeMapping
<Extension()>
Public Function GetMapping (typeMapper As IRelationalTypeMapper, typeName As String) As RelationalTypeMapping
Parameters
- typeMapper
- IRelationalTypeMapper
The type mapper.
- typeName
- String
The type to get the mapping for.
Returns
The type mapping to be used.
- Attributes
Applies to
GetMapping(IRelationalTypeMapper, Type)
Caution
Use IRelationalTypeMappingSource instead.
Gets the relational database type for a given .NET type, throwing if no mapping is found.
public static Microsoft.EntityFrameworkCore.Storage.RelationalTypeMapping GetMapping (this Microsoft.EntityFrameworkCore.Storage.IRelationalTypeMapper typeMapper, Type clrType);
[System.Obsolete("Use IRelationalTypeMappingSource instead.")]
public static Microsoft.EntityFrameworkCore.Storage.RelationalTypeMapping GetMapping (this Microsoft.EntityFrameworkCore.Storage.IRelationalTypeMapper typeMapper, Type clrType);
static member GetMapping : Microsoft.EntityFrameworkCore.Storage.IRelationalTypeMapper * Type -> Microsoft.EntityFrameworkCore.Storage.RelationalTypeMapping
[<System.Obsolete("Use IRelationalTypeMappingSource instead.")>]
static member GetMapping : Microsoft.EntityFrameworkCore.Storage.IRelationalTypeMapper * Type -> Microsoft.EntityFrameworkCore.Storage.RelationalTypeMapping
<Extension()>
Public Function GetMapping (typeMapper As IRelationalTypeMapper, clrType As Type) As RelationalTypeMapping
Parameters
- typeMapper
- IRelationalTypeMapper
The type mapper.
- clrType
- Type
The type to get the mapping for.
Returns
The type mapping to be used.
- Attributes
Applies to
Entity Framework
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for