MSFGeocodingResult

Objective-C


@interface MSFGeocodingResult : NSObject {
  void *swigCPtr;
  BOOL swigCMemOwn;
}

Swift

class MSFGeocodingResult : NSObject

A geocoding result object describing address, features (geometry) and rank of the result.

  • Checks if this object is equal to the specified object.

    Declaration

    Objective-C

    - (BOOL)isEqual:(id)object;

    Swift

    func isEqual(_ object: Any!) -> Bool

    Parameters

    object

    The reference object.

    Return Value

    True when objects are equal, false otherwise.

  • Returns the hash value of this object.

    Declaration

    Objective-C

    - (NSUInteger)hash;

    Swift

    func hash() -> UInt

    Return Value

    The hash value of this object.

  • Constructs a GeocodingResult from a projection, address, rank and feature collection.

    Declaration

    Objective-C

    - (id)initWithProjection:(MSFProjection *)projection
                     address:(MSFGeocodingAddress *)address
                        rank:(float)rank
           featureCollection:(MSFFeatureCollection *)featureCollection;

    Swift

    init!(projection: MSFProjection!, address: MSFGeocodingAddress!, rank: Float, featureCollection: MSFFeatureCollection!)

    Parameters

    projection

    The projection used for the geometry of the result.

    address

    The address of the result.

    rank

    The relative ranking of the result (in range 0..1).

    featureCollection

    The geometry (features) associated with the result.

  • Returns the address of the result.

    Declaration

    Objective-C

    - (MSFGeocodingAddress *)getAddress;

    Swift

    func getAddress() -> MSFGeocodingAddress!

    Return Value

    The address of the result.

  • Returns the rank of the result. The rank is a normalized number between 0 and 1, 1 meaning a perfect match.

    Declaration

    Objective-C

    - (float)getRank;

    Swift

    func getRank() -> Float

    Return Value

    The rank of the result.

  • Returns the feature collection of the result.

    Declaration

    Objective-C

    - (MSFFeatureCollection *)getFeatureCollection;

    Swift

    func getFeatureCollection() -> MSFFeatureCollection!

    Return Value

    The feature collection of the result.

  • Returns the projection of the geometry in the result.

    Declaration

    Objective-C

    - (MSFProjection *)getProjection;

    Swift

    func getProjection() -> MSFProjection!

    Return Value

    The projection of the geometry in the result.

  • Returns the result as a GeoJSON FeatureCollection, in WGS84.

    Every feature carries the result’s “address” and “rank” alongside its own properties, so one string is the whole answer - a binding that walked the features instead paid a crossing per feature and rebuilt this shape by hand.

    Declaration

    Objective-C

    - (NSString *)getGeoJSON;

    Swift

    func getGeoJSON() -> String!

    Return Value

    The result as GeoJSON.

  • Creates a string representation of this result object, useful for logging.

    Declaration

    Objective-C

    - (NSString *)description;

    Swift

    func description() -> String!

    Return Value

    The string representation of this result object.

  • Undocumented

    Declaration

    Objective-C

    -(void)dealloc;

    Swift

    func dealloc()