////////////////////////////////////////////////////////// // GENERATED BY FLUTTIFY. DO NOT EDIT IT. ////////////////////////////////////////////////////////// #import "SubHandlerCustom.h" #import "PathSmooth/MASmoothPathTool.h" #import // Dart端一次方法调用所存在的栈, 只有当MethodChannel传递参数受限时, 再启用这个容器 extern NSMutableDictionary* STACK; // Dart端随机存取对象的容器 extern NSMutableDictionary* HEAP; // 日志打印开关 extern BOOL enableLog; @implementation AmapMapFluttifyPlugin (SubHandlerCustom) - (NSDictionary*) getSubHandlerCustom { return @{ @"MAMapRectIsEmpty::MAMapRectIsEmpty": ^(NSObject * registrar, id args, FlutterResult methodResult) { // args // struct arg NSValue* rectValue = (NSValue*) args[@"rect"]; MAMapRect rect; [rectValue getValue:&rect]; // ref // print log if (enableLog) { NSLog(@"fluttify-objc: MAMapRectIsEmpty::MAMapRectIsEmpty(%@)", args[@"rect"]); } // invoke native method BOOL result = MAMapRectIsEmpty(rect); // result // 返回值: Value NSObject* __result__ = @(result); methodResult(__result__); }, @"MALonLatPoint::set_lat_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // args // jsonable arg double lat = [args[@"lat"] doubleValue]; // ref MALonLatPoint* ref = (MALonLatPoint*) args[@"__this__"]; ref.lat = lat; methodResult(@"success"); } methodResult(@"success"); }, @"MALonLatPoint::set_lon_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // args // jsonable arg double lon = [args[@"lon"] doubleValue]; // ref MALonLatPoint* ref = (MALonLatPoint*) args[@"__this__"]; ref.lon = lon; methodResult(@"success"); } methodResult(@"success"); }, @"MASmoothPathTool::set_intensity_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // args // jsonable arg int intensity = [args[@"intensity"] intValue]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; ref.intensity = intensity; methodResult(@"success"); } methodResult(@"success"); }, @"MASmoothPathTool::set_threshHold_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // args // jsonable arg float threshHold = [args[@"threshHold"] floatValue]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; ref.threshHold = threshHold; methodResult(@"success"); } methodResult(@"success"); }, @"MASmoothPathTool::set_noiseThreshhold_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // args // jsonable arg int noiseThreshhold = [args[@"noiseThreshhold"] intValue]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; ref.noiseThreshhold = noiseThreshhold; methodResult(@"success"); } methodResult(@"success"); }, @"MALonLatPoint::get_lat_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { NSMutableArray* resultList = [NSMutableArray array]; for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // ref object MALonLatPoint* ref = (MALonLatPoint*) args[@"__this__"]; double result = ref.lat; // 返回值: Value NSObject* __result__ = @(result); [resultList addObject:__result__]; } methodResult(resultList); }, @"MALonLatPoint::get_lon_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { NSMutableArray* resultList = [NSMutableArray array]; for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // ref object MALonLatPoint* ref = (MALonLatPoint*) args[@"__this__"]; double result = ref.lon; // 返回值: Value NSObject* __result__ = @(result); [resultList addObject:__result__]; } methodResult(resultList); }, @"MASmoothPathTool::get_intensity_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { NSMutableArray* resultList = [NSMutableArray array]; for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // ref object MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; int result = ref.intensity; // 返回值: Value NSObject* __result__ = @(result); [resultList addObject:__result__]; } methodResult(resultList); }, @"MASmoothPathTool::get_threshHold_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { NSMutableArray* resultList = [NSMutableArray array]; for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // ref object MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; float result = ref.threshHold; // 返回值: Value NSObject* __result__ = @(result); [resultList addObject:__result__]; } methodResult(resultList); }, @"MASmoothPathTool::get_noiseThreshhold_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { NSMutableArray* resultList = [NSMutableArray array]; for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // ref object MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; int result = ref.noiseThreshhold; // 返回值: Value NSObject* __result__ = @(result); [resultList addObject:__result__]; } methodResult(resultList); }, @"MASmoothPathTool::pathOptimize": ^(NSObject * registrar, id args, FlutterResult methodResult) { // args // list arg NSArray* originlist = (NSArray*) args[@"originlist"]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // print log if (enableLog) { NSLog(@"fluttify-objc: MASmoothPathTool@%@::pathOptimize(%@)", args[@"refId"], args[@"originlist"]); } // invoke native method NSArray* result = [ref pathOptimize: originlist]; // result // 返回值: 列表 NSMutableArray* __result__ = [NSMutableArray array]; for (int __i__ = 0; __i__ < result.count; __i__++) { NSObject* object = [result objectAtIndex:__i__]; [__result__ addObject: object]; } methodResult(__result__); }, @"MASmoothPathTool::kalmanFilterPath": ^(NSObject * registrar, id args, FlutterResult methodResult) { // args // list arg NSArray* originlist = (NSArray*) args[@"originlist"]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // print log if (enableLog) { NSLog(@"fluttify-objc: MASmoothPathTool@%@::kalmanFilterPath(%@)", args[@"refId"], args[@"originlist"]); } // invoke native method NSArray* result = [ref kalmanFilterPath: originlist]; // result // 返回值: 列表 NSMutableArray* __result__ = [NSMutableArray array]; for (int __i__ = 0; __i__ < result.count; __i__++) { NSObject* object = [result objectAtIndex:__i__]; [__result__ addObject: object]; } methodResult(__result__); }, @"MASmoothPathTool::removeNoisePoint": ^(NSObject * registrar, id args, FlutterResult methodResult) { // args // list arg NSArray* originlist = (NSArray*) args[@"originlist"]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // print log if (enableLog) { NSLog(@"fluttify-objc: MASmoothPathTool@%@::removeNoisePoint(%@)", args[@"refId"], args[@"originlist"]); } // invoke native method NSArray* result = [ref removeNoisePoint: originlist]; // result // 返回值: 列表 NSMutableArray* __result__ = [NSMutableArray array]; for (int __i__ = 0; __i__ < result.count; __i__++) { NSObject* object = [result objectAtIndex:__i__]; [__result__ addObject: object]; } methodResult(__result__); }, @"MASmoothPathTool::kalmanFilterPoint_curLoc": ^(NSObject * registrar, id args, FlutterResult methodResult) { // args // ref arg MALonLatPoint* lastLoc = (MALonLatPoint*) args[@"lastLoc"]; // ref arg MALonLatPoint* curLoc = (MALonLatPoint*) args[@"curLoc"]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // print log if (enableLog) { NSLog(@"fluttify-objc: MASmoothPathTool@%@::kalmanFilterPoint(%@, %@)", args[@"refId"], args[@"lastLoc"], args[@"curLoc"]); } // invoke native method MALonLatPoint* result = [ref kalmanFilterPoint: lastLoc curLoc: curLoc]; // result // return a ref id __result__ = result; methodResult(__result__); }, @"MASmoothPathTool::reducerVerticalThreshold": ^(NSObject * registrar, id args, FlutterResult methodResult) { // args // list arg NSArray* inPoints = (NSArray*) args[@"inPoints"]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // print log if (enableLog) { NSLog(@"fluttify-objc: MASmoothPathTool@%@::reducerVerticalThreshold(%@)", args[@"refId"], args[@"inPoints"]); } // invoke native method NSArray* result = [ref reducerVerticalThreshold: inPoints]; // result // 返回值: 列表 NSMutableArray* __result__ = [NSMutableArray array]; for (int __i__ = 0; __i__ < result.count; __i__++) { NSObject* object = [result objectAtIndex:__i__]; [__result__ addObject: object]; } methodResult(__result__); }, @"ObjectFactory::createMALonLatPoint": ^(NSObject * registrar, id args, FlutterResult methodResult) { // print log if (enableLog) { NSLog(@"ObjectFactory::createMALonLatPoint"); } MALonLatPoint* __this__; if ([((NSDictionary*) args)[@"init"] boolValue]) { __this__ = [[MALonLatPoint alloc] init]; } else { __this__ = [MALonLatPoint alloc]; } methodResult(__this__); if (enableLog) NSLog(@"HEAP: %@", HEAP); }, @"ObjectFactory::createMASmoothPathTool": ^(NSObject * registrar, id args, FlutterResult methodResult) { // print log if (enableLog) { NSLog(@"ObjectFactory::createMASmoothPathTool"); } MASmoothPathTool* __this__; if ([((NSDictionary*) args)[@"init"] boolValue]) { __this__ = [[MASmoothPathTool alloc] init]; } else { __this__ = [MASmoothPathTool alloc]; } methodResult(__this__); if (enableLog) NSLog(@"HEAP: %@", HEAP); }, @"RefClass::isKindOfMALonLatPoint": ^(NSObject * registrar, id args, FlutterResult methodResult) { // 引用对象 NSObject* __this__ = ((NSDictionary*) args)[@"__this__"]; BOOL isTargetType = [__this__ isKindOfClass:[MALonLatPoint class]]; methodResult(@(isTargetType)); }, @"RefClass::isKindOfMASmoothPathTool": ^(NSObject * registrar, id args, FlutterResult methodResult) { // 引用对象 NSObject* __this__ = ((NSDictionary*) args)[@"__this__"]; BOOL isTargetType = [__this__ isKindOfClass:[MASmoothPathTool class]]; methodResult(@(isTargetType)); }, @"ObjectFactory::create_batchMALonLatPoint": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { NSMutableArray* resultList = [NSMutableArray array]; NSNumber* length = (NSNumber*) ((NSDictionary*) argsBatch)[@"length"]; NSNumber* init = (NSNumber*) ((NSDictionary*) argsBatch)[@"init"]; for (int __i__ = 0; __i__ < [length integerValue]; __i__++) { MALonLatPoint* __this__; if ([init boolValue]) { __this__ = [[MALonLatPoint alloc] init]; } else { __this__ = [MALonLatPoint alloc]; } [resultList addObject:__this__]; } methodResult(resultList); if (enableLog) NSLog(@"HEAP: %@", HEAP); }, @"ObjectFactory::create_batchMASmoothPathTool": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { NSMutableArray* resultList = [NSMutableArray array]; NSNumber* length = (NSNumber*) ((NSDictionary*) argsBatch)[@"length"]; NSNumber* init = (NSNumber*) ((NSDictionary*) argsBatch)[@"init"]; for (int __i__ = 0; __i__ < [length integerValue]; __i__++) { MASmoothPathTool* __this__; if ([init boolValue]) { __this__ = [[MASmoothPathTool alloc] init]; } else { __this__ = [MASmoothPathTool alloc]; } [resultList addObject:__this__]; } methodResult(resultList); if (enableLog) NSLog(@"HEAP: %@", HEAP); }, @"MALonLatPoint::get_lat": ^(NSObject * registrar, id args, FlutterResult methodResult) { // print log if (enableLog) { NSLog(@"MALonLatPoint::get_lat"); } // ref object MALonLatPoint* ref = (MALonLatPoint*) args[@"__this__"]; // invoke native method double result = ref.lat; // 返回值: Value NSObject* __result__ = @(result); methodResult(__result__); }, @"MALonLatPoint::get_lon": ^(NSObject * registrar, id args, FlutterResult methodResult) { // print log if (enableLog) { NSLog(@"MALonLatPoint::get_lon"); } // ref object MALonLatPoint* ref = (MALonLatPoint*) args[@"__this__"]; // invoke native method double result = ref.lon; // 返回值: Value NSObject* __result__ = @(result); methodResult(__result__); }, @"MASmoothPathTool::get_intensity": ^(NSObject * registrar, id args, FlutterResult methodResult) { // print log if (enableLog) { NSLog(@"MASmoothPathTool::get_intensity"); } // ref object MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // invoke native method int result = ref.intensity; // 返回值: Value NSObject* __result__ = @(result); methodResult(__result__); }, @"MASmoothPathTool::get_threshHold": ^(NSObject * registrar, id args, FlutterResult methodResult) { // print log if (enableLog) { NSLog(@"MASmoothPathTool::get_threshHold"); } // ref object MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // invoke native method float result = ref.threshHold; // 返回值: Value NSObject* __result__ = @(result); methodResult(__result__); }, @"MASmoothPathTool::get_noiseThreshhold": ^(NSObject * registrar, id args, FlutterResult methodResult) { // print log if (enableLog) { NSLog(@"MASmoothPathTool::get_noiseThreshhold"); } // ref object MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // invoke native method int result = ref.noiseThreshhold; // 返回值: Value NSObject* __result__ = @(result); methodResult(__result__); }, @"MASmoothPathTool::pathOptimize_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { NSMutableArray* resultList = [NSMutableArray array]; for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // args // list arg NSArray* originlist = (NSArray*) args[@"originlist"]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // invoke native method NSArray* result = [ref pathOptimize: originlist]; // result // 返回值: 列表 NSMutableArray* __result__ = [NSMutableArray array]; for (int __i__ = 0; __i__ < result.count; __i__++) { NSObject* object = [result objectAtIndex:__i__]; [__result__ addObject: object]; } [resultList addObject:__result__]; } methodResult(resultList); }, @"MASmoothPathTool::kalmanFilterPath_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { NSMutableArray* resultList = [NSMutableArray array]; for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // args // list arg NSArray* originlist = (NSArray*) args[@"originlist"]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // invoke native method NSArray* result = [ref kalmanFilterPath: originlist]; // result // 返回值: 列表 NSMutableArray* __result__ = [NSMutableArray array]; for (int __i__ = 0; __i__ < result.count; __i__++) { NSObject* object = [result objectAtIndex:__i__]; [__result__ addObject: object]; } [resultList addObject:__result__]; } methodResult(resultList); }, @"MASmoothPathTool::removeNoisePoint_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { NSMutableArray* resultList = [NSMutableArray array]; for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // args // list arg NSArray* originlist = (NSArray*) args[@"originlist"]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // invoke native method NSArray* result = [ref removeNoisePoint: originlist]; // result // 返回值: 列表 NSMutableArray* __result__ = [NSMutableArray array]; for (int __i__ = 0; __i__ < result.count; __i__++) { NSObject* object = [result objectAtIndex:__i__]; [__result__ addObject: object]; } [resultList addObject:__result__]; } methodResult(resultList); }, @"MASmoothPathTool::kalmanFilterPoint_curLoc_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { NSMutableArray* resultList = [NSMutableArray array]; for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // args // ref arg MALonLatPoint* lastLoc = (MALonLatPoint*) args[@"lastLoc"]; // ref arg MALonLatPoint* curLoc = (MALonLatPoint*) args[@"curLoc"]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // invoke native method MALonLatPoint* result = [ref kalmanFilterPoint: lastLoc curLoc: curLoc]; // result // return a ref id __result__ = result; [resultList addObject:__result__]; } methodResult(resultList); }, @"MASmoothPathTool::reducerVerticalThreshold_batch": ^(NSObject * registrar, id argsBatch, FlutterResult methodResult) { NSMutableArray* resultList = [NSMutableArray array]; for (int __i__ = 0; __i__ < ((NSArray*>*) argsBatch).count; __i__++) { NSDictionary* args = [((NSArray*>*) argsBatch) objectAtIndex:__i__]; // args // list arg NSArray* inPoints = (NSArray*) args[@"inPoints"]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; // invoke native method NSArray* result = [ref reducerVerticalThreshold: inPoints]; // result // 返回值: 列表 NSMutableArray* __result__ = [NSMutableArray array]; for (int __i__ = 0; __i__ < result.count; __i__++) { NSObject* object = [result objectAtIndex:__i__]; [__result__ addObject: object]; } [resultList addObject:__result__]; } methodResult(resultList); }, @"MALonLatPoint::set_lat": ^(NSObject * registrar, id args, FlutterResult methodResult) { // print log if (enableLog) { NSLog(@"MALonLatPoint::set_lat"); } // args // jsonable arg double lat = [args[@"lat"] doubleValue]; // ref MALonLatPoint* ref = (MALonLatPoint*) args[@"__this__"]; ref.lat = lat; methodResult(@"success"); }, @"MALonLatPoint::set_lon": ^(NSObject * registrar, id args, FlutterResult methodResult) { // print log if (enableLog) { NSLog(@"MALonLatPoint::set_lon"); } // args // jsonable arg double lon = [args[@"lon"] doubleValue]; // ref MALonLatPoint* ref = (MALonLatPoint*) args[@"__this__"]; ref.lon = lon; methodResult(@"success"); }, @"MASmoothPathTool::set_intensity": ^(NSObject * registrar, id args, FlutterResult methodResult) { // print log if (enableLog) { NSLog(@"MASmoothPathTool::set_intensity"); } // args // jsonable arg int intensity = [args[@"intensity"] intValue]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; ref.intensity = intensity; methodResult(@"success"); }, @"MASmoothPathTool::set_threshHold": ^(NSObject * registrar, id args, FlutterResult methodResult) { // print log if (enableLog) { NSLog(@"MASmoothPathTool::set_threshHold"); } // args // jsonable arg float threshHold = [args[@"threshHold"] floatValue]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; ref.threshHold = threshHold; methodResult(@"success"); }, @"MASmoothPathTool::set_noiseThreshhold": ^(NSObject * registrar, id args, FlutterResult methodResult) { // print log if (enableLog) { NSLog(@"MASmoothPathTool::set_noiseThreshhold"); } // args // jsonable arg int noiseThreshhold = [args[@"noiseThreshhold"] intValue]; // ref MASmoothPathTool* ref = (MASmoothPathTool*) args[@"__this__"]; ref.noiseThreshhold = noiseThreshhold; methodResult(@"success"); }, }; } @end