C# 클래스 OSCodePointDataImport.OSDataImporter

파일 보기 프로젝트 열기: AdaTheDev/Ordnance-Survey-Code-Point-Data-Importer

보호된 메소드들

메소드 설명
ConvertToLonLat ( double northing, double easting ) : TDPG.GeoCoordConversion.PolarGeoCoordinate

Converts northing and easting coordinates into Longitude/Latitude coordinates in the WGS84 coordinate system.

CreateSpatialIndex ( SqlConnection connection, string schemaName, string tableName ) : void

Creates a spatial index on the GeoLocation column.

LoadRowsToDatabase ( SqlConnection connection, DataTable data, string schemaName, string tableName ) : int

Loads the supplied data to the newly created table in the database.

SetForeignKey ( SqlConnection connection, string schemaName, string primaryKeyTableName, string primaryKeyColumnName, string foreignKeyTableName, string foreignKeyColumnName ) : void

Adds a foreign key constraint.

SetGeoColumn ( SqlConnection connection, string schemaName, string tableName ) : void

Set the GeoLocation column in the supplied table, to a GEOGRAPHY point based on the Latitude and Longitude columns

SetPrimaryKey ( SqlConnection connection, string schemaName, string tableName, string pkColumnNames ) : void

Sets the primary key on the supplied table

비공개 메소드들

메소드 설명
ExecCommand ( SqlConnection connection, string commandText ) : void

Executes the supplied SQL.

메소드 상세

ConvertToLonLat() 보호된 메소드

Converts northing and easting coordinates into Longitude/Latitude coordinates in the WGS84 coordinate system.
protected ConvertToLonLat ( double northing, double easting ) : TDPG.GeoCoordConversion.PolarGeoCoordinate
northing double northing coordinate
easting double easting coordinate
리턴 TDPG.GeoCoordConversion.PolarGeoCoordinate

CreateSpatialIndex() 보호된 메소드

Creates a spatial index on the GeoLocation column.
protected CreateSpatialIndex ( SqlConnection connection, string schemaName, string tableName ) : void
connection System.Data.SqlClient.SqlConnection db conneciton to run the command against
schemaName string schema name
tableName string table name
리턴 void

LoadRowsToDatabase() 보호된 메소드

Loads the supplied data to the newly created table in the database.
protected LoadRowsToDatabase ( SqlConnection connection, DataTable data, string schemaName, string tableName ) : int
connection System.Data.SqlClient.SqlConnection SQL Server database connection
data System.Data.DataTable DataTable containing the data to load
schemaName string name of schema the table belongs to
tableName string table to load the data to
리턴 int

SetForeignKey() 보호된 메소드

Adds a foreign key constraint.
protected SetForeignKey ( SqlConnection connection, string schemaName, string primaryKeyTableName, string primaryKeyColumnName, string foreignKeyTableName, string foreignKeyColumnName ) : void
connection System.Data.SqlClient.SqlConnection db connection to run the command against
schemaName string schema name
primaryKeyTableName string name of the primary key table
primaryKeyColumnName string name of the primary key column
foreignKeyTableName string name of the foreign key table
foreignKeyColumnName string name of the foreign key column
리턴 void

SetGeoColumn() 보호된 메소드

Set the GeoLocation column in the supplied table, to a GEOGRAPHY point based on the Latitude and Longitude columns
protected SetGeoColumn ( SqlConnection connection, string schemaName, string tableName ) : void
connection System.Data.SqlClient.SqlConnection db connection to use
schemaName string name of schema the table belongs to
tableName string name of table to update
리턴 void

SetPrimaryKey() 보호된 메소드

Sets the primary key on the supplied table
protected SetPrimaryKey ( SqlConnection connection, string schemaName, string tableName, string pkColumnNames ) : void
connection System.Data.SqlClient.SqlConnection db connection to use
schemaName string name of schema the table belongs to
tableName string name of the table to add the PK constraint on
pkColumnNames string column or columns that form the PK
리턴 void