ColumnBuilder.Geography 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
Geography(Nullable<Boolean>, DbGeography, String, String, String) |
Creates a new column definition to store geography data. |
Geography(Nullable<Boolean>, DbGeography, String, String, String, IDictionary<String,AnnotationValues>) |
Creates a new column definition to store geography data. Entity Framework Migrations APIs are not designed to accept input provided by untrusted sources (such as the end user of an application). If input is accepted from such sources it should be validated before being passed to these APIs to protect against SQL injection attacks etc. |
Geography(Nullable<Boolean>, DbGeography, String, String, String)
Creates a new column definition to store geography data.
public System.Data.Entity.Migrations.Model.ColumnModel Geography (Nullable<bool> nullable = null, System.Data.Spatial.DbGeography defaultValue = null, string defaultValueSql = null, string name = null, string storeType = null);
member this.Geography : Nullable<bool> * System.Data.Spatial.DbGeography * string * string * string -> System.Data.Entity.Migrations.Model.ColumnModel
Public Function Geography (Optional nullable As Nullable(Of Boolean) = null, Optional defaultValue As DbGeography = null, Optional defaultValueSql As String = null, Optional name As String = null, Optional storeType As String = null) As ColumnModel
Parameters
- defaultValue
- DbGeography
Constant value to use as the default value for this column.
- defaultValueSql
- String
SQL expression used as the default value for this column.
- name
- String
The name of the column.
- storeType
- String
Provider specific data type to use for this column.
Returns
The newly constructed column definition.
Applies to
Geography(Nullable<Boolean>, DbGeography, String, String, String, IDictionary<String,AnnotationValues>)
Creates a new column definition to store geography data.
Entity Framework Migrations APIs are not designed to accept input provided by untrusted sources (such as the end user of an application). If input is accepted from such sources it should be validated before being passed to these APIs to protect against SQL injection attacks etc.
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1026:DefaultParametersShouldNotBeUsed")]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic")]
public System.Data.Entity.Migrations.Model.ColumnModel Geography (Nullable<bool> nullable = null, System.Data.Entity.Spatial.DbGeography defaultValue = null, string defaultValueSql = null, string name = null, string storeType = null, System.Collections.Generic.IDictionary<string,System.Data.Entity.Infrastructure.Annotations.AnnotationValues> annotations = null);
member this.Geography : Nullable<bool> * System.Data.Entity.Spatial.DbGeography * string * string * string * System.Collections.Generic.IDictionary<string, System.Data.Entity.Infrastructure.Annotations.AnnotationValues> -> System.Data.Entity.Migrations.Model.ColumnModel
Public Function Geography (Optional nullable As Nullable(Of Boolean) = null, Optional defaultValue As DbGeography = null, Optional defaultValueSql As String = null, Optional name As String = null, Optional storeType As String = null, Optional annotations As IDictionary(Of String, AnnotationValues) = null) As ColumnModel
Parameters
- defaultValue
- DbGeography
Constant value to use as the default value for this column.
- defaultValueSql
- String
SQL expression used as the default value for this column.
- name
- String
The name of the column.
- storeType
- String
Provider specific data type to use for this column.
- annotations
- IDictionary<String,AnnotationValues>
Custom annotations usually from the Code First model.
Returns
The newly constructed column definition.
- Attributes
Applies to
Entity Framework