Kakao
Maps API

Kakao 지도 iOS API Documentation

Classes
MTMapView
- constants
- properties
- instance methods
- class methods
MTMapCameraUpdate
- class methods
MTMapPOIItem
- constants
- properties
- class methods
MTMapLocationMarkerItem
- properties
- class methods
MTMapCircle
- properties
- class methods
MTMapPolyline
- properties
- class methods
MTMapReverseGeoCoder
- instance methods
- class methods
Protocols
MTMapViewDelegate
- instance methods
MTMapReverseGeoCoderDelegate
- instance methods

MTMapView Properties Class Methods Instance Methods Constants

Kakao 지도 화면을 보여주는 View Class이다.
MTMapView를 생성하여 Kakao 지도 화면을 보여주는 View를 사용할 수 있다.
지도 종류 지정, 지도 화면 이동/확대/축소, 현위치 트래킹 및 나침반 모드, POI Item(MTMapPOIItem) 관리, Polyline(MTMapPolyline) 관리 등의 기능이 제공된다.
MTMapViewDelegate protocol을 구현하는 delegate객체를 지정하여 지도에서 발생하는 다양한 이벤트들을 통보받을 수 있다.
동시에 두개 이상의 MTMapView 객체를 생성하여 사용하는 것은 허용되지 않는다.
같이보기 MTMapPoint, MTMapPOIItem, MTMapPolyline, MTMapViewDelegate

Import

#import <MTMapView.h>

Task

지도 타일 이미지 Persistent Cache 기능 활성화

+ isMapTilePersistentCacheEnabled
+ setMapTilePersistentCacheEnabled:
+ clearMapTilePersistentCache

현위치 마커

- updateCurrentLocationMarker:

지도 화면의 중심점 설정

- setMapCenterPoint:animated:
- setMapCenterPoint:zoomLevel:animated:

지도 화면 확대/축소

- setZoomLevel:animated:
- zoomInAnimated:
- zoomOutAnimated:
- fitMapViewAreaToShowMapPoints:

지도 회전

- setMapRotationAngle:animated:

지도 이동 및 확대/축소

- animateWithCameraUpdate:

지도 타일 Refresh

- refreshMapTiles

Memery Warning

- didReceiveMemoryWarning

POIItem

- addPOIItem:
- addPOIItems:
- selectPOIItem:animated:
- deselectPOIItem:
- findPOIItemByTag:
- findPOIItemByName:
- removePOIItem:
- removePOIItems:
- removeAllPOIItems
- fitMapViewAreaToShowAllPOIItems

Polyline

- addPolyline:
- findPolylineByTag:
- removePolyline:
- removeAllPolylines
- fitMapViewAreaToShowPolyline:
- fitMapViewAreaToShowAllPolylines

Circle

- addCircle:
- findCircleByTag:
- removeCircle:
- removeAllCircles
- fitMapViewAreaToShowCircle:
- fitMapViewAreaToShowAllCircleOverlays

Properties

delegate

지도 객체에서 발생하는 이벤트를 처리할 delegate 객체를 설정한다.
delegate 객체는 APP KEY 인증 결과 이벤트, 지도 이동/확대/축소, 지도 화면 터치(Single Tap / Double Tap / Long Press) 이벤트, 현위치 트래킹 이벤트, POI 관련 이벤트를 통보받을 수 있다.

@property (nonatomic, assign) id<MTMapViewDelegate> delegate;

baseMapType

지도 종류(기본 지도, 위성 지도, 하이브리드 지도)를 지정하거나 현재 보여주고 있는 지도 종류를 확인할 수 있다.

@property (nonatomic) MTMapType baseMapType;

useHDMapTile

고해상도 지도 타일 사용 여부를 설정한다.
Retina Display인 경우 기본값은 YES, 아닌경우 기본값은 NO

@property (nonatomic) BOOL useHDMapTile;

showCurrentLocationMarker

현위치를 표시하는 아이콘(마커)를 화면에 표시할지 여부를 설정한다.
currentLocationTrackingMode property를 이용하여 현위치 트래킹 기능을 On 시키면 자동으로 현위치 마커가 보여지게 된다.
현위치 트래킹 기능을 Off한 후에 현위치 아이콘을 지도 화면에서 제거할 때 사용할 수 있다.

@property (nonatomic) BOOL showCurrentLocationMarker;

currentLocationTrackingMode

현위치 트래킹 모드 및 나침반 모드를 설정한다.
- 현위치 트래킹 모드 : 지도화면 중심을 단말의 현재 위치로 이동시켜줌
- 나침반 모드 : 단말의 방향에 따라 지도화면이 회전됨
현위치 트래킹 모드만 On시키거나 현위치 트래킹 모드, 나침반 모드 둘다 On 시킬 수 있다.
현위치 트래킹/나침반 모드를 활성화 시키면 현위치 정보가 설정된 MTMapViewDelegate 객체에 전달된다.
같이보기 MTMapCurrentLocationTrackingMode
같이보기 MTMapViewDelegate

@property (nonatomic) MTMapCurrentLocationTrackingMode currentLocationTrackingMode;

mapCenterPoint

현재 지도 화면의 중심점을 확인할 수 있다.

@property (nonatomic, readonly) MTMapPoint* mapCenterPoint;

zoomLevel

현재 지도 화면의 확대/축소 레벨을 확인할 수 있다.

@property (nonatomic, readonly) MTMapZoomLevel zoomLevel;

mapRotationAngle

현재 지도화면의 회전 각도(360 degree)를 확인할 수 있다.

@property (nonatomic, readonly) MTMapRotationAngle mapRotationAngle;

poiItems

지도화면에 보여주고 있는 POI 아이템 리스트를 조회할 수 있다.

@property (nonatomic, readonly) NSArray* poiItems;

polylines

지도화면에 보여주고 있는 Polyline 리스트를 조회할 수 있다.

@property (nonatomic, readonly) NSArray* polylines;

circles

지도화면에 보여주고 있는 CircleOverlay 리스트를 조회할 수 있다.

@property (nonatomic, readonly) NSArray* circles;

Class Methods

isMapTilePersistentCacheEnabled:

+ (BOOL)isMapTilePersistentCacheEnabled;

지도 타일 이미지 Persistent Cache 기능 활성화 여부를 조회한다.

Parameter
  • apiKey NSString* : 발급받은 APP KEY 해시 문자열
Returns
  • BOOL : Persistent Cache 기능 활성화 여부

setMapTilePersistentCacheEnabled:

+ (void)setMapTilePersistentCacheEnabled:(BOOL)enableCache;

지도 타일 이미지 Persistent Cache 기능은 네트워크를 통해 다운로드한 지도 이미지 데이터를 단말의 영구(persistent) 캐쉬 영역에 저장하는 기능이다.
같은 영역의 지도를 다시 로드할때 캐쉬에 저장된 지도 타일들은 네트워크를 통해 다운로드 받지 않고 단말의 캐쉬에서 바로 로드하여 네트워크 사용량을 줄이고 지도 로딩 시간을 단축할 수 있다.
사용되지 않는 지도 타일 이미지 캐쉬 데이터는 MapView 동작 중에 자동으로 삭제되어 캐쉬 용량의 크기가 너무 커지지 않도록 조절된다.
Application의 Cache 영역 사용량이 부담이 되면 Cache 기능을 비활성화 하는 것이 좋다.
MTMapView가 동작하는 중에는 Cache 기능 활성화 설정 변경이 적용되지 않으며 MTMapView를 사용하기 전에 Cache 활성화 여부를 설정해야 한다.

Parameter
  • enableCache BOOL : Persistent Cache 기능 활성화 여부

clearMapTilePersistentCache

+ (void)clearMapTilePersistentCache;

Application의 Document Directory의 임시 디렉토리에 저장된 지도 타일 캐쉬 데이터를 모두 삭제한다.
MTMapView가 동작 중인 상태에서도 사용가능하다.

Instance Methods

updateCurrentLocationMarker:

- (void)updateCurrentLocationMarker:(MTMapLocationMarkerItem *)locationMarkerItem;

화면상에 보이는 현위치 마커의 UI를 업데이트 한다.

Parameter
  • locationMarkerItem MTMapLocationMarkerItem* : 현위치 마커 정보. nil일 경우, Default 현위치 마커로 노출된다.

setMapCenterPoint:animated:

- (void)setMapCenterPoint:(MTMapPoint*)mapPoint animated:(BOOL)animated;

지도 화면의 중심점을 설정한다.

Parameter
  • mapPoint MTMapPoint* : 지도화면 중심점을 나타내는 MTMapPoint 객체
  • animated BOOL : 지도화면 중심점 이동시 애니매이션 효과를 적용할지 여부

setMapCenterPoint:zoomLevel:animated:

- (void)setMapCenterPoint:(MTMapPoint*)mapPoint zoomLevel:(MTMapZoomLevel)zoomLevel animated:(BOOL)animated;

지도 화면의 중심점과 확대/축소 레벨을 설정한다.

Parameter
  • mapPoint MTMapPoint* : 지도화면 중심점을 나타내는 MTMapPoint 객체
  • zoomLevel MTMapZoomLevel : 지도화면 확대 축소 레벨 값 (-2~12, 값이 클수록 더 넓은 영역이 화면이 보임)
  • animated BOOL : 지도화면 중심점 이동시 애니매이션 효과를 적용할지 여부

setZoomLevel:animated:

- (void)setZoomLevel:(MTMapZoomLevel)zoomLevel animated:(BOOL)animated;

지도 화면의 확대/축소 레벨을 설정한다.

Parameter
  • zoomLevel MTMapZoomLevel : 지도화면 확대 축소 레벨 값 (-2~12, 값이 클수록 더 넓은 영역이 화면이 보임)
  • animated BOOL : 지도화면의 확대/축소 레벨 변경시 애니매이션 효과를 적용할지 여부

zoomInAnimated:

- (void)zoomInAnimated:(BOOL)animated;

지도 화면을 한단계 확대한다. (더 좁은 영역이 크게 보임)
확대/축소 레벨 값이 1 감소됨

Parameter
  • animated BOOL : 지도화면의 확대 시 애니매이션 효과를 적용할지 여부

zoomOutAnimated:

- (void)zoomOutAnimated:(BOOL)animated;

지도 화면을 한단계 축소한다. (더 넓은 영역이 화면에 나타남)
확대/축소 레벨 값이 1 증가됨

Parameter
  • animated BOOL : 지도화면의 축소 시 애니매이션 효과를 적용할지 여부

fitMapViewAreaToShowMapPoints:

- (void)fitMapViewAreaToShowMapPoints:(NSArray*)mapPoints;

지정한 지도 좌표들이 모두 화면에 나타나도록 지도화면 중심과 확대/축소 레벨을 자동조절 한다.

Parameter
  • mapPoints NSArray* : 화면에 모두 보여주고자 하는 지도 좌표 리스트 (Array of MTMapPoint)

setMapRotationAngle:animated:

- (void)setMapRotationAngle:(MTMapRotationAngle)angle animated:(BOOL)animated;

지도 화면의 회전 각도를 설정한다.

Parameter
  • angle MTMapRotationAngle : 회전 각도 (0~360도)
  • animated BOOL : 회전 각도 변경시 애니매이션 효과를 적용할지 여부

animateWithCameraUpdate:

- (void)animateWithCameraUpdate:(MTMapCameraUpdate *)cameraUpdate;

지도 화면 이동 혹은 확대/축소 시킨다.

Parameter
  • cameraUpdate MTMapCameraUpdate : 지도 화면 이동을 위한 중심점, 확대/축소 레벨 등을 지정한 MTMapCameraUpdate 객체

refreshMapTiles

- (void)refreshMapTiles;

지도 화면에 나타나는 지도 타일들을 지도 타일 서버에서 다시 받아와서 갱신한다.

didReceiveMemoryWarning

- (void)didReceiveMemoryWarning;

MTMapView를 포함하고 있는 UIViewController 객체의 didReceiveMemoryWarning 메소드 구현에서 호출해 주어야 한다.
iOS에서 Memory Warning 발생시 메모리에 저장하고 있는 지도 타일 이미지 캐쉬 데이터 들을 삭제하여 메모리를 확보할 수 있다.

addPOIItem:

- (void)addPOIItem:(MTMapPOIItem*)poiItem;

지도화면에 POI Item 아이콘(마커)를 추가한다.

Parameter

addPOIItems:

- (void)addPOIItems:(NSArray *)poiItems;

지도화면에 POI Item 아이콘(마커) 리스트를 추가한다.

Parameter
  • poiItems NSArray* : 추가할 POI Item 객체 리스트 (array of MTMapPOIItem(s))

selectPOIItem:animated:

- (void)selectPOIItem:(MTMapPOIItem*)poiItem animated:(BOOL)animated;

특정 POI Item 을 선택한다.
선택된 POI Item은 Callout Balloon(말풍선)이 아이콘(마커)위에 나타난다.

Parameter
  • poiItem MTMapPOIItem : 선택할 POI Item 객체
  • animated BOOL : POI Item 선택시 말풍선이 나타날 때 애니매이션 효과가 적용될 지 여부

deselectPOIItem:

- (void)deselectPOIItem:(MTMapPOIItem*)poiItem;

특정 POI Item 을 선택 해제한다.
선택 해제된 POI Item은 Callout Balloon(말풍선)이 POI 아이콘(마커)위에서 사라진다.

Parameter
  • poiItem MTMapPOIItem : 선택 해제할 POI Item 객체
  • animated BOOL : POI Item 선택시 말풍선이 나타날 때 애니매이션 효과가 적용될 지 여부

findPOIItemByTag:

- (MTMapPOIItem*)findPOIItemByTag:(NSInteger)tag;

지도화면에 추가된 POI Item 들 중에서 tag값이 일치하는 POI Item을 찾는다.

Parameter
  • tag NSInteger : 찾고자 하는 POI Item의 tag 값
Return
  • MTMapPOIItem : tag가 일치하는 POI Item 객체, 일치하는 POI Item이 없는 경우 nil이 리턴된다.

findPOIItemByName:

- (NSArray*)findPOIItemByName:(NSString*)name;

지도화면에 추가된 POI Item 들 중에서 이름이 일치하는 POI Item 객체(리스트)를 찾는다.

Parameter
  • name NSString* : 찾고자 하는 POI Item의 이름 문자열
Return
  • NSArray * : 이름 문자열이 일치하는 POI Item 객체(리스트), 일치하는 POI Item이 없는 경우 nil이 리턴된다.

removePOIItem:

- (void)removePOIItem:(MTMapPOIItem*)poiItem;

특정 POI Item을 지도화면에서 제거한다.

Parameter

removePOIItems:

- (void)removePOIItems:(NSArray *)poiItems; // array of MTMapPOIItem(s)

POI Item 리스트를 지도화면에서 제거한다.

Parameter
  • poiItems NSArray* : 제거하고자 하는 POI Item 객체 리스트

removeAllPOIItems

- (void)removeAllPOIItems;

지도 화면에 추가된 모든 POI Item들을 제거한다.

fitMapViewAreaToShowAllPOIItems

- (void)fitMapViewAreaToShowAllPOIItems;

지도 화면에 추가된 모든 POI Item들이 화면에 나타나도록 지도 화면 중심과 확대/축소 레벨을 자동으로 조정한다.

addPolyline:

- (void)addPolyline:(MTMapPolyline*)polyline;

지도화면에 Polyline을 추가한다.

Parameter

findPolylineByTag:

- (MTMapPolyline*)findPolylineByTag:(NSInteger)tag;

지도화면에 추가된 Polyline들 중에서 tag값이 일치하는 Polyline을 찾는다.

Parameter
  • tag NSInteger : 찾고자 하는 Polyline의 tag 값
Return
  • MTMapPolyline* : tag값이 일치하는 Polyline 객체, 일치하는 Polyline이 없는 경우 nil이 리턴된다.

removePolyline:

- (void)removePolyline:(MTMapPolyline*)polyline;

특정 Polyline을 지도화면에서 제거한다.

Parameter

removeAllPolylines

- (void)removeAllPolylines;

지도 화면에 추가된 모든 Polyline을 제거한다.

fitMapViewAreaToShowPolyline:

- (void)fitMapViewAreaToShowPolyline:(MTMapPolyline*)polyline;

특정 Polyline의 모든 점들이 화면에 전부 나타나도록 지도 화면 중심과 확대/축소 레벨을 자동으로 조정한다.

Parameter

fitMapViewAreaToShowAllPolylines

- (void)fitMapViewAreaToShowAllPolylines;

지도 화면에 추가된 모든 Polyline 들이 화면에 나타나도록 지도 화면 중심과 확대/축소 레벨을 자동으로 조정한다.

addCircle:

- (void)addCircle:(MTMapCircle*)circle;

지도화면에 Circle을 추가한다.

Parameter

findCircleByTag:

- (MTMapCircle*)findCircleByTag:(NSInteger)tag;

지도화면에 추가된 Circle들 중에서 tag값이 일치하는 Circle를 찾는다.

Parameter
  • tag NSInteger : 찾고자 하는 Circle의 tag 값
Return
  • MTMapCircle* : tag값이 일치하는 Circle 객체, 일치하는 Circle이 없는 경우 nil이 리턴된다.

removeCircle:

- (void)removeCircle:(MTMapCircle*)circle;

특정 Circle을 지도화면에서 제거한다.

Parameter
  • circle MTMapCircle* : 제거하고자 하는 CircleOverlay 객체

removeAllCircles

- (void)removeAllCircles;

지도 화면에 추가된 모든 Circle를 제거한다.

fitMapViewAreaToShowCircle:

- (void)fitMapViewAreaToShowCircle:(MTMapCircle*)circle;

특정 Circle이 화면에 전부 나타나도록 지도 화면 중심과 확대/축소 레벨을 자동으로 조정한다.

Parameter
  • circle MTMapCircle* : 화면에 보여주고자 하는 Circle

fitMapViewAreaToShowAllCircleOverlays

- (void)fitMapViewAreaToShowAllCircleOverlays;

지도 화면에 추가된 모든 Circle들이 화면에 나타나도록 지도 화면 중심과 확대/축소 레벨을 자동으로 조정한다.

Constants

MTMapType

typedef enum {
    MTMapTypeStandard, /**< 기본 지도 */
    MTMapTypeSatellite, /**< 위성 지도 */
    MTMapTypeHybrid /**< 하이브리드 지도 */
} MTMapType;

지도 종류

Constants
  • MTMapTypeStandard : 기본 지도
  • MTMapTypeSatellite : 위성 지도
  • MTMapTypeHybrid : 하이브리드 지도

MTMapCurrentLocationTrackingMode

typedef enum {
    MTMapCurrentLocationTrackingOff, /**< 현위치 트랙킹 모드 및 나침반 모드 Off */
    MTMapCurrentLocationTrackingOnWithoutHeading, /**< 현위치 트랙킹 모드 On, 단말의 위치에 따라 지도 중심이 이동한다. 나침반 모드는 꺼진 상태 */
    MTMapCurrentLocationTrackingOnWithHeading, /**< 현위치 트랙킹 모드 On + 나침반 모드 On, 단말의 위치에 따라 지도 중심이 이동하며 단말의 방향에 따라 지도가 회전한다.(나침반 모드 On) */
    MTMapCurrentLocationTrackingOnWithoutHeadingWithoutMapMoving,
    MTMapCurrentLocationTrackingOnWithHeadingWithoutMapMoving,
} MTMapCurrentLocationTrackingMode;

현위치 트랙킹 타입 enumeration
같이보기 MTMapView.currentLocationTrackingMode

Constants
  • MTMapCurrentLocationTrackingOff : 현위치 트랙킹 모드 및 나침반 모드 Off
  • MTMapCurrentLocationTrackingOnWithoutHeading : 현위치 트랙킹 모드 On, 단말의 위치에 따라 지도 중심이 이동한다. 나침반 모드는 꺼진 상태
  • MTMapCurrentLocationTrackingOnWithHeading : 현위치 트랙킹 모드 On + 나침반 모드 On, 단말의 위치에 따라 지도 중심이 이동하며 단말의 방향에 따라 지도가 회전한다.(나침반 모드 On)
  • MTMapCurrentLocationTrackingOnWithoutHeadingWithoutMapMoving : 현위치 트랙킹 모드 On + 나침반 모드 Off + 지도이동 Off, 지도중심이동을 하지 않는다. 나침반 모드는 꺼진 상태
  • MTMapCurrentLocationTrackingOnWithHeadingWithoutMapMoving : 현위치 트랙킹 모드 On + 나침반 모드 On + 지도이동 Offm 지도중심이동을 하지 않는다. (나침반 모드 On)

MTMapZoomLevel

Zoom Level 데이터 타입 (integer)

Constants
  • MTMapZoomLevel : 지도화면 확대 축소 레벨 값(-2~12, 값이 클수록 더 넓은 영역이 화면이 보임)

MTMapCameraUpdate Class Methods

지도 화면 처리를 담당하는 클래스이다.
지도 화면 이동/확대/축소 등의 기능이 제공된다.
같이보기 MTMapView

Import

#import <MTMapPOIItem.h>

Task

이동

+ move:
+ move:withZoomLevel:
+ move:withDiameter:
+ move:withDiameter:withPadding:

확대/축소

+ fitMapView:
+ fitMapView:withPadding:
+ fitMapView:withPadding:withMinZoomLevel:withMaxZoomLevel:

Class Methods

move

+ (MTMapCameraUpdate *)move:(MTMapPoint *)mapPoint;

지도 화면을 설정한 확대/축소 레벨로 조정 및 설정한 중심점으로 이동한다.

Parameter
  • mapPoint MTMapPoint* : 이동하는 지도 화면의 중심점
Returns

move:withZoomLevel:

+ (MTMapCameraUpdate *)move:(MTMapPoint *)mapPoint withZoomLevel:(MTMapZoomLevel)zoomLevel;

지도 화면을 설정한 확대/축소 레벨로 조정 및 설정한 중심점으로 이동한다.

Parameter
  • mapPoint MTMapPoint* : 이동하는 지도 화면의 중심점
  • zoomLevel MTMapZoomLevel : 변경된 지도 확대/축소 레벨
Returns

move:withDiameter:

+ (MTMapCameraUpdate *)move:(MTMapPoint *)mapPoint withDiameter:(CGFloat)meter;

설정한 중심점으로 이동하면서 지정한 직경(meter) 영역이 보이도록 줌레벨이 조정된다.
지정한 영역의 padding 값은 0

Parameter
  • mapPoint MTMapPoint* : 이동하는 지도 화면의 중심점
  • meter CGFloat : 직경(지름)
Returns

move:withDiameter:withPadding:

+ (MTMapCameraUpdate *)move:(MTMapPoint *)mapPoint withDiameter:(CGFloat)meter withPadding:(CGFloat)padding;

설정한 중심점으로 이동하면서 지정한 직경(meter) 영역이 보이도록 줌레벨이 조정된다.

Parameter
  • mapPoint MTMapPoint* : 이동하는 지도 화면의 중심점
  • meter CGFloat : 직경(지름)
  • padding CGFloat : 지정한 영역의 padding 값
Returns

fitMapView:

+ (MTMapCameraUpdate *)fitMapView:(MTMapBounds)bounds;

지정한 영역이 화면에 나타나도록 지도화면 중심과 확대/축소 레벨을 자동조절한다.
지정한 영역의 padding 값은 0

Parameter
  • bounds MTMapBounds : 화면에 보여주고자 하는 영역 (MTMapPoint 타입의 좌하단 지점과 우상단 지점을 인자로 갖는 구조체)
Returns

fitMapView:withPadding:

+ (MTMapCameraUpdate *)fitMapView:(MTMapBounds)bounds withPadding:(CGFloat)padding;

padding 값을 반영한 지정한 영역이 화면에 지정된 나타나도록 지도화면 중심과 확대/축소 레벨을 자동조절한다.

Parameter
  • bounds MTMapBounds : 화면에 보여주고자 하는 영역 (MTMapPoint 타입의 좌하단 지점과 우상단 지점을 인자로 갖는 구조체)
  • padding CGFloat : padding 지정한 영역의 padding 값
Returns

fitMapView:withPadding:withMaxZoomLevel:

+ (MTMapCameraUpdate *)fitMapView:(MTMapBounds)bounds withPadding:(CGFloat)padding withMinZoomLevel:(MTMapZoomLevel)minZoomLevel withMaxZoomLevel:(MTMapZoomLevel)maxZoomLevel;

padding 값을 반영한 지정한 영역이 화면에 지정된 나타나도록 하되 지정한 최소 레벨과 최대 레벨 범위 안의 지도화면 중심과 확대/축소 레벨을 자동조절 한다.

Parameter
  • bounds MTMapBounds : 화면에 보여주고자 하는 영역 (MTMapPoint 타입의 좌하단 지점과 우상단 지점을 인자로 갖는 구조체)
  • padding CGFloat : 지정한 영역의 padding 값
  • minZoomLevel MTMapZoomLevel : 지도 화면 최대 확대 레벨 값 (-2~12, 값이 작을수록 더 좁은 영역이 화면이 보임. 지도 화면이 확대됨)
  • maxZoomLevel MTMapZoomLevel : 지도 화면 최대 축소 레벨 값 (-2~12, 값이 클수록 더 넓은 영역이 화면이 보임. 지도 화면이 축소됨)
Returns

MTMapPOIItem Properties Class Methods Contants

지도화면 위에 추가되는 POI Item에 해당하는 클래스이다.
지도화면 위에 POI 아이콘(마커)를 추가하기 위해서는 MTMapPOIItem 객체를 생성하여 MTMapView객체에 등록해 주어야 한다. (MTMapView.addPOIItem:, MTMapView.addPOIItems:)
이미 제공되고 있는 POI Item 아이콘을 그대로 사용할 수도 있고, 개발자가 지정한 임의의 이미지를 POI Item 아이콘으로 사용할 수 있다.
MTMapView에 등록된 POI Item을 사용자가 선택하면 POI Item 아이콘(마커)위에 말풍선(Callout Balloon)이 나타나게 되며 말풍선에는 POI Item 이름이 보여지게 된다.
단말 사용자가 길게 누른후(long press) 끌어어(dragging) 위치를 이동시킬 수 있는 Draggable POI Item 도 생성하여 MTMapView에 등록할 수 있다.

Import

#import <MTMapPOIItem.h>

Task

POIItem 생성

+ poiItem

Properties

itemName

POI Item 이름을 지정한다.
POI Item 아이콘이 선택되면 나타나는 말풍선(Callout Balloon)에 POI Item 이름이 보여지게 된다.

@property (nonatomic, copy) NSString* itemName;

mapPoint

POI Item의 지도상 좌표

@property (nonatomic, retain) MTMapPoint* mapPoint;

markerType

POI Item 아이콘(마커) 타입
기본 제공 POI Item 아이콘을 사용하거나, 개발자가 지정한 임의의 이미지를 POI Item 아이콘으로 사용할 수 있다.
default = MTMapPOIItemMarkerTypeBluePin

@property (nonatomic, assign) MTMapPOIItemMarkerType markerType;

markerSelectedType

POI Item 아이콘(마커)가 선택되어진 상태 타입
기본 제공 POI Item 아이콘을 사용하거나, 개발자가 지정한 임의의 이미지를 POI Item 아이콘으로 사용할 수 있다.
default = MTMapPOIItemMarkerTypeNone
같이보기 MTMapPOIItemMarkerSelectedType

@property (nonatomic, assign) MTMapPOIItemMarkerSelectedType markerSelectedType;

showAnimationType

POI Item이 지도화면에 나타날때 애니매이션 종류를 지정한다.
default = MTMapPOIItemShowAnimationTypeNoAnimation
같이보기 MTMapPOIItemShowAnimationType

@property (nonatomic, assign) MTMapPOIItemShowAnimationType showAnimationType;

showDisclosureButtonOnCalloutBalloon

POI Item이 사용자에 의해 선택된 경우 나타나는 말풍선에 나타나는 글자 마지막에 Disclosure Button 이미지(꺽쇠(>)모양 이미지)를 표시할지 여부를 지정한다.
default = YES

@property (nonatomic, assign) BOOL showDisclosureButtonOnCalloutBalloon;

draggable

POI Item 객체에 임의의 정수값(tag)을 지정할 수 있다.
MTMapView 객체에 등록된 POI Item들 중 특정 POI Item을 찾기 위한 식별자로 사용할 수 있다.
tag값을 반드시 지정해야 하는 것은 아니다.
같이보기 MTMapView.findPOIItemByTag:

@property (nonatomic, assign) BOOL draggable;

tag

POI Item 객체에 임의의 정수값(tag)을 지정할 수 있다.
MTMapView 객체에 등록된 POI Item들 중 특정 POI Item을 찾기 위한 식별자로 사용할 수 있다.
tag값을 반드시 지정해야 하는 것은 아니다.
같이보기 MTMapView.findPOIItemByTag:

@property (nonatomic, assign) NSInteger tag;

userObject

해당 POI Item과 관련된 정보를 저장하고 있는 임의의 객체를 저장하고자 할때 사용한다.
사용자가 POI Item을 선택하는 경우 등에 선택된 POI Item과 관련된 정보를 손쉽게 접근할 수 있다.

@property (nonatomic, retain) NSObject* userObject;

customImageName

markerType이 MTMapPOIItemMarkerTypeCustomImage인 경우에만 지정한다.
기본 제공되는 POI Item 아이콘 이미지를 사용하지 않고, 개발자가 지정한 Custom 이미지를 사용하고자 하는 경우에 사용하고자 하는 Image 이름을 지정한다. Application Bundle에 포함된 Image Resource 이름(ex. “MyPOIIconImage.png”)을 지정할 수 있다.
Custom Image는 Screen Scale = 2.0(Retina Display)에 대응하는 고해상도 이미지를 지정해야 한다.
같이보기 MTMapPOIItemMarkerTypeCustomImage

@property (nonatomic, copy) NSString* customImageName;

customSelectedImageName

markerType이 MTMapPOIItemMarkerSelectedTypeCustomImage인 경우에만 지정한다.
개발자가 지정한 Custom 이미지를 사용하고 있는 POI Item 아이콘(마커)이 선택되었을 경우에 사용하고자 하는 Image 이름을 지정한다. Application Bundle에 포함된 Image Resource 이름(ex. “MyPOIIconImage.png”)을 지정할 수 있다.
Custom Image는 Screen Scale = 2.0(Retina Display)에 대응하는 고해상도 이미지를 지정해야 한다.
같이보기 MTMapPOIItemMarkerTypeCustomImage

@property (nonatomic, copy) NSString* customSelectedImageName;

imageNameOfCalloutBalloonLeftSide

POI Item이 사용자에 의해 선택된 경우 나타나는 말풍선의 왼쪽 끝에 사용하고자 하는 Image 이름을 지정한다. Application Bundle에 포함된 Image Resource 이름(ex. “MyPOIIconImage.png”)을 지정할 수 있다.
Custom Image는 Screen Scale = 2.0(Retina Display)에 대응하는 고해상도 이미지를 지정해야 한다.

@property (nonatomic, copy) NSString* imageNameOfCalloutBalloonLeftSide;

imageNameOfCalloutBalloonRightSide

POI Item이 사용자에 의해 선택된 경우 나타나는 말풍선의 오른쪽 끝에 사용하고자 하는 Image 이름을 지정한다. Application Bundle에 포함된 Image Resource 이름(ex. “MyPOIIconImage.png”)을 지정할 수 있다.
Custom Image는 Screen Scale = 2.0(Retina Display)에 대응하는 고해상도 이미지를 지정해야 한다.

@property (nonatomic, copy) NSString* imageNameOfCalloutBalloonRightSide;

customImageAnchorPointOffset

markerType이 MTMapPOIItemMarkerTypeCustomImage인 경우에만 지정한다.
customImageName에 지정한 이미지 상의 어느 지점이 POI Item의 좌표 지점에 해당하는 지를 설정한다.
이미지 상의 Pixel 좌표를 지정한다. 이미지의 좌하단이 원점(0,0)이고 오른쪽 방향이 x+축, 위쪽 방향이 y+축이 된다.
예를들어, 이미지의 pixel 크기가 60×60인 Custom Image의 하단 변(edge)의 정중앙이 POI Item 좌표 지점에 해당된다면 mapView.customImageAnchorPointOffset = MTMapImageOffsetMake(30,0) 와 같이 지정할 수 있다.
값을 지정하지 않는 경우 이미지의 하단 중앙이 Anchor Point로 설정된다.
같이보기 MTMapPOIItemMarkerTypeCustomImage

@property (nonatomic, assign) MTMapImageOffset customImageAnchorPointOffset;

customCalloutBalloonView

POI Item이 사용자에 의해 선택된 경우 나타나는 말풍선 대신 Custom View를 지정할 수 있다.
같이보기 customHighlightedCalloutBalloonView

@property (nonatomic, retain) UIView* customCalloutBalloonView;

customHighlightedCalloutBalloonView

POI Item이 사용자에 의해 선택된 경우 나타나는 말풍선 대신 Custom View를 사용할 경우에만 지정한다.
Custom View가 선택되어진 상태일 때의 View를 별도로 지정할 수 있다.
같이보기 customCalloutBalloonView

@property (nonatomic, retain) UIView* customHighlightedCalloutBalloonView;

Class Methods

poiItem

+ (id)poiItem;

MTMapPOIItem 객체를 생성한다. autorelease 상태로 MTMapPOIItem 객체를 생성하여 리턴한다.

Returns
  • id

Constants

MTMapPOIItemMarkerType

typedef enum {
    MTMapPOIItemMarkerTypeBluePin, /**< 파란색 핀 */
    MTMapPOIItemMarkerTypeRedPin, /**< 빨간색 핀 */
    MTMapPOIItemMarkerTypeYellowPin, /**< 노란색 핀 */
    MTMapPOIItemMarkerTypeCustomImage /**< 개발자가 지정한 POI Item 아이콘 이미지 사용 */
} MTMapPOIItemMarkerType;

POI Item 아이콘(마커) 타입 enumeration
같이보기 MTMapPOIItem.markerType

Constants
  • MTMapPOIItemMarkerTypeBluePin : 파란색
  • MTMapPOIItemMarkerTypeRedPin : 빨간색 핀
  • MTMapPOIItemMarkerTypeYellowPin : 노란색 핀
  • MTMapPOIItemMarkerTypeCustomImage : 개발자가 지정한 POI Item 아이콘 이미지 사용

MTMapPOIItemMarkerSelectedType

typedef enum {
    MTMapPOIItemMarkerSelectedTypeNone, /**< 선택 효과를 사용하지 않음 */
    MTMapPOIItemMarkerSelectedTypeBluePin, /**< 파란색 핀 */
    MTMapPOIItemMarkerSelectedTypeRedPin, /**< 빨간색 핀 */
    MTMapPOIItemMarkerSelectedTypeYellowPin, /**< 노란색 핀 */
    MTMapPOIItemMarkerSelectedTypeCustomImage /**< 개발자가 지정한 POI Item 아이콘 이미지 사용 */
} MTMapPOIItemMarkerSelectedType;

POI Item 아이콘(마커)가 선택되어진 상태 타입 enumeration
같이보기 MTMapPOIItem.markerSelectedType

Constants
  • MTMapPOIItemMarkerSelectedTypeNone : 선택 효과를 사용하지 않음
  • MTMapPOIItemMarkerSelectedTypeBluePin : 파란색 핀
  • MTMapPOIItemMarkerSelectedTypeRedPin : 빨간색 핀
  • MTMapPOIItemMarkerSelectedTypeYellowPin : 노란색 핀
  • MTMapPOIItemMarkerSelectedTypeCustomImage : 개발자가 지정한 POI Item 아이콘 이미지 사용

MTMapPOIItemShowAnimationType

typedef enum {
    MTMapPOIItemShowAnimationTypeNoAnimation, /**< 애니매이션 없음 */
    MTMapPOIItemShowAnimationTypeDropFromHeaven, /**< POI Item 아이콘이 하늘에서 지도 위로 떨어지는 애니매이션 */
    MTMapPOIItemShowAnimationTypeSpringFromGround /**< POI Item 아이콘이 땅위에서 스프링처럼 튀어나오는 듯한 애니매이션 */
} MTMapPOIItemShowAnimationType;

POI Item이 화면에 추가될때 애니매이션 타입 enumeration
같이보기 MTMapPOIItem.showAnimationType

Constants
  • MTMapPOIItemShowAnimationTypeNoAnimation : 애니메이션 없음
  • MTMapPOIItemShowAnimationTypeDropFromHeaven : POI Item 아이콘이 하늘에서 지도 위로 떨어지는 애니매이션
  • MTMapPOIItemShowAnimationTypeSpringFromGround : POI Item 아이콘이 땅위에서 스프링처럼 튀어나오는 듯한 애니매이션

MTMapLocationMarkerItem Properties Class Methods

지도화면 위에 추가되는 현위치 마커 Item에 해당하는 Class이다.
지도화면 위의 현위치 마커를 개발자가 원하는 UI로 바꿔주기 위해서는 MTMapLocationMarkerItem 객체를 생성하여 MTMapView 객체에 등록해 주어야 한다. (updateCurrentLocationMarker:)
Default로 제공되는 현위치 마커를 사용하기 위해서는 MTMapLocationMarkerItem 객체의 값을 nil로 넘겨준다.

Import

#import <MTMapLocationMarkerItem.h>

Task

Marker Item 생성

+ mapLocationMarkerItem

Properties

customImageName

기본 제공되는 Map Location Marker 아이콘 이미지를 사용하지 않고, 개발자가 지정한 Custom 이미지를 사용하고자 하는 경우에 사용하고자 하는 Image 이름을 지정한다.
Custom Image는 Screen Scale = 2.0(Retina Display)에 대응하는 고해상도 이미지를 지정해야 한다.

@property (nonatomic, copy) NSString* customImageName;

customTrackingImageName

기본 제공되는 Map Location Marker의 Tracking 중인 아이콘 이미지를 사용하지 않고, 개발자가 지정한 Custom 이미지를 사용하고자 하는 경우에 사용하고자 하는 Image 이름을 지정한다.
Custom Image는 Screen Scale = 2.0(Retina Display)에 대응하는 고해상도 이미지를 지정해야 한다.

@property (nonatomic, copy) NSString* customTrackingImageName;

customTrackingAnimationImageNames

기본 제공되는 Map Location Marker의 Tracking 중인 아이콘 이미지를 사용하지 않고, 개발자가 지정한 Custom 이미지들로 애니매이션을 보여주고 싶은 경우 애니매이션에 사용하고자 하는 Image 이름들을 순서대로 지정한다.
Custom Image는 Screen Scale = 2.0(Retina Display)에 대응하는 고해상도 이미지를 지정해야 한다.

@property (nonatomic, copy) NSString* customTrackingAnimationImageNames;

customTrackingAnimationDuration

기본 제공되는 Map Location Marker의 Tracking 중인 아이콘 이미지를 사용하지 않고, 개발자가 지정한 Custom 이미지들로 애니매이션을 보여주고 싶은 경우 애니매이션의 duration을 지정한다. default = 1.0 초

@property (nonatomic, assign) float customTrackingAnimationDuration;

customDirectionImageName

기본 제공되는 Map Location Marker의 방향 이미지를 사용하지 않고, 개발자가 지정한 Custom 이미지를 사용하고자 하는 경우에 사용하고자 하는 Image 이름을 지정한다.
Custom Image는 Screen Scale = 2.0(Retina Display)에 대응하는 고해상도 이미지를 지정해야 한다.

@property (nonatomic, copy) NSString* customDirectionImageName;

customImageAnchorPointOffset

customImageName에 지정한 이미지 상의 어느 지점이 현위치 지점에 해당하는 지를 설정한다.
이미지 상의 Pixel 좌표를 지정한다. 이미지의 좌하단이 원점(0,0)이고 오른쪽 방향이 x+축, 위쪽 방향이 y+축이 된다.
예를들어, 이미지의 pixel 크기가 60×60인 Custom Image의 정중앙이 현위치 좌표 지점에 해당된다면 mapView.customImageAnchorPointOffset = MTMapImageOffsetMake(30,30) 와 같이 지정할 수 있다.
값을 지정하지 않는 경우 이미지의 중앙이 Anchor Point로 설정된다.

@property (nonatomic, assign) MTMapImageOffset customImageAnchorPointOffset;

customTrackingImageAnchorPointOffset

기본 제공되는 Map Location Marker 아이콘 이미지를 사용하지 않고, 개발자가 지정한 Custom 이미지를 사용하고자 하는 경우에 사용하고자 하는 Image 이름을 지정한다.
Custom Image는 Screen Scale = 2.0(Retina Display)에 대응하는 고해상도 이미지를 지정해야 한다.

@property (nonatomic, copy) NSString* customImageName;

customDirectionImageAnchorPointOffset

customImageName에 지정한 이미지 상의 어느 지점이 현위치 지점에 해당하는 지를 설정한다.
이미지 상의 Pixel 좌표를 지정한다. 이미지의 좌하단이 원점(0,0)이고 오른쪽 방향이 x+축, 위쪽 방향이 y+축이 된다.
예를들어, 이미지의 pixel 크기가 60×60인 Custom Image의 정중앙이 현위치 좌표 지점에 해당된다면
mapView.customTrackingImageAnchorPointOffset = MTMapImageOffsetMake(30,30) 와 같이 지정할 수 있다.
값을 지정하지 않는 경우 이미지의 중앙이 Anchor Point로 설정된다.

@property (nonatomic, assign) MTMapImageOffset customTrackingImageAnchorPointOffset;

radius

기본 제공되는 Map Location Marker의 Circle 반경 값을 지정한다.

@property (nonatomic, assign) float radius;

strokeColor

기본 제공되는 Map Location Marker의 Circle 선 색상을 지정한다.

@property (nonatomic, retain) UIColor* strokeColor;

fillColor

기본 제공되는 Map Location Marker의 Circle 영역 색상을 지정한다.

@property (nonatomic, retain) UIColor* fillColor;

Class Methods

mapLocationMarkerItem

+(id) mapLocationMarkerItem

MTMapLocationMarkerItem 객체를 생성한다. autorelease 상태로 MTMapLocationMarkerItem 객체를 생성하여 리턴한다.

Returns
  • id

MTMapCircle Properties Class Methods

지도도화면 위에 추가되는 Circle에 해당하는 Class이다.
지도화면 위에 Circle을 추가하기 위해서는MTMapCircle 객체를 생성하여 MTMapView객체에 등록해 주어야 한다.
(MTMapView.addCircle:) Circle의 중심점을 설정하고 선 색상, 선 두께, 영역 색깔, 반경을 지정할 수 있다.
같이보기 MTMapView

Import

#import <MTMapCircle.h>

Task

Circle 생성

+ circle

Properties

centerPoint

Circle의 중심점을 지정한다.

@property (nonatomic, retain) MTMapPoint* centerPoint;

lineWidth

Circle의 선 두께를 지정한다.

@property (nonatomic, assign) float lineWidth;

lineColor

Circle의 선 색상을 지정한다.

@property (nonatomic, retain) UIColor* lineColor;

fillColor

Circle의 영역 색상을 지정한다.

@property (nonatomic, retain) UIColor* fillColor;

radius

Circle의 반경 값을 지정한다.

@property (nonatomic, assign) float radius;

tag

Circle 객체에 임의의 정수값(tag)을 지정할 수 있다.
MTMapView에 등록된 Circle들 중 특정 Circle을 찾기 위한 식별자로 사용할 수 있다.
tag값을 반드시 지정해야 하는 것은 아니다.

@property (nonatomic, assign) NSInteger tag;

Class Methods

circle

+ (id)circle;

MTMapCircle 객체를 생성한다. autorelease 상태로 MTMapCircle 객체를 생성하여 리턴한다.

Returns
  • id

MTMapPolyline Properties Class Methods Instants Methods

지도도화면 위에 추가되는 Polyline에 해당하는 Class이다.
Polyline은 여러 개의 점들을 순서대로 연결한 선들의 집합이다.
지도화면 위에 Polyline을 추가하여 경로나 영역등을 표현할 수 있다.
지도화면 위에 Polyline을 추가하기 위해서는 MTMapPolyline 객체를 생성하여 MTMapView객체에 등록해 주어야 한다.
(MTMapView.addPolyline:) Polyline을 구성하는 좌표 리스트를 설정하고 선 색상을 지정할 수 있다.

Import

#import <MTMapPolyline.h>

Task

Polyline 생성

+ polyLine
+ polyLineWithCapacity:

Polyline에 점 추가하기

- addPoint
- addPoints

Properties

mapPointList

Polyline을 구성하는 점들의 리스트를 조회할 수 있다.

@property (nonatomic, readonly) NSArray* mapPointList;

polylineColor

Polyline의 선 색상을 지정한다.

@property (nonatomic, retain) UIColor* polylineColor;

tag

Polyline 객체에 임의의 정수값(tag)을 지정할 수 있다.
MTMapView에 등록된 Polyline들 중 특정 Polyline을 찾기 위한 식별자로 사용할 수 있다.
tag값을 반드시 지정해야 하는 것은 아니다.

@property (nonatomic, assign) NSInteger tag;

Class Methods

polyLine

+(id)polyLine;

MTMapPolyline 객체를 생성한다. autorelease 상태로 MTMapPolyline 객체를 생성하여 리턴한다.

Returns
  • id

polyLineWithCapacity

+ (id)polyLineWithCapacity:(NSUInteger)capacity;

MTMapPolyline 객체를 생성하고 Polyline을 구성하는 점들을 저장하는 Array의 크기를 미리 지정한다.
autorelease 상태로 MTMapPolyline 객체를 생성하여 리턴한다.
Polyline을 구성하는 점들의 개수를 미리 알수 있는 경우 capacity값을 지정하면 메모리를 효율적으로 사용할 수 있다.

Parameters
  • capacity NSUInteger : Polyline을 구성하는 점들의 좌표를 저장하는 Array의 메모리 할당 크기 (Polyline의 점 개수를 지정한다.)

Instants Methods

addPoint:

- (void)addPoint:(MTMapPoint*)mapPoint;

Polyline에 점 하나를 추가한다.
Polyline 객체가 MTMapView에 등록된 후에는 점들을 추가해도 지도화면에 반영되지 않는다.

Parameters
  • mapPoint MTMapPoint* : 추가하고자 하는 점의 좌표 객체

addPoints:

- (void)addPoints:(NSArray*)mapPointList;

Polyline에 점 리스트를 추가한다.
Polyline 객체가 MTMapView 객체에 등록된 후에는 점들을 추가해도 지도화면에 반영되지 않는다.

Parameters
  • mapPointList NSArray* : 추가하고자 하는 점들의 좌표 객체 리스트

MTMapReverseGeoCoder Instance Methods Class Methods

지도 좌표를 주소 정보로 변환(Reverse Geo-Coding)하는 기능을 제공하는 Class이다.

Import

#import <MTMapReverseGeoCoder.h>

Instance Methods

initWithMapPoint:withDelegate:withOpenAPIKey:

- (id)initWithMapPoint:(MTMapPoint*)mapPoint withDelegate:(id< MTMapReverseGeoCoderDelegate >)delegate withOpenAPIKey:(NSString*)openAPIKey;

MTMapReverseGeoCoder 객체를 생성한다.

주소정보를 알고자 하는 지도 좌표와 Reverse Geo-coding 결과를 통보받을 수 있는 delegate 객체를 설정한다.
비동기(Asynchronous) 방식으로 Reverse Geo-coding을 수행하고자 하는 경우 MTMapReverseGeoCoder 객체를 생성한다.
동기(Synchronous, Blocking) 방식으로 Reverse Geo-coding을 실행하는 경우에는 findAddressForMapPoint:withAddressType: static 메소드를 사용한다.

Parameters
  • mapPoint MTMapPoint* : 주소정보로 변화하고자하는 지도 좌표
  • delegate id< MTMapReverseGeoCoderDelegate > : Reverse Geo-coding 결과를 통보받을 수 있는 delegate 객체
  • openAPIKey NSString* : APP KEY
Returns
  • id

startFindingAddress:

- (void)startFindingAddress;

Reverse Geo-coding(Asynchronous) 서비스를 요청한다.
주소 정보는 비동기 방식으로 delegate 객체에 전달된다.

cancelFindingAddress:

- (void)cancelFindingAddress;

Reverse Geo-coding(Asynchronous) 서비스를 요청을 취소한다.
주소 정보는 비동기 방식으로 delegate 객체에 전달된다.

Class Methods

findAddressForMapPoint:withOpenAPIKey:

+ (id)findAddressForMapPoint:(MTMapPoint*)mapPoint withOpenAPIKey:(NSString*)openAPIKey;

동기(Synchronous, Blocking) 방식으로 Reverse Geo-coding 을 수행한다.
메소드를 호출한 thread는 Reverse Geo-Coding 서비스가 수행되는 동한 block된 후 변환된 주소정보를 리턴받는다.

Parameters
  • mapPoint MTMapPoint* : 주소정보로 변화하고자하는 지도 좌표
  • openAPIKey NSString* : APP KEY
Returns
  • NSString*

MTMapViewDelegate Instance Methods

지도 객체에서 발생하는 이벤트를 처리할 delegate interface protocol이다.
MTMapViewDelegate protocol을 구현한 객체를 생성하여 MTMapView 객체의 delegate property에 설정해야한다.
delegate 객체는 APP KEY 인증 결과 이벤트, 지도 이동/확대/축소, 지도 화면 터치(Single Tap / Double Tap / Long Press) 이벤트, 현위치 트래킹 이벤트, POI 관련 이벤트를 통보받을 수 있다.
같이보기 MTMapView

Import

#import <MTMapView.h>

Instance Methods

mapView:openAPIKeyAuthenticationResultCode:resultMessage:

- (void)mapView:(MTMapView*)mapView openAPIKeyAuthenticationResultCode:(int)resultCode resultMessage:(NSString*)resultMessage;

[APP KEY Authentication] 설정한 APP KEY 값을 APP KEY 인증 서버에 인증한 결과를 통보받을 수 있다.
APP KEY 는 App. Bundle Id 당 하나씩 카카오 개발자 APP KEY 발급 페이지를 통해서 발급 된다.

Parameter
  • mapView MTMapView* : MTMapView 객체
  • resultCode “int” : resultCode 인증 결과 코드, 200 : 인증성공, 200이 아닌경우에는 인증 실패
  • resultMessage “NSSting*” : 인증 결과 메세지, 인증 성공 및 실패에 대한 구체적인 메세지를 제공함

mapView:centerPointMovedTo:

- (void)mapView:(MTMapView*)mapView centerPointMovedTo:(MTMapPoint*)mapCenterPoint;

[Map View Event] 지도 중심 좌표가 이동한 경우 호출된다.

Parameter

mapView:finishedMapMoveAnimation:

- (void)mapView:(MTMapView*)mapView finishedMapMoveAnimation:(MTMapPoint*)mapCenterPoint;

[Map View Event] 지도 화면의 이동이 끝난 뒤 호출된다.

Parameter

mapView:zoomLevelChangedTo:

- (void)mapView:(MTMapView*)mapView zoomLevelChangedTo:(MTMapZoomLevel)zoomLevel;

[Map View Event] 지도 확대/축소 레벨이 변경된 경우 호출된다.

Parameter

mapView:singleTapOnMapPoint:

- (void)mapView:(MTMapView*)mapView singleTapOnMapPoint:(MTMapPoint*)mapPoint;

[Map View Event] 사용자가 지도 위를 터치한 경우 호출된다.

Parameter

mapView:doubleTapOnMapPoint:

- (void)mapView:(MTMapView*)mapView doubleTapOnMapPoint:(MTMapPoint*)mapPoint;

[Map View Event] 사용자가 지도 위 한 지점을 더블 터치한 경우 호출된다.

Parameter

mapView:dragStartedOnMapPoint:

- (void)mapView:(MTMapView*)mapView dragStartedOnMapPoint:(MTMapPoint*)mapPoint;

[Map View Event] 사용자가 지도 위 한 지점을 터치하여 드래그를 시작할 경우 호출된다.

Parameter
  • mapView MTMapView* : MTMapView 객체
  • mapPoint MTMapPoint* : 사용자의 드래그가 시작한 지도 좌표

mapView:dragEndedOnMapPoint:

- (void)mapView:(MTMapView*)mapView dragEndedOnMapPoint:(MTMapPoint*)mapPoint;

[Map View Event] 사용자가 지도 위 한 지점을 터치하여 드래그를 끝낼 경우 호출된다.

Parameter
  • mapView MTMapView* : MTMapView 객체
  • mapPoint MTMapPoint* : 사용자의 드래그가 끝난 지도 좌표

mapView:longPressOnMapPoint:

- (void)mapView:(MTMapView*)mapView longPressOnMapPoint:(MTMapPoint*)mapPoint;

[Map View Event] 사용자가 지도 위 한 지점을 길게 누른 경우(long press) 호출된다.

Parameter

mapView:updateCurrentLocation:withAccuracy:

- (void)mapView:(MTMapView*)mapView updateCurrentLocation:(MTMapPoint*)location withAccuracy:(MTMapLocationAccuracy)accuracy;

[User Location Tracking] 단말의 현위치 좌표값을 통보받을 수 있다.
MTMapView 클래스의 currentLocationTrackingMode property를 통해서 사용자 현위치 트래킹 기능이 켜진 경우(MTMapCurrentLocationTrackingOnWithoutHeading, MTMapCurrentLocationTrackingOnWithHeading)
단말의 위치에 해당하는 지도 좌표와 위치 정확도가 주기적으로 delegate 객체에 통보된다.

Parameter

mapView:updateDeviceHeading:

- (void)mapView:(MTMapView*)mapView updateDeviceHeading:(MTMapRotationAngle)headingAngle;

[User Location Tracking] 단말의 방향(Heading) 각도값을 통보받을 수 있다.
MTMapView 클래스의 currentLocationTrackingMode property를 통해서 사용자 현위치 트래킹과 나침반 모드가 켜진 경우(MTMapCurrentLocationTrackingOnWithHeading) 단말의 방향 각도값이 주기적으로 delegate 객체에 통보된다.

Parameter

mapView:selectedPOIItem:

- (BOOL)mapView:(MTMapView*)mapView selectedPOIItem:(MTMapPOIItem*)poiItem;

[POI Item] 단말 사용자가 POI Item을 선택한 경우 호출된다.
사용자가 MTMapView에 등록된 POI Item 아이콘(마커)를 터치한 경우 호출된다.
MTMapViewDelegate protocol을 구현하는 delegate 객체의 구현의 리턴값(BOOL)에 따라 해당 POI Item 선택 시, POI Item 마커 위에 말풍선(Callout Balloon)을 보여줄지 여부를 선택할 수 있다.

Parameter
Return
  • BOOL : POI Item 선택 시, 말풍선을 보여줄지 여부. YES:터치 시 말풍선이 나타남. NO:터치 시 말풍선이 나타나지 않음.

mapView:touchedCalloutBalloonOfPOIItem:

- (void)mapView:(MTMapView*)mapView touchedCalloutBalloonOfPOIItem:(MTMapPOIItem*)poiItem;

[POI Item] 단말 사용자가 POI Item 아이콘(마커) 위에 나타난 말풍선(Callout Balloon)을 터치한 경우 호출된다.

Parameter

mapView:touchedCalloutBalloonLeftSideOfPOIItem:

- (void)mapView:(MTMapView*)mapView touchedCalloutBalloonLeftSideOfPOIItem:(MTMapPOIItem*)poiItem;

[POI Item] 단말 사용자가 POI Item 아이콘(마커) 위에 나타난 말풍선(Callout Balloon)의 왼쪽 영역을 터치한 경우 호출된다.

Parameter

mapView:touchedCalloutBalloonRightSideOfPOIItem:

- (void)mapView:(MTMapView*)mapView touchedCalloutBalloonRightSideOfPOIItem:(MTMapPOIItem*)poiItem;

[POI Item] 단말 사용자가 POI Item 아이콘(마커) 위에 나타난 말풍선(Callout Balloon)의 오른쪽 영역을 터치한 경우 호출된다.

Parameter

mapView:draggablePOIItem:movedToNewMapPoint:

- (void)mapView:(MTMapView*)mapView draggablePOIItem:(MTMapPOIItem*)poiItem movedToNewMapPoint:(MTMapPoint*)newMapPoint;

[POI Item] 단말 사용자가 길게 누른후(long press) 끌어서(dragging) 위치 이동 가능한 POI Item의 위치를 이동시킨 경우 호출된다.

Parameter
  • mapView MTMapView* : MTMapView 객체
  • poiItem MTMapPOIItem* : 새로운 위치로 이동된 Draggable POI Item 객체
  • newMapPoint MTMapPoint* : 이동된 POI Item의 위치에 해당하는 지도 좌표

MTMapReverseGeoCoderDelegate Instance Methods

Reverse Geo-Coding 결과를 비동기적으로 통보받는 객체가 구현해야하는 interface protocol이다.
같이보기 MTMapReverseGeoCoder

Import

#import <MTMapView.h>

Instance Methods

MTMapReverseGeoCoder:foundAddress:

- (void)MTMapReverseGeoCoder:(MTMapReverseGeoCoder*)rGeoCoder foundAddress:(NSString*)addressString;

주소를 찾은 경우 호출된다.

Parameter
  • rGeoCoder MTMapReverseGeoCoder* : MTMapReverseGeoCoder 객체
  • addressString NSString* : addressString 결과 주소 문자열

MTMapReverseGeoCoder:failedToFindAddressWithError:

- (void)MTMapReverseGeoCoder:(MTMapReverseGeoCoder*)rGeoCoder failedToFindAddressWithError:(NSError*)error;

Reverse Geo-Coding 서비스 호출에 실패한 경우 호출된다.

Parameter