31 lines
729 B
Objective-C
31 lines
729 B
Objective-C
#import "MBXAnnotation.h"
|
|
|
|
@interface MBXAnnotation ()
|
|
|
|
@property (nonatomic) CLLocationCoordinate2D coordinate;
|
|
@property (nonatomic) NSString *title;
|
|
@property (nonatomic) NSString *subtitle;
|
|
|
|
@end
|
|
|
|
@implementation MBXAnnotation
|
|
|
|
+ (instancetype)annotationWithLocation:(CLLocationCoordinate2D)coordinate title:(NSString *)title subtitle:(NSString *)subtitle
|
|
{
|
|
return [[self alloc] initWithLocation:coordinate title:title subtitle:subtitle];
|
|
}
|
|
|
|
- (instancetype)initWithLocation:(CLLocationCoordinate2D)coordinate title:(NSString *)title subtitle:(NSString *)subtitle
|
|
{
|
|
if (self = [super init])
|
|
{
|
|
_coordinate = coordinate;
|
|
_title = title;
|
|
_subtitle = subtitle;
|
|
}
|
|
|
|
return self;
|
|
}
|
|
|
|
@end
|