Map Doc  1.0
iOS-引擎SDK-开放平台
MBRouteBase.h
浏览该文件的文档.
1 //
2 // MBRouteBase.h
3 // iNaviCore
4 //
5 // Created by fanwei on 2/26/13.
6 // Copyright (c) 2013 Mapbar. All rights reserved.
7 //
8 
9 #import <Foundation/Foundation.h>
10 
11 #import "MBNaviCoreBase.h"
12 #import "MBNaviBaseTypes.h"
13 
14 
16 
20 typedef NS_ENUM(NSInteger, MBRouteTmcStyle) {
23 };
24 
28 typedef NS_ENUM(NSInteger, MBRouteType) {
30  MBRouteType_offline = 1, // 离线数据计算的路线
31  MBRouteType_online = 2 // 在线数据计算的路线
32 };
33 
34 struct RouteArrowData ;
36 
38 {
40  NSInteger lenght;
41 };
42 
46 typedef NS_ENUM(NSInteger, MBRerouteReaseon) {
50 };
51 
52 // 路线详情类型,注意不要修改其含义与次序
53 typedef NS_ENUM(NSInteger, MBDirectionsFlag) {
57 };
58 
62 @interface MBRouteBase : NSObject
63 
70 - (instancetype)initWithRouteBase:(void *)base;
71 
78 - (void *)getRouteBase;
79 
87 
92 - (NSInteger)getLength;
93 
100 - (NSString *)getDescription;
101 
108 - (BOOL)hasToll;
109 
115 - (NSInteger)getTollCharge;
116 
123 - (BOOL)hasSailing;
124 
131 - (NSInteger)getEstimatedTime;
132 
139 - (MBRoutePlan *)getPlan;
140 
147 - (int)getStartDirection;
148 
156 
164 
172 
180 - (void)setDirectionsFlag:(MBDirectionsFlag)flag;
181 
189 - (NSInteger)getCurrentIndexInDescriptions:(int)curDistance;
190 
197 - (NSInteger)getDescriptionNumber;
198 
207 - (MBRouteDescriptionItem*)getDescriptionItem:(NSInteger)index curDistance:(NSInteger)curDistance;
208 
216 - (NSInteger)getSegmentNumber;
217 
227 - (BOOL)isEqualRouteBase:(MBRouteBase *)route;
228 
239 - (MBPoint *)getSegmentFinePoints:(NSInteger)index withPointNum:(NSInteger *)num;
240 
252 - (NSInteger)getTmcSections:(NSInteger)maxSection pixels:(NSMutableArray *)pixels tmcStates:(NSMutableArray *)tmcStates;
253 - (NSInteger)getTmcSections:(NSInteger)maxSection outPixels:(UInt32 *)pixels outTmcStates:(UInt8 *)tmcStates;
254 
266 - (NSInteger)getDescriptionItemTmcSection:(NSInteger)index rates:(NSMutableArray *)rates tmcStates:(NSMutableArray *)tmcStates;
267 
273 - (void)enableTmcColors:(BOOL)enable;
274 
280 - (BOOL)isTmcColorsEnabled;
281 
285 - (void)updateTmc;
286 
291 - (NSString *)getTmcTime;
292 
302 - (MBTmcState)getSegmentTmc:(int)index;
303 
311 - (NSInteger)getTrafficLightNumber;
312 
316 @property (nonatomic, assign) MBRouteTmcStyle style;
317 
321 - (void *)handle;
322 
332 - (RouteArrowData *) getArrowPointsByIndex:(NSInteger)index;
333 
339 
349 - (BOOL)hasSegmentTrafficLight:(NSInteger)index;
350 
354 - (NSInteger) getNavInfoId:(NSInteger)index;
355 - (NSString *)getRoadNameWithDescriptionIndex:(NSInteger)index;
356 @end
357 
361 @interface MBDSegment : NSObject
365 @property (nonatomic, readonly, copy) NSString *name;
366 
370 @property (nonatomic, readonly, assign) int pointNumber;
371 
377 - (const MBPoint*)getShapePoints;
378 @end
379 
383 @interface MBRouteEngine : NSObject
391 - (MBDSegment *)grabSegmentsByPoint:(MBPoint *)pos;
392 @end
Definition: MBNaviCoreBase.h:42
void updateTmc()
Definition: MBRouteBase.h:47
Definition: MBRouteBase.h:30
BOOL hasSailing()
MBRerouteReaseon getRerouteReason()
int pointNumber
Definition: MBRouteBase.h:370
Definition: MBRouteBase.h:361
Definition: MBRoutePlan.h:17
MBPoint getLastShapePoint()
MBPoint getFirstShapePoint()
NSInteger getLength()
NSInteger getTollCharge()
MBRouteType getType()
NSInteger getEstimatedTime()
void * getRouteBase()
Definition: MBRouteDescriptionItem.h:15
NSString * getDescription()
Definition: MBRouteBase.h:29
Definition: MBRouteBase.h:48
NSInteger getTrafficLightNumber()
NSInteger getSegmentNumber()
MBRerouteReaseon
Definition: MBRouteBase.h:46
NSString * getTmcTime()
Definition: MBRouteBase.h:37
NSInteger lenght
Definition: MBRouteBase.h:40
MBRect getBoundingBox()
Definition: MBRouteBase.h:62
MBPoint * pts
Definition: MBRouteBase.h:39
BOOL isTmcColorsEnabled()
int getStartDirection()
MBTmcState
Definition: MBNaviBaseTypes.h:19
void * handle()
Definition: MBRouteBase.h:49
MBDirectionsFlag
Definition: MBRouteBase.h:53
MBRoutePlan * getPlan()
MBRouteType
Definition: MBRouteBase.h:28
const MBPoint * getShapePoints()
NSString * name
Definition: MBRouteBase.h:365
返回没有合并的路线详情
Definition: MBRouteBase.h:55
Definition: MBRouteBase.h:383
NSInteger getDescriptionNumber()
Definition: MBRouteBase.h:31
Definition: MBRouteBase.h:22
Definition: MBRouteBase.h:54
Definition: MBNaviCoreBase.h:31
MBRouteTmcStyle style
Definition: MBRouteBase.h:316
返回合并后的路线详情
Definition: MBRouteBase.h:56
Definition: MBRouteBase.h:21
MBRouteTmcStyle
Definition: MBRouteBase.h:20