MSFGeoJSONGeometryReader

Objective-C


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

Swift

class MSFGeoJSONGeometryReader : NSObject

A GeoJSON parser. Parser supports Geometry, Feature and FeatureCollection inputs.

  • Constructs a new GeoJSONGeometryReader object.

    Declaration

    Objective-C

    - (id)init;

    Swift

    init!()
  • Returns the current target projection. If target projection is set, all geometry coordinates will be converted from WGS84 to target projection coordinate system.

    Declaration

    Objective-C

    - (MSFProjection *)getTargetProjection;

    Swift

    func getTargetProjection() -> MSFProjection!

    Return Value

    The current target projection or null.

  • Sets the current target projection. If target projection is set, all geometry coordinates will be converted from WGS84 to target projection coordinate system.

    Declaration

    Objective-C

    - (void)setTargetProjection:(MSFProjection *)proj;

    Swift

    func setTargetProjection(_ proj: MSFProjection!)

    Parameters

    proj

    The new target projection or null.

  • Reads geometry from the specified GeoJSON string.

    Declaration

    Objective-C

    - (MSFGeometry *)readGeometry:(NSString *)geoJSON;

    Swift

    func readGeometry(_ geoJSON: String!) -> MSFGeometry!

    Parameters

    geoJSON

    The GeoJSON string to read.

    Return Value

    The geometry read from the string. @throws NSException If string could not be parsed.

  • Reads feature from the specified GeoJSON string.

    Declaration

    Objective-C

    - (MSFFeature *)readFeature:(NSString *)geoJSON;

    Swift

    func readFeature(_ geoJSON: String!) -> MSFFeature!

    Parameters

    geoJSON

    The GeoJSON string to read.

    Return Value

    The feature read from the string. @throws NSException If string could not be parsed.

  • Reads feature collection from the specified GeoJSON string.

    Declaration

    Objective-C

    - (MSFFeatureCollection *)readFeatureCollection:(NSString *)geoJSON;

    Swift

    func readFeatureCollection(_ geoJSON: String!) -> MSFFeatureCollection!

    Parameters

    geoJSON

    The GeoJSON string to read.

    Return Value

    The feature collection read from the string. @throws NSException If string could not be parsed.

  • Undocumented

    Declaration

    Objective-C

    -(void)dealloc;

    Swift

    func dealloc()