C# Class ESRIUK.DynamicLocators.Core.LocatorWrapper

This class is the base class for all locators created with the SDK. It contains the implementations of all of the interfaces that are required for an ArcGIS locator to work Many of the method implementations minimal to enalbe basic functionality and to allow further customisation This class CANNOT be used on as is to create a locator. The methods CreateFields, Properties, FindAddressCandidates and ReverseGeocode must be overridden in a child class at a minimum to create a locator
Inheritance: ILocator, IAddressInputs, IGeocodingProperties, IAddressGeocoding, IAddressCandidates, IClone, ISingleLineAddressInput, ILocatorImpl, ILocatorDataset, IESRILocatorReleaseInfo, IBatchGeocoding, IReverseGeocoding, IReverseGeocodingProperties, IGeocodeServerSingleLine
Mostrar archivo Open project: EsriUK/dynamic-locator-sdk

Protected Properties

Property Type Description
m_addXYCoordsToMatchFields bool
m_addressFields IFields
m_candidateFields IFields
m_locatorProperties IPropertySet
m_matchFields IFields
m_searchTokenAlias string
m_searchTokenName String
m_spatialReference ISpatialReference

Public Methods

Method Description
Assign ( IClone src ) : void

Assigns the properties of src to the receiver.

Clone ( ) : IClone

Clones the receiver and assigns the result to *clone.

FindAddressCandidates ( IPropertySet address ) : IArray

Generates candidates for an address.

GetDefaultInputFieldNames ( ) : object

Recognized names for the single line input field.

GetSingleLineAddressField ( ) : IField

Field needed to geocode a single line address.

IsEqual ( IClone other ) : bool

Returns TRUE when the receiver and other have the same properties.

IsIdentical ( IClone other ) : bool

Returns TRUE when the receiver and other are the same object.

LocatorWrapper ( ) : System

The constructor initialises the log4net configuration and calls the CreateFields method

MatchAddress ( IPropertySet address ) : IPropertySet

Uses the FindAddressCandidates method to geocode a single address

MatchRecordSet ( ICursor addressCursor, string addressFieldNames, IRecordSetInit outputRecordSet, string outputFieldNames, IPropertySet fieldsToCopy, ITrackCancel cancelTracker ) : void

Uses MatchAddress to geocode a cursor of addresses to a RecordSet This is called by ArcGIS Server Geocode Addresses

MatchTable ( ITable addressTable, String addressFieldNames, String whereClause, IFeatureClass outputFeatureClass, String outputFieldNames, IPropertySet fieldsToCopy, ITrackCancel cancelTracker ) : void

Geocodes a table of addresses

RematchTable ( ITable pInputTable, string inputFieldNames, string inputJoinFieldName, IFeatureClass resultTable, string outputFieldNames, string outputJoinFieldName, string whereClause, ITrackCancel cancelTracker ) : void

Uses MatchTable to rematch addresses in a feature class

ReverseGeocode ( IPoint location, bool returnIntersection ) : IPropertySet

Generate an address based on a point.

Validate ( ) : void

Checks that the locator properties and locator dataset are present and valid.

get_DefaultInputFieldNames ( string addressField ) : object

Recognized names for an input field.

set_DefaultInputFieldNames ( string addressField, object inputFieldNames ) : void

Recognized names for a required input field.

Protected Methods

Method Description
CreateFields ( ) : void

This initialises all of the different fields that are required for the locator to function It contains declarations for the Match and Candidate fields for the locator and so must be overridden in each child class

getProperty ( IPropertySet locatorProperties, String Name ) : object

Helper method for getting a property and returning null if it isn't found instead of throwing an exception.

isSameObject ( object a, object b ) : bool

Compare two objects to see if they are identical

Private Methods

Method Description
createGDBWorkspace ( string path, string gdbType ) : IWorkspace

Create a workspace for a FGDB or PGDB

setupEditSession ( IClass table ) : IWorkspaceEdit

Setup an edit Session for a table

tokenizeConnectionProperties ( string connection ) : string[]

Get connection properties for FGDB and PGDB

tokenizeLocatorWorkspaceString ( string locatorWorkspaceString ) : string[]

Get the path for a locator stored in a file folder

tokenizeSDEProperties ( string connection ) : string

Builds a property set that contains the connection info for SDE

Method Details

Assign() public method

Assigns the properties of src to the receiver.
public Assign ( IClone src ) : void
src IClone
return void

Clone() public method

Clones the receiver and assigns the result to *clone.
public Clone ( ) : IClone
return IClone

CreateFields() protected method

This initialises all of the different fields that are required for the locator to function It contains declarations for the Match and Candidate fields for the locator and so must be overridden in each child class
protected CreateFields ( ) : void
return void

FindAddressCandidates() public method

Generates candidates for an address.
public FindAddressCandidates ( IPropertySet address ) : IArray
address IPropertySet
return IArray

GetDefaultInputFieldNames() public method

Recognized names for the single line input field.
public GetDefaultInputFieldNames ( ) : object
return object

GetSingleLineAddressField() public method

Field needed to geocode a single line address.
public GetSingleLineAddressField ( ) : IField
return IField

IsEqual() public method

Returns TRUE when the receiver and other have the same properties.
public IsEqual ( IClone other ) : bool
other IClone
return bool

IsIdentical() public method

Returns TRUE when the receiver and other are the same object.
public IsIdentical ( IClone other ) : bool
other IClone
return bool

LocatorWrapper() public method

The constructor initialises the log4net configuration and calls the CreateFields method
public LocatorWrapper ( ) : System
return System

MatchAddress() public method

Uses the FindAddressCandidates method to geocode a single address
public MatchAddress ( IPropertySet address ) : IPropertySet
address IPropertySet Input address
return IPropertySet

MatchRecordSet() public method

Uses MatchAddress to geocode a cursor of addresses to a RecordSet This is called by ArcGIS Server Geocode Addresses
public MatchRecordSet ( ICursor addressCursor, string addressFieldNames, IRecordSetInit outputRecordSet, string outputFieldNames, IPropertySet fieldsToCopy, ITrackCancel cancelTracker ) : void
addressCursor ICursor Cursor containing address to be geocoded
addressFieldNames string The address fields that make up a record in the cursor
outputRecordSet IRecordSetInit The output record set
outputFieldNames string The output field names
fieldsToCopy IPropertySet
cancelTracker ITrackCancel
return void

MatchTable() public method

Geocodes a table of addresses
public MatchTable ( ITable addressTable, String addressFieldNames, String whereClause, IFeatureClass outputFeatureClass, String outputFieldNames, IPropertySet fieldsToCopy, ITrackCancel cancelTracker ) : void
addressTable ITable Input address table
addressFieldNames String Fields defined in the table
whereClause String Query filter where clause
outputFeatureClass IFeatureClass Output feature class for matched addresses
outputFieldNames String Output field names
fieldsToCopy IPropertySet
cancelTracker ITrackCancel
return void

RematchTable() public method

Uses MatchTable to rematch addresses in a feature class
public RematchTable ( ITable pInputTable, string inputFieldNames, string inputJoinFieldName, IFeatureClass resultTable, string outputFieldNames, string outputJoinFieldName, string whereClause, ITrackCancel cancelTracker ) : void
pInputTable ITable Input table containing addresses
inputFieldNames string In put tables fields
inputJoinFieldName string Input join field name
resultTable IFeatureClass The rematch result table
outputFieldNames string Output field names
outputJoinFieldName string Output join field name
whereClause string Where Clause for the Match Table method
cancelTracker ITrackCancel
return void

ReverseGeocode() public method

Generate an address based on a point.
public ReverseGeocode ( IPoint location, bool returnIntersection ) : IPropertySet
location IPoint
returnIntersection bool
return IPropertySet

Validate() public method

Checks that the locator properties and locator dataset are present and valid.
public Validate ( ) : void
return void

getProperty() protected method

Helper method for getting a property and returning null if it isn't found instead of throwing an exception.
protected getProperty ( IPropertySet locatorProperties, String Name ) : object
locatorProperties IPropertySet
Name String
return object

get_DefaultInputFieldNames() public method

Recognized names for an input field.
public get_DefaultInputFieldNames ( string addressField ) : object
addressField string
return object

isSameObject() protected method

Compare two objects to see if they are identical
protected isSameObject ( object a, object b ) : bool
a object
b object
return bool

set_DefaultInputFieldNames() public method

Recognized names for a required input field.
public set_DefaultInputFieldNames ( string addressField, object inputFieldNames ) : void
addressField string
inputFieldNames object
return void

Property Details

m_addXYCoordsToMatchFields protected_oe property

protected bool m_addXYCoordsToMatchFields
return bool

m_addressFields protected_oe property

protected IFields m_addressFields
return IFields

m_candidateFields protected_oe property

protected IFields m_candidateFields
return IFields

m_locatorProperties protected_oe property

protected IPropertySet m_locatorProperties
return IPropertySet

m_matchFields protected_oe property

protected IFields m_matchFields
return IFields

m_searchTokenAlias protected_oe property

protected string m_searchTokenAlias
return string

m_searchTokenName protected_oe property

protected String m_searchTokenName
return String

m_spatialReference protected_oe property

protected ISpatialReference m_spatialReference
return ISpatialReference