I am implementing an offline map using MapBox in my app that currently uses mapkit with Apple Maps.
I have an object which describes a point of interest - name, description location etc with an interface as seen below:
#import <Foundation/Foundation.h>
#import <Mapkit/MapKit.h>
#import <MapBox/MapBox.h>
@class CLLocation;
@interface MHGPlace : NSObject <MKAnnotation>
@property (nonatomic, readonly) CLLocationCoordinate2D coordinate;
-(NSString *) title;
-(NSString *) subtitle;
-(NSString *) mapid;
@property (nonatomic, copy) NSString *name;
@property (nonatomic, copy) NSString *description;
@end
The above object gets added to an array and then to mapkit as follows:
[self.mapView addAnnotations:self.places];
However, when dealing with a MapBox mapview I cant add a MKAnnotation object like I do above as it requires an RMAnnotation Object. But when I change my interface to read-
<RMAnnotation> instead of <MKAnnotation>, it doesnt seem to exist.
I cant find anything in there documentation about how to add an annotation like this. It would be good to try and do it like this so I can handle callbacks and know which annotation has been tapped etc!