高德地图SDK(导航) V11.2.0501

Loading...
Searching...
No Matches
Instance Methods | Class Methods | List of all members
MAPolyline Class Reference

`#include <MAPolyline.h>`

Inheritance diagram for MAPolyline:

## Instance Methods
(BOOL) | - setPolylineWithPoints:count:
| 重新设置折线坐标点. since 5.0.0 Reset polyline coordinate points. since 5.0.0
(BOOL) | - setPolylineWithCoordinates:count:
| 重新设置折线坐标点. since 5.0.0 Reset polyline coordinate points. since 5.0.0
Instance Methods inherited from MAMultiPoint
(void) | - getCoordinates:range:
| 将内部的坐标点数据转化为经纬度坐标并拷贝到coords内存中 Convert the internal coordinate point data into latitude and longitude coordinates and copy them to the coords memory
Instance Methods inherited from <MAOverlay>
(CLLocationCoordinate2D) | - coordinate
(MAMapRect) | - boundingMapRect
Instance Methods inherited from <MAAnnotation>
(void) | - setCoordinate:
| 设置标注的坐标，在拖拽时会被调用. Set the coordinates of the annotation, which will be called during dragging

## Class Methods
(instancetype) | + polylineWithPoints:count:
| 根据map point数据生成多段线 Generate polylines based on map point data
(instancetype) | + polylineWithCoordinates:count:
| 根据经纬度坐标数据生成多段线 Generate a polyline based on latitude and longitude coordinate data

## Additional Inherited Members
Protected Attributes inherited from MAShape
NSString * | _title
| 标题 Title
NSString * | _subtitle
| 副标题 Subtitle
Protected Attributes inherited from MABaseOverlay
double | _altitude
| 海拔 Elevation
Properties inherited from MAMultiPoint
MAMapPoint * | points
NSUInteger | pointCount
BOOL | cross180Longitude
Properties inherited from MAShape
NSString * | title
| 标题 Title
NSString * | subtitle
| 副标题 Subtitle
Properties inherited from MABaseOverlay
CLLocationCoordinate2D | coordinate
MAMapRect | boundingMapRect
double | altitude
Properties inherited from <MAAnnotation>
NSString * | title
NSString * | subtitle
double | altitude

## Detailed Description

此类用于定义一个由多个点相连的多段线，点与点之间尾部相连但第一点与最后一个点不相连, 通常MAPolyline是MAPolylineView的model This class is used to define a polyline connected by multiple points, where the points are connected end-to-end but the first point is not connected to the last point. Typically, MAPolyline is the model of MAPolylineView.

## Method Documentation

## ◆ polylineWithCoordinates:count:

+ (instancetype) polylineWithCoordinates: |  | (CLLocationCoordinate2D *) | coords
count: |  | (NSUInteger) | count

根据经纬度坐标数据生成多段线 Generate a polyline based on latitude and longitude coordinate data

Parameters

  coords | 经纬度坐标数据,coords对应的内存会拷贝,调用者负责该内存的释放 Latitude and longitude coordinate data, the memory corresponding to coords will be copied, the caller is responsible for releasing this memory
  count | 经纬度坐标个数 Number of latitude and longitude coordinates

Returns
  生成的多段线 generated polylines

## ◆ polylineWithPoints:count:

+ (instancetype) polylineWithPoints: |  | (MAMapPoint *) | points
count: |  | (NSUInteger) | count

根据map point数据生成多段线 Generate polylines based on map point data

Parameters

  points | map point数据,points对应的内存会拷贝,调用者负责该内存的释放 map point data, the memory corresponding to points will be copied, the caller is responsible for releasing this memory
  count | map point个数 number of map points

Returns
  生成的多段线 generated polylines

## ◆ setPolylineWithCoordinates:count:

- (BOOL) setPolylineWithCoordinates: |  | (CLLocationCoordinate2D *) | coords
count: |  | (NSInteger) | count

重新设置折线坐标点. since 5.0.0 Reset polyline coordinate points. since 5.0.0

Parameters

  coords | 指定的经纬度坐标点数组, C数组，内部会做copy，调用者负责内存管理 Specified latitude-longitude coordinate point array, C array, internal copy will be made, caller is responsible for memory management.
  count | 坐标点的个数 Number of coordinate points

Returns
  是否设置成功 Whether the setting is successful

## ◆ setPolylineWithPoints:count:

- (BOOL) setPolylineWithPoints: |  | (MAMapPoint *) | points
count: |  | (NSInteger) | count

重新设置折线坐标点. since 5.0.0 Reset polyline coordinate points. since 5.0.0

Parameters

  points | 指定的直角坐标点数组, C数组，内部会做copy，调用者负责内存管理 Specified rectangular coordinate point array, C array, internal copy will be made, caller is responsible for memory management.
  count | 坐标点的个数 Number of coordinate points

Returns
  是否设置成功 Whether the setting is successful

The documentation for this class was generated from the following file:

- MAPolyline.h

© 2017 高德信息技术有限公司 版权所有，保留所有权利。