From cd2cb06bb89e71893fa162cdf88eadf9485b46f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20V=C3=A4limaa?= Date: Tue, 21 Jan 2025 11:34:42 +0800 Subject: [PATCH 1/4] refactor: ios groundoverlay improvements --- .../GoogleMapsGroundOverlayControllerTests.m | 15 ++-- .../ios/Classes/FGMGroundOverlayController.h | 32 +++++---- .../ios/Classes/FGMGroundOverlayController.m | 40 +++++------ .../ios/Classes/FGMImageUtils.h | 18 +++++ .../Classes/{FGMUtils.m => FGMImageUtils.m} | 69 +++++++++---------- .../ios/Classes/FGMUtils.h | 18 ----- .../ios/Classes/GoogleMapMarkerController.m | 6 +- .../google_maps_flutter_ios-umbrella.h | 2 +- 8 files changed, 97 insertions(+), 103 deletions(-) create mode 100644 packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.h rename packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/{FGMUtils.m => FGMImageUtils.m} (84%) delete mode 100644 packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMUtils.h diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/RunnerTests/GoogleMapsGroundOverlayControllerTests.m b/packages/google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/RunnerTests/GoogleMapsGroundOverlayControllerTests.m index 7e85c56bf1c1..7c2a7d76163d 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/RunnerTests/GoogleMapsGroundOverlayControllerTests.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/RunnerTests/GoogleMapsGroundOverlayControllerTests.m @@ -7,8 +7,9 @@ @import XCTest; @import GoogleMaps; -#import #import + +#import #import #import "PartiallyMockedMapView.h" @@ -18,10 +19,10 @@ @interface GoogleMapsGroundOverlayControllerTests : XCTestCase @implementation GoogleMapsGroundOverlayControllerTests /// Returns GoogleMapGroundOverlayController object instantiated with position and a mocked map -/// instance +/// instance. /// /// @return An object of FLTGoogleMapGroundOverlayController -- (FGMGroundOverlayController *)groundOverlayControllerWithPositionWithMockedMap { ++ (FGMGroundOverlayController *)groundOverlayControllerWithPositionWithMockedMap { NSString *imagePath = [[NSBundle bundleForClass:[self class]] pathForResource:@"widegamut" ofType:@"png" inDirectory:@"assets"]; @@ -46,10 +47,10 @@ - (FGMGroundOverlayController *)groundOverlayControllerWithPositionWithMockedMap } /// Returns GoogleMapGroundOverlayController object instantiated with bounds and a mocked map -/// instance +/// instance. /// /// @return An object of FLTGoogleMapGroundOverlayController -- (FGMGroundOverlayController *)groundOverlayControllerWithBoundsWithMockedMap { ++ (FGMGroundOverlayController *)groundOverlayControllerWithBoundsWithMockedMap { NSString *imagePath = [[NSBundle bundleForClass:[self class]] pathForResource:@"widegamut" ofType:@"png" inDirectory:@"assets"]; @@ -76,7 +77,7 @@ - (FGMGroundOverlayController *)groundOverlayControllerWithBoundsWithMockedMap { - (void)testUpdatingGroundOverlayWithPosition { FGMGroundOverlayController *groundOverlayController = - [self groundOverlayControllerWithPositionWithMockedMap]; + [GoogleMapsGroundOverlayControllerTests groundOverlayControllerWithPositionWithMockedMap]; FGMPlatformLatLng *position = [FGMPlatformLatLng makeWithLatitude:52.4816 longitude:3.1791]; @@ -111,7 +112,7 @@ - (void)testUpdatingGroundOverlayWithPosition { - (void)testUpdatingGroundOverlayWithBounds { FGMGroundOverlayController *groundOverlayController = - [self groundOverlayControllerWithBoundsWithMockedMap]; + [GoogleMapsGroundOverlayControllerTests groundOverlayControllerWithBoundsWithMockedMap]; FGMPlatformLatLngBounds *bounds = [FGMPlatformLatLngBounds makeWithNortheast:[FGMPlatformLatLng makeWithLatitude:54.4816 longitude:5.1791] diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.h b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.h index b8e479406a7a..c455de651041 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.h +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.h @@ -7,22 +7,24 @@ #import "messages.g.h" +NS_ASSUME_NONNULL_BEGIN + /// Controller of a single ground overlay on the map. @interface FGMGroundOverlayController : NSObject /// The ground overlay this controller handles. -@property(strong, nonatomic) GMSGroundOverlay *_Nonnull groundOverlay; +@property(strong, nonatomic) GMSGroundOverlay *groundOverlay; /// Whether ground overlay is created with bounds or position. -@property(nonatomic, assign) BOOL isCreatedWithBounds; +@property(nonatomic, assign, getter=isCreatedWithBounds) BOOL createdWithBounds; /// Zoom level when ground overlay is initialized with position. @property(nonatomic, strong, nullable) NSNumber *zoomLevel; /// Initializes an instance of this class with a GMSGroundOverlay, a map view, and identifier. -- (instancetype _Nullable)initWithGroundOverlay:(GMSGroundOverlay *_Nonnull)groundOverlay - identifier:(NSString *_Nonnull)identifier - mapView:(GMSMapView *_Nonnull)mapView +- (instancetype _Nullable)initWithGroundOverlay:(GMSGroundOverlay *)groundOverlay + identifier:(NSString *)identifier + mapView:(GMSMapView *)mapView isCreatedWithBounds:(BOOL)isCreatedWithBounds; /// Removes this ground overlay from the map. @@ -33,25 +35,27 @@ @interface FLTGroundOverlaysController : NSObject /// Initializes the controller with a GMSMapView, callback handler and registrar. -- (instancetype _Nullable)initWithMapView:(GMSMapView *_Nonnull)mapView - callbackHandler:(FGMMapsCallbackApi *_Nonnull)callbackHandler - registrar:(NSObject *_Nonnull)registrar; +- (instancetype _Nullable)initWithMapView:(GMSMapView *)mapView + callbackHandler:(FGMMapsCallbackApi *)callbackHandler + registrar:(NSObject *)registrar; /// Adds ground overlays to the map. -- (void)addGroundOverlays:(NSArray *_Nonnull)groundOverlaysToAdd; +- (void)addGroundOverlays:(NSArray *)groundOverlaysToAdd; /// Updates ground overlays on the map. -- (void)changeGroundOverlays:(NSArray *_Nonnull)groundOverlaysToChange; +- (void)changeGroundOverlays:(NSArray *)groundOverlaysToChange; /// Removes ground overlays from the map. -- (void)removeGroundOverlaysWithIdentifiers:(NSArray *_Nonnull)identifiers; +- (void)removeGroundOverlaysWithIdentifiers:(NSArray *)identifiers; /// Called when a ground overlay is tapped on the map. -- (void)didTapGroundOverlayWithIdentifier:(NSString *_Nonnull)identifier; +- (void)didTapGroundOverlayWithIdentifier:(NSString *)identifier; /// Returns true if a ground overlay with the given identifier exists on the map. -- (bool)hasGroundOverlaysWithIdentifier:(NSString *_Nonnull)identifier; +- (bool)hasGroundOverlaysWithIdentifier:(NSString *)identifier; /// Returns FGMPlatformGroundOverlay for identifier. -- (nullable FGMPlatformGroundOverlay *)groundOverlayWithIdentifier:(NSString *_Nonnull)identifier; +- (nullable FGMPlatformGroundOverlay *)groundOverlayWithIdentifier:(NSString *)identifier; @end + +NS_ASSUME_NONNULL_END diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.m index e5be82287c98..d5c3f3eace8a 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.m @@ -3,7 +3,8 @@ // found in the LICENSE file. #import "FGMGroundOverlayController.h" -#import "FGMUtils.h" + +#import "FGMImageUtils.h" #import "FLTGoogleMapJSONConversions.h" @interface FGMGroundOverlayController () @@ -24,7 +25,7 @@ - (instancetype)initWithGroundOverlay:(GMSGroundOverlay *)groundOverlay _groundOverlay = groundOverlay; _mapView = mapView; _groundOverlay.userData = @[ identifier ]; - _isCreatedWithBounds = isCreatedWithBounds; + _createdWithBounds = isCreatedWithBounds; } return self; } @@ -77,13 +78,11 @@ - (void)updateFromPlatformGroundOverlay:(FGMPlatformGroundOverlay *)groundOverla [self setVisible:groundOverlay.visible]; [self setZIndex:(int)groundOverlay.zIndex]; [self setAnchor:CGPointMake(groundOverlay.anchor.x, groundOverlay.anchor.y)]; - UIImage *image = [FGMUtils iconFromBitmap:groundOverlay.image - registrar:registrar - screenScale:screenScale]; + UIImage *image = IconFromBitmap(groundOverlay.image, registrar, screenScale); [self setIcon:image]; [self setBearing:groundOverlay.bearing]; [self setTransparency:groundOverlay.transparency]; - if (_isCreatedWithBounds) { + if ([self isCreatedWithBounds]) { [self setPositionFromBounds:[[GMSCoordinateBounds alloc] initWithCoordinate:CLLocationCoordinate2DMake( groundOverlay.bounds.northeast.latitude, @@ -104,7 +103,7 @@ @interface FLTGroundOverlaysController () /// A map from ground overlay id to the controller that manages it. @property(strong, nonatomic) NSMutableDictionary - *groundOverlayIdentifierToController; + *groundOverlayControllerByIdentifier; /// A callback api for the map interactions. @property(strong, nonatomic) FGMMapsCallbackApi *callbackHandler; @@ -126,7 +125,7 @@ - (instancetype)initWithMapView:(GMSMapView *)mapView if (self) { _callbackHandler = callbackHandler; _mapView = mapView; - _groundOverlayIdentifierToController = [[NSMutableDictionary alloc] init]; + _groundOverlayControllerByIdentifier = [[NSMutableDictionary alloc] init]; _registrar = registrar; } return self; @@ -150,18 +149,14 @@ - (void)addGroundOverlays:(NSArray *)groundOverlaysT coordinate:CLLocationCoordinate2DMake( groundOverlay.bounds.southwest.latitude, groundOverlay.bounds.southwest.longitude)] - icon:[FGMUtils iconFromBitmap:groundOverlay.image - registrar:self.registrar - screenScale:[self getScreenScale]]]; + icon:IconFromBitmap(groundOverlay.image, self.registrar, [self getScreenScale])]; } else { NSAssert(groundOverlay.zoomLevel != nil, @"If ground overlay is initialized with position, zoomLevel is required"); gmsOverlay = [GMSGroundOverlay groundOverlayWithPosition:CLLocationCoordinate2DMake(groundOverlay.position.latitude, groundOverlay.position.longitude) - icon:[FGMUtils iconFromBitmap:groundOverlay.image - registrar:self.registrar - screenScale:[self getScreenScale]] + icon:IconFromBitmap(groundOverlay.image, self.registrar, [self getScreenScale]) zoomLevel:[groundOverlay.zoomLevel doubleValue]]; } FGMGroundOverlayController *controller = @@ -173,14 +168,14 @@ - (void)addGroundOverlays:(NSArray *)groundOverlaysT [controller updateFromPlatformGroundOverlay:groundOverlay registrar:self.registrar screenScale:[self getScreenScale]]; - self.groundOverlayIdentifierToController[identifier] = controller; + self.groundOverlayControllerByIdentifier[identifier] = controller; } } - (void)changeGroundOverlays:(NSArray *)groundOverlaysToChange { for (FGMPlatformGroundOverlay *groundOverlay in groundOverlaysToChange) { NSString *identifier = groundOverlay.groundOverlayId; - FGMGroundOverlayController *controller = self.groundOverlayIdentifierToController[identifier]; + FGMGroundOverlayController *controller = self.groundOverlayControllerByIdentifier[identifier]; [controller updateFromPlatformGroundOverlay:groundOverlay registrar:self.registrar screenScale:[self getScreenScale]]; @@ -189,12 +184,12 @@ - (void)changeGroundOverlays:(NSArray *)groundOverla - (void)removeGroundOverlaysWithIdentifiers:(NSArray *)identifiers { for (NSString *identifier in identifiers) { - FGMGroundOverlayController *controller = self.groundOverlayIdentifierToController[identifier]; + FGMGroundOverlayController *controller = self.groundOverlayControllerByIdentifier[identifier]; if (!controller) { continue; } [controller removeGroundOverlay]; - [self.groundOverlayIdentifierToController removeObjectForKey:identifier]; + [self.groundOverlayControllerByIdentifier removeObjectForKey:identifier]; } } @@ -202,7 +197,7 @@ - (void)didTapGroundOverlayWithIdentifier:(NSString *)identifier { if (!identifier) { return; } - FGMGroundOverlayController *controller = self.groundOverlayIdentifierToController[identifier]; + FGMGroundOverlayController *controller = self.groundOverlayControllerByIdentifier[identifier]; if (!controller) { return; } @@ -212,10 +207,7 @@ - (void)didTapGroundOverlayWithIdentifier:(NSString *)identifier { } - (bool)hasGroundOverlaysWithIdentifier:(NSString *)identifier { - if (!identifier) { - return false; - } - return self.groundOverlayIdentifierToController[identifier] != nil; + return self.groundOverlayControllerByIdentifier[identifier] != nil; } - (CGFloat)getScreenScale { @@ -229,7 +221,7 @@ - (CGFloat)getScreenScale { } - (nullable FGMPlatformGroundOverlay *)groundOverlayWithIdentifier:(NSString *)identifier { - FGMGroundOverlayController *controller = self.groundOverlayIdentifierToController[identifier]; + FGMGroundOverlayController *controller = self.groundOverlayControllerByIdentifier[identifier]; if (!controller) { return nil; } diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.h b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.h new file mode 100644 index 000000000000..155b4ecaf459 --- /dev/null +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.h @@ -0,0 +1,18 @@ +// Copyright 2013 The Flutter Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#import +#import +#import "messages.g.h" + +NS_ASSUME_NONNULL_BEGIN + +/// Creates a UIImage from Pigeon bitmap. +UIImage *IconFromBitmap(FGMPlatformBitmap *platformBitmap, + NSObject *registrar, + CGFloat screenScale); +/// Returns a BOOL indicating whether image is considered scalable with the given scale factor from size. +BOOL IsScalableWithScaleFactorFromSize(CGSize originalSize, CGSize targetSize); + +NS_ASSUME_NONNULL_END diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMUtils.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.m similarity index 84% rename from packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMUtils.m rename to packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.m index 993d0a873d5e..4039fba028f5 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMUtils.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.m @@ -2,18 +2,21 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#import "FGMUtils.h" - -@interface FGMUtils () - -@end - -@implementation FGMUtils - -+ (UIImage *)iconFromBitmap:(FGMPlatformBitmap *)platformBitmap - registrar:(NSObject *)registrar - screenScale:(CGFloat)screenScale { - NSAssert(screenScale > 0, @"Screen scale must be greater than 0"); +#import "FGMImageUtils.h" +#import "Foundation/Foundation.h" + +static UIImage * ScaleImage(UIImage *image, double scale); +static UIImage * ScaledImageWithScale(UIImage *image, CGFloat scale); +static UIImage * ScaledImageWithSize(UIImage *image, CGSize size); +static UIImage * ScaledImage(UIImage *image, + NSNumber *width, + NSNumber *height, + CGFloat screenScale); + +UIImage *IconFromBitmap(FGMPlatformBitmap *platformBitmap, + NSObject *registrar, + CGFloat screenScale) { + assert(screenScale > 0 && "Screen scale must be greater than 0"); // See comment in messages.dart for why this is so loosely typed. See also // https://github.com/flutter/flutter/issues/117819. id bitmap = platformBitmap.bitmap; @@ -40,7 +43,7 @@ + (UIImage *)iconFromBitmap:(FGMPlatformBitmap *)platformBitmap // Refer to the flutter google_maps_flutter_platform_interface package for details. FGMPlatformBitmapAssetImage *bitmapAssetImage = bitmap; image = [UIImage imageNamed:[registrar lookupKeyForAsset:bitmapAssetImage.name]]; - image = [self scaleImage:image by:bitmapAssetImage.scale]; + image = ScaleImage(image, bitmapAssetImage.scale); } else if ([bitmap isKindOfClass:[FGMPlatformBitmapBytes class]]) { // Deprecated: This message handling for 'fromBytes' has been replaced by 'bytes'. // Refer to the flutter google_maps_flutter_platform_interface package for details. @@ -62,10 +65,10 @@ + (UIImage *)iconFromBitmap:(FGMPlatformBitmap *)platformBitmap NSNumber *width = bitmapAssetMap.width; NSNumber *height = bitmapAssetMap.height; if (width || height) { - image = [FGMUtils scaledImage:image withScale:screenScale]; - image = [FGMUtils scaledImage:image withWidth:width height:height screenScale:screenScale]; + image = ScaledImageWithScale(image, screenScale); + image = ScaledImage(image, width, height, screenScale); } else { - image = [FGMUtils scaledImage:image withScale:bitmapAssetMap.imagePixelRatio]; + image = ScaledImageWithScale(image, bitmapAssetMap.imagePixelRatio); } } } else if ([bitmap isKindOfClass:[FGMPlatformBitmapBytesMap class]]) { @@ -80,13 +83,10 @@ + (UIImage *)iconFromBitmap:(FGMPlatformBitmap *)platformBitmap if (width || height) { // Before scaling the image, image must be in screenScale. - image = [FGMUtils scaledImage:image withScale:screenScale]; - image = [FGMUtils scaledImage:image - withWidth:width - height:height - screenScale:screenScale]; + image = ScaledImageWithScale(image, screenScale); + image = ScaledImage(image, width, height, screenScale); } else { - image = [FGMUtils scaledImage:image withScale:bitmapBytesMap.imagePixelRatio]; + image = ScaledImageWithScale(image, bitmapBytesMap.imagePixelRatio); } } else { // No scaling, load image from bytes without scale parameter. @@ -106,7 +106,7 @@ + (UIImage *)iconFromBitmap:(FGMPlatformBitmap *)platformBitmap /// flutter google_maps_flutter_platform_interface package which has been replaced by 'bytes' /// message handling. It will be removed when the deprecated image bitmap description type /// 'fromBytes' is removed from the platform interface. -+ (UIImage *)scaleImage:(UIImage *)image by:(double)scale { +UIImage * ScaleImage(UIImage *image, double scale) { if (fabs(scale - 1) > 1e-3) { return [UIImage imageWithCGImage:[image CGImage] scale:(image.scale * scale) @@ -123,7 +123,7 @@ + (UIImage *)scaleImage:(UIImage *)image by:(double)scale { /// @param image The UIImage to scale. /// @param scale The factor by which to scale the image. /// @return UIImage Returns the scaled UIImage. -+ (UIImage *)scaledImage:(UIImage *)image withScale:(CGFloat)scale { +UIImage * ScaledImageWithScale(UIImage *image, CGFloat scale) { if (fabs(scale - image.scale) > DBL_EPSILON) { return [UIImage imageWithCGImage:[image CGImage] scale:scale @@ -140,7 +140,7 @@ + (UIImage *)scaledImage:(UIImage *)image withScale:(CGFloat)scale { /// @param image The UIImage to scale. /// @param size The target CGSize to scale the image to. /// @return UIImage Returns the scaled UIImage. -+ (UIImage *)scaledImage:(UIImage *)image withSize:(CGSize)size { +UIImage * ScaledImageWithSize(UIImage *image, CGSize size) { CGFloat originalPixelWidth = image.size.width * image.scale; CGFloat originalPixelHeight = image.size.height * image.scale; @@ -159,11 +159,11 @@ + (UIImage *)scaledImage:(UIImage *)image withSize:(CGSize)size { // Check if the aspect ratios are approximately equal. CGSize originalPixelSize = CGSizeMake(originalPixelWidth, originalPixelHeight); - if ([FGMUtils isScalableWithScaleFactorFromSize:originalPixelSize toSize:size]) { + if (IsScalableWithScaleFactorFromSize(originalPixelSize, size)) { // Scaled image has close to same aspect ratio, // updating image scale instead of resizing image. CGFloat factor = originalPixelWidth / size.width; - return [FGMUtils scaledImage:image withScale:(image.scale * factor)]; + return ScaledImageWithScale(image, image.scale * factor); } else { // Aspect ratios differ significantly, resize the image. UIGraphicsImageRendererFormat *format = [UIGraphicsImageRendererFormat defaultFormat]; @@ -177,7 +177,7 @@ + (UIImage *)scaledImage:(UIImage *)image withSize:(CGSize)size { }]; // Return image with proper scaling. - return [FGMUtils scaledImage:newImage withScale:image.scale]; + return ScaledImageWithScale(newImage, image.scale); } } @@ -189,10 +189,10 @@ + (UIImage *)scaledImage:(UIImage *)image withSize:(CGSize)size { /// @param height The target height to scale the image to. /// @param screenScale The current screen scale. /// @return UIImage Returns the scaled UIImage. -+ (UIImage *)scaledImage:(UIImage *)image - withWidth:(NSNumber *)width - height:(NSNumber *)height - screenScale:(CGFloat)screenScale { +UIImage * ScaledImage(UIImage *image, + NSNumber *width, + NSNumber *height, + CGFloat screenScale) { if (!width && !height) { return image; } @@ -212,10 +212,10 @@ + (UIImage *)scaledImage:(UIImage *)image CGSize targetSize = CGSizeMake(round(targetWidth * screenScale), round(targetHeight * screenScale)); - return [FGMUtils scaledImage:image withSize:targetSize]; + return ScaledImageWithSize(image, targetSize); } -+ (BOOL)isScalableWithScaleFactorFromSize:(CGSize)originalSize toSize:(CGSize)targetSize { +BOOL IsScalableWithScaleFactorFromSize(CGSize originalSize, CGSize targetSize) { // Select the scaling factor based on the longer side to have good precision. CGFloat scaleFactor = (originalSize.width > originalSize.height) ? (targetSize.width / originalSize.width) @@ -234,4 +234,3 @@ + (BOOL)isScalableWithScaleFactorFromSize:(CGSize)originalSize toSize:(CGSize)ta // if both dimensions are within the threshold. return widthWithinThreshold && heightWithinThreshold; } -@end diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMUtils.h b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMUtils.h deleted file mode 100644 index e52c7e5777df..000000000000 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMUtils.h +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2013 The Flutter Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#import -#import -#import "messages.g.h" - -NS_ASSUME_NONNULL_BEGIN - -@interface FGMUtils : NSObject -+ (UIImage *)iconFromBitmap:(FGMPlatformBitmap *)platformBitmap - registrar:(NSObject *)registrar - screenScale:(CGFloat)screenScale; -+ (BOOL)isScalableWithScaleFactorFromSize:(CGSize)originalSize toSize:(CGSize)targetSize; -@end - -NS_ASSUME_NONNULL_END diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/GoogleMapMarkerController.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/GoogleMapMarkerController.m index f3b0335e4ebb..3a0d0b827503 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/GoogleMapMarkerController.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/GoogleMapMarkerController.m @@ -5,7 +5,7 @@ #import "GoogleMapMarkerController.h" #import "FGMMarkerUserData.h" -#import "FGMUtils.h" +#import "FGMImageUtils.h" #import "FLTGoogleMapJSONConversions.h" @interface FLTGoogleMapMarkerController () @@ -113,9 +113,7 @@ - (void)updateFromPlatformMarker:(FGMPlatformMarker *)platformMarker [self setAlpha:platformMarker.alpha]; [self setAnchor:FGMGetCGPointForPigeonPoint(platformMarker.anchor)]; [self setDraggable:platformMarker.draggable]; - UIImage *image = [FGMUtils iconFromBitmap:platformMarker.icon - registrar:registrar - screenScale:screenScale]; + UIImage *image = IconFromBitmap(platformMarker.icon, registrar, screenScale); [self setIcon:image]; [self setFlat:platformMarker.flat]; [self setConsumeTapEvents:platformMarker.consumeTapEvents]; diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/google_maps_flutter_ios-umbrella.h b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/google_maps_flutter_ios-umbrella.h index 6ea64ecbb4ac..20462b321a3f 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/google_maps_flutter_ios-umbrella.h +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/google_maps_flutter_ios-umbrella.h @@ -6,7 +6,7 @@ #import #import #import -#import +#import #import #import #import From 20107cf90b9152e9e0ead3dd65145b5bbd04d3b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20V=C3=A4limaa?= Date: Tue, 21 Jan 2025 14:43:44 +0800 Subject: [PATCH 2/4] refactor: switch anchor to platformpoint on ios --- .../ios/Classes/FLTGoogleMapJSONConversions.m | 4 +- .../ios/Classes/messages.g.h | 741 +++---- .../ios/Classes/messages.g.m | 1851 +++++++---------- .../lib/src/google_maps_flutter_ios.dart | 6 +- .../lib/src/messages.g.dart | 789 +++---- .../pigeons/messages.dart | 10 +- 6 files changed, 1375 insertions(+), 2026 deletions(-) diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FLTGoogleMapJSONConversions.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FLTGoogleMapJSONConversions.m index 5f44ceb893b5..2b9ac010a294 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FLTGoogleMapJSONConversions.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FLTGoogleMapJSONConversions.m @@ -137,7 +137,7 @@ GMSMapViewType FGMGetMapViewTypeForPigeonMapType(FGMPlatformMapType type) { longitude:groundOverlay.bounds .southWest .longitude]] - anchor:[FGMPlatformDoublePair makeWithX:groundOverlay.anchor.x + anchor:[FGMPlatformPoint makeWithX:groundOverlay.anchor.x y:groundOverlay.anchor.y] transparency:1.0f - groundOverlay.opacity bearing:groundOverlay.bearing @@ -153,7 +153,7 @@ GMSMapViewType FGMGetMapViewTypeForPigeonMapType(FGMPlatformMapType type) { makeWithLatitude:groundOverlay.position.latitude longitude:groundOverlay.position.longitude] bounds:nil - anchor:[FGMPlatformDoublePair makeWithX:groundOverlay.anchor.x + anchor:[FGMPlatformPoint makeWithX:groundOverlay.anchor.x y:groundOverlay.anchor.y] transparency:1.0f - groundOverlay.opacity bearing:groundOverlay.bearing diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.h b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.h index 4cbedd002f0a..c289b6673361 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.h +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.h @@ -1,7 +1,7 @@ // Copyright 2013 The Flutter Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// Autogenerated from Pigeon (v22.7.2), do not edit directly. +// Autogenerated from Pigeon (v22.7.0), do not edit directly. // See also: https://pub.dev/packages/pigeon #import @@ -91,7 +91,6 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { @class FGMPlatformLatLng; @class FGMPlatformLatLngBounds; @class FGMPlatformCameraTargetBounds; -@class FGMPlatformDoublePair; @class FGMPlatformGroundOverlay; @class FGMPlatformMapViewCreationParams; @class FGMPlatformMapConfiguration; @@ -111,26 +110,26 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { @interface FGMPlatformCameraPosition : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithBearing:(double)bearing - target:(FGMPlatformLatLng *)target - tilt:(double)tilt - zoom:(double)zoom; -@property(nonatomic, assign) double bearing; -@property(nonatomic, strong) FGMPlatformLatLng *target; -@property(nonatomic, assign) double tilt; -@property(nonatomic, assign) double zoom; ++ (instancetype)makeWithBearing:(double )bearing + target:(FGMPlatformLatLng *)target + tilt:(double )tilt + zoom:(double )zoom; +@property(nonatomic, assign) double bearing; +@property(nonatomic, strong) FGMPlatformLatLng * target; +@property(nonatomic, assign) double tilt; +@property(nonatomic, assign) double zoom; @end /// Pigeon representation of a CameraUpdate. @interface FGMPlatformCameraUpdate : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithCameraUpdate:(id)cameraUpdate; ++ (instancetype)makeWithCameraUpdate:(id )cameraUpdate; /// This Object must be one of the classes below prefixed with /// PlatformCameraUpdate. Each such class represents a different type of /// camera update, and each holds a different set of data, preventing the /// use of a single unified class. -@property(nonatomic, strong) id cameraUpdate; +@property(nonatomic, strong) id cameraUpdate; @end /// Pigeon equivalent of NewCameraPosition @@ -138,7 +137,7 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithCameraPosition:(FGMPlatformCameraPosition *)cameraPosition; -@property(nonatomic, strong) FGMPlatformCameraPosition *cameraPosition; +@property(nonatomic, strong) FGMPlatformCameraPosition * cameraPosition; @end /// Pigeon equivalent of NewLatLng @@ -146,94 +145,98 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithLatLng:(FGMPlatformLatLng *)latLng; -@property(nonatomic, strong) FGMPlatformLatLng *latLng; +@property(nonatomic, strong) FGMPlatformLatLng * latLng; @end /// Pigeon equivalent of NewLatLngBounds @interface FGMPlatformCameraUpdateNewLatLngBounds : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithBounds:(FGMPlatformLatLngBounds *)bounds padding:(double)padding; -@property(nonatomic, strong) FGMPlatformLatLngBounds *bounds; -@property(nonatomic, assign) double padding; ++ (instancetype)makeWithBounds:(FGMPlatformLatLngBounds *)bounds + padding:(double )padding; +@property(nonatomic, strong) FGMPlatformLatLngBounds * bounds; +@property(nonatomic, assign) double padding; @end /// Pigeon equivalent of NewLatLngZoom @interface FGMPlatformCameraUpdateNewLatLngZoom : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithLatLng:(FGMPlatformLatLng *)latLng zoom:(double)zoom; -@property(nonatomic, strong) FGMPlatformLatLng *latLng; -@property(nonatomic, assign) double zoom; ++ (instancetype)makeWithLatLng:(FGMPlatformLatLng *)latLng + zoom:(double )zoom; +@property(nonatomic, strong) FGMPlatformLatLng * latLng; +@property(nonatomic, assign) double zoom; @end /// Pigeon equivalent of ScrollBy @interface FGMPlatformCameraUpdateScrollBy : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithDx:(double)dx dy:(double)dy; -@property(nonatomic, assign) double dx; -@property(nonatomic, assign) double dy; ++ (instancetype)makeWithDx:(double )dx + dy:(double )dy; +@property(nonatomic, assign) double dx; +@property(nonatomic, assign) double dy; @end /// Pigeon equivalent of ZoomBy @interface FGMPlatformCameraUpdateZoomBy : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithAmount:(double)amount focus:(nullable FGMPlatformPoint *)focus; -@property(nonatomic, assign) double amount; -@property(nonatomic, strong, nullable) FGMPlatformPoint *focus; ++ (instancetype)makeWithAmount:(double )amount + focus:(nullable FGMPlatformPoint *)focus; +@property(nonatomic, assign) double amount; +@property(nonatomic, strong, nullable) FGMPlatformPoint * focus; @end /// Pigeon equivalent of ZoomIn/ZoomOut @interface FGMPlatformCameraUpdateZoom : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithOut:(BOOL)out; -@property(nonatomic, assign) BOOL out; ++ (instancetype)makeWithOut:(BOOL )out; +@property(nonatomic, assign) BOOL out; @end /// Pigeon equivalent of ZoomTo @interface FGMPlatformCameraUpdateZoomTo : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithZoom:(double)zoom; -@property(nonatomic, assign) double zoom; ++ (instancetype)makeWithZoom:(double )zoom; +@property(nonatomic, assign) double zoom; @end /// Pigeon equivalent of the Circle class. @interface FGMPlatformCircle : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithConsumeTapEvents:(BOOL)consumeTapEvents - fillColor:(NSInteger)fillColor - strokeColor:(NSInteger)strokeColor - visible:(BOOL)visible - strokeWidth:(NSInteger)strokeWidth - zIndex:(double)zIndex - center:(FGMPlatformLatLng *)center - radius:(double)radius - circleId:(NSString *)circleId; -@property(nonatomic, assign) BOOL consumeTapEvents; -@property(nonatomic, assign) NSInteger fillColor; -@property(nonatomic, assign) NSInteger strokeColor; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) NSInteger strokeWidth; -@property(nonatomic, assign) double zIndex; -@property(nonatomic, strong) FGMPlatformLatLng *center; -@property(nonatomic, assign) double radius; -@property(nonatomic, copy) NSString *circleId; ++ (instancetype)makeWithConsumeTapEvents:(BOOL )consumeTapEvents + fillColor:(NSInteger )fillColor + strokeColor:(NSInteger )strokeColor + visible:(BOOL )visible + strokeWidth:(NSInteger )strokeWidth + zIndex:(double )zIndex + center:(FGMPlatformLatLng *)center + radius:(double )radius + circleId:(NSString *)circleId; +@property(nonatomic, assign) BOOL consumeTapEvents; +@property(nonatomic, assign) NSInteger fillColor; +@property(nonatomic, assign) NSInteger strokeColor; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) NSInteger strokeWidth; +@property(nonatomic, assign) double zIndex; +@property(nonatomic, strong) FGMPlatformLatLng * center; +@property(nonatomic, assign) double radius; +@property(nonatomic, copy) NSString * circleId; @end /// Pigeon equivalent of the Heatmap class. @interface FGMPlatformHeatmap : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithJson:(id)json; ++ (instancetype)makeWithJson:(id )json; /// The heatmap data, as JSON. This should only be set from /// Heatmap.toJson, and the native code must interpret it according to the /// internal implementation details of that method. -@property(nonatomic, strong) id json; +@property(nonatomic, strong) id json; @end /// Pigeon equivalent of the InfoWindow class. @@ -241,11 +244,11 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithTitle:(nullable NSString *)title - snippet:(nullable NSString *)snippet - anchor:(FGMPlatformPoint *)anchor; -@property(nonatomic, copy, nullable) NSString *title; -@property(nonatomic, copy, nullable) NSString *snippet; -@property(nonatomic, strong) FGMPlatformPoint *anchor; + snippet:(nullable NSString *)snippet + anchor:(FGMPlatformPoint *)anchor; +@property(nonatomic, copy, nullable) NSString * title; +@property(nonatomic, copy, nullable) NSString * snippet; +@property(nonatomic, strong) FGMPlatformPoint * anchor; @end /// Pigeon equivalent of Cluster. @@ -253,13 +256,13 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithClusterManagerId:(NSString *)clusterManagerId - position:(FGMPlatformLatLng *)position - bounds:(FGMPlatformLatLngBounds *)bounds - markerIds:(NSArray *)markerIds; -@property(nonatomic, copy) NSString *clusterManagerId; -@property(nonatomic, strong) FGMPlatformLatLng *position; -@property(nonatomic, strong) FGMPlatformLatLngBounds *bounds; -@property(nonatomic, copy) NSArray *markerIds; + position:(FGMPlatformLatLng *)position + bounds:(FGMPlatformLatLngBounds *)bounds + markerIds:(NSArray *)markerIds; +@property(nonatomic, copy) NSString * clusterManagerId; +@property(nonatomic, strong) FGMPlatformLatLng * position; +@property(nonatomic, strong) FGMPlatformLatLngBounds * bounds; +@property(nonatomic, copy) NSArray * markerIds; @end /// Pigeon equivalent of the ClusterManager class. @@ -267,39 +270,39 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithIdentifier:(NSString *)identifier; -@property(nonatomic, copy) NSString *identifier; +@property(nonatomic, copy) NSString * identifier; @end /// Pigeon equivalent of the Marker class. @interface FGMPlatformMarker : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithAlpha:(double)alpha - anchor:(FGMPlatformPoint *)anchor - consumeTapEvents:(BOOL)consumeTapEvents - draggable:(BOOL)draggable - flat:(BOOL)flat - icon:(FGMPlatformBitmap *)icon - infoWindow:(FGMPlatformInfoWindow *)infoWindow - position:(FGMPlatformLatLng *)position - rotation:(double)rotation - visible:(BOOL)visible - zIndex:(double)zIndex - markerId:(NSString *)markerId - clusterManagerId:(nullable NSString *)clusterManagerId; -@property(nonatomic, assign) double alpha; -@property(nonatomic, strong) FGMPlatformPoint *anchor; -@property(nonatomic, assign) BOOL consumeTapEvents; -@property(nonatomic, assign) BOOL draggable; -@property(nonatomic, assign) BOOL flat; -@property(nonatomic, strong) FGMPlatformBitmap *icon; -@property(nonatomic, strong) FGMPlatformInfoWindow *infoWindow; -@property(nonatomic, strong) FGMPlatformLatLng *position; -@property(nonatomic, assign) double rotation; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) double zIndex; -@property(nonatomic, copy) NSString *markerId; -@property(nonatomic, copy, nullable) NSString *clusterManagerId; ++ (instancetype)makeWithAlpha:(double )alpha + anchor:(FGMPlatformPoint *)anchor + consumeTapEvents:(BOOL )consumeTapEvents + draggable:(BOOL )draggable + flat:(BOOL )flat + icon:(FGMPlatformBitmap *)icon + infoWindow:(FGMPlatformInfoWindow *)infoWindow + position:(FGMPlatformLatLng *)position + rotation:(double )rotation + visible:(BOOL )visible + zIndex:(double )zIndex + markerId:(NSString *)markerId + clusterManagerId:(nullable NSString *)clusterManagerId; +@property(nonatomic, assign) double alpha; +@property(nonatomic, strong) FGMPlatformPoint * anchor; +@property(nonatomic, assign) BOOL consumeTapEvents; +@property(nonatomic, assign) BOOL draggable; +@property(nonatomic, assign) BOOL flat; +@property(nonatomic, strong) FGMPlatformBitmap * icon; +@property(nonatomic, strong) FGMPlatformInfoWindow * infoWindow; +@property(nonatomic, strong) FGMPlatformLatLng * position; +@property(nonatomic, assign) double rotation; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) double zIndex; +@property(nonatomic, copy) NSString * markerId; +@property(nonatomic, copy, nullable) NSString * clusterManagerId; @end /// Pigeon equivalent of the Polygon class. @@ -307,25 +310,25 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithPolygonId:(NSString *)polygonId - consumesTapEvents:(BOOL)consumesTapEvents - fillColor:(NSInteger)fillColor - geodesic:(BOOL)geodesic - points:(NSArray *)points - holes:(NSArray *> *)holes - visible:(BOOL)visible - strokeColor:(NSInteger)strokeColor - strokeWidth:(NSInteger)strokeWidth - zIndex:(NSInteger)zIndex; -@property(nonatomic, copy) NSString *polygonId; -@property(nonatomic, assign) BOOL consumesTapEvents; -@property(nonatomic, assign) NSInteger fillColor; -@property(nonatomic, assign) BOOL geodesic; -@property(nonatomic, copy) NSArray *points; -@property(nonatomic, copy) NSArray *> *holes; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) NSInteger strokeColor; -@property(nonatomic, assign) NSInteger strokeWidth; -@property(nonatomic, assign) NSInteger zIndex; + consumesTapEvents:(BOOL )consumesTapEvents + fillColor:(NSInteger )fillColor + geodesic:(BOOL )geodesic + points:(NSArray *)points + holes:(NSArray *> *)holes + visible:(BOOL )visible + strokeColor:(NSInteger )strokeColor + strokeWidth:(NSInteger )strokeWidth + zIndex:(NSInteger )zIndex; +@property(nonatomic, copy) NSString * polygonId; +@property(nonatomic, assign) BOOL consumesTapEvents; +@property(nonatomic, assign) NSInteger fillColor; +@property(nonatomic, assign) BOOL geodesic; +@property(nonatomic, copy) NSArray * points; +@property(nonatomic, copy) NSArray *> * holes; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) NSInteger strokeColor; +@property(nonatomic, assign) NSInteger strokeWidth; +@property(nonatomic, assign) NSInteger zIndex; @end /// Pigeon equivalent of the Polyline class. @@ -333,48 +336,49 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithPolylineId:(NSString *)polylineId - consumesTapEvents:(BOOL)consumesTapEvents - color:(NSInteger)color - geodesic:(BOOL)geodesic - jointType:(FGMPlatformJointType)jointType - patterns:(NSArray *)patterns - points:(NSArray *)points - visible:(BOOL)visible - width:(NSInteger)width - zIndex:(NSInteger)zIndex; -@property(nonatomic, copy) NSString *polylineId; -@property(nonatomic, assign) BOOL consumesTapEvents; -@property(nonatomic, assign) NSInteger color; -@property(nonatomic, assign) BOOL geodesic; + consumesTapEvents:(BOOL )consumesTapEvents + color:(NSInteger )color + geodesic:(BOOL )geodesic + jointType:(FGMPlatformJointType)jointType + patterns:(NSArray *)patterns + points:(NSArray *)points + visible:(BOOL )visible + width:(NSInteger )width + zIndex:(NSInteger )zIndex; +@property(nonatomic, copy) NSString * polylineId; +@property(nonatomic, assign) BOOL consumesTapEvents; +@property(nonatomic, assign) NSInteger color; +@property(nonatomic, assign) BOOL geodesic; /// The joint type. @property(nonatomic, assign) FGMPlatformJointType jointType; /// The pattern data, as a list of pattern items. -@property(nonatomic, copy) NSArray *patterns; -@property(nonatomic, copy) NSArray *points; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) NSInteger width; -@property(nonatomic, assign) NSInteger zIndex; +@property(nonatomic, copy) NSArray * patterns; +@property(nonatomic, copy) NSArray * points; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) NSInteger width; +@property(nonatomic, assign) NSInteger zIndex; @end /// Pigeon equivalent of the PatternItem class. @interface FGMPlatformPatternItem : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithType:(FGMPlatformPatternItemType)type length:(nullable NSNumber *)length; ++ (instancetype)makeWithType:(FGMPlatformPatternItemType)type + length:(nullable NSNumber *)length; @property(nonatomic, assign) FGMPlatformPatternItemType type; -@property(nonatomic, strong, nullable) NSNumber *length; +@property(nonatomic, strong, nullable) NSNumber * length; @end /// Pigeon equivalent of the Tile class. @interface FGMPlatformTile : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithWidth:(NSInteger)width - height:(NSInteger)height - data:(nullable FlutterStandardTypedData *)data; -@property(nonatomic, assign) NSInteger width; -@property(nonatomic, assign) NSInteger height; -@property(nonatomic, strong, nullable) FlutterStandardTypedData *data; ++ (instancetype)makeWithWidth:(NSInteger )width + height:(NSInteger )height + data:(nullable FlutterStandardTypedData *)data; +@property(nonatomic, assign) NSInteger width; +@property(nonatomic, assign) NSInteger height; +@property(nonatomic, strong, nullable) FlutterStandardTypedData * data; @end /// Pigeon equivalent of the TileOverlay class. @@ -382,37 +386,41 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithTileOverlayId:(NSString *)tileOverlayId - fadeIn:(BOOL)fadeIn - transparency:(double)transparency - zIndex:(NSInteger)zIndex - visible:(BOOL)visible - tileSize:(NSInteger)tileSize; -@property(nonatomic, copy) NSString *tileOverlayId; -@property(nonatomic, assign) BOOL fadeIn; -@property(nonatomic, assign) double transparency; -@property(nonatomic, assign) NSInteger zIndex; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) NSInteger tileSize; + fadeIn:(BOOL )fadeIn + transparency:(double )transparency + zIndex:(NSInteger )zIndex + visible:(BOOL )visible + tileSize:(NSInteger )tileSize; +@property(nonatomic, copy) NSString * tileOverlayId; +@property(nonatomic, assign) BOOL fadeIn; +@property(nonatomic, assign) double transparency; +@property(nonatomic, assign) NSInteger zIndex; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) NSInteger tileSize; @end /// Pigeon equivalent of Flutter's EdgeInsets. @interface FGMPlatformEdgeInsets : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithTop:(double)top bottom:(double)bottom left:(double)left right:(double)right; -@property(nonatomic, assign) double top; -@property(nonatomic, assign) double bottom; -@property(nonatomic, assign) double left; -@property(nonatomic, assign) double right; ++ (instancetype)makeWithTop:(double )top + bottom:(double )bottom + left:(double )left + right:(double )right; +@property(nonatomic, assign) double top; +@property(nonatomic, assign) double bottom; +@property(nonatomic, assign) double left; +@property(nonatomic, assign) double right; @end /// Pigeon equivalent of LatLng. @interface FGMPlatformLatLng : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithLatitude:(double)latitude longitude:(double)longitude; -@property(nonatomic, assign) double latitude; -@property(nonatomic, assign) double longitude; ++ (instancetype)makeWithLatitude:(double )latitude + longitude:(double )longitude; +@property(nonatomic, assign) double latitude; +@property(nonatomic, assign) double longitude; @end /// Pigeon equivalent of LatLngBounds. @@ -420,9 +428,9 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithNortheast:(FGMPlatformLatLng *)northeast - southwest:(FGMPlatformLatLng *)southwest; -@property(nonatomic, strong) FGMPlatformLatLng *northeast; -@property(nonatomic, strong) FGMPlatformLatLng *southwest; + southwest:(FGMPlatformLatLng *)southwest; +@property(nonatomic, strong) FGMPlatformLatLng * northeast; +@property(nonatomic, strong) FGMPlatformLatLng * southwest; @end /// Pigeon equivalent of CameraTargetBounds. @@ -431,16 +439,7 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// a target, and having an explicitly unbounded target (null [bounds]). @interface FGMPlatformCameraTargetBounds : NSObject + (instancetype)makeWithBounds:(nullable FGMPlatformLatLngBounds *)bounds; -@property(nonatomic, strong, nullable) FGMPlatformLatLngBounds *bounds; -@end - -/// Pair of double values, such as for an offset or size. -@interface FGMPlatformDoublePair : NSObject -/// `init` unavailable to enforce nonnull fields, see the `make` class method. -- (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithX:(double)x y:(double)y; -@property(nonatomic, assign) double x; -@property(nonatomic, assign) double y; +@property(nonatomic, strong, nullable) FGMPlatformLatLngBounds * bounds; @end /// Pigeon equivalent of the GroundOverlay class. @@ -448,131 +447,133 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithGroundOverlayId:(NSString *)groundOverlayId - image:(FGMPlatformBitmap *)image - position:(nullable FGMPlatformLatLng *)position - bounds:(nullable FGMPlatformLatLngBounds *)bounds - anchor:(nullable FGMPlatformDoublePair *)anchor - transparency:(double)transparency - bearing:(double)bearing - zIndex:(double)zIndex - visible:(BOOL)visible - clickable:(BOOL)clickable - zoomLevel:(nullable NSNumber *)zoomLevel; -@property(nonatomic, copy) NSString *groundOverlayId; -@property(nonatomic, strong) FGMPlatformBitmap *image; -@property(nonatomic, strong, nullable) FGMPlatformLatLng *position; -@property(nonatomic, strong, nullable) FGMPlatformLatLngBounds *bounds; -@property(nonatomic, strong, nullable) FGMPlatformDoublePair *anchor; -@property(nonatomic, assign) double transparency; -@property(nonatomic, assign) double bearing; -@property(nonatomic, assign) double zIndex; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) BOOL clickable; -@property(nonatomic, strong, nullable) NSNumber *zoomLevel; + image:(FGMPlatformBitmap *)image + position:(nullable FGMPlatformLatLng *)position + bounds:(nullable FGMPlatformLatLngBounds *)bounds + anchor:(nullable FGMPlatformPoint *)anchor + transparency:(double )transparency + bearing:(double )bearing + zIndex:(double )zIndex + visible:(BOOL )visible + clickable:(BOOL )clickable + zoomLevel:(nullable NSNumber *)zoomLevel; +@property(nonatomic, copy) NSString * groundOverlayId; +@property(nonatomic, strong) FGMPlatformBitmap * image; +@property(nonatomic, strong, nullable) FGMPlatformLatLng * position; +@property(nonatomic, strong, nullable) FGMPlatformLatLngBounds * bounds; +@property(nonatomic, strong, nullable) FGMPlatformPoint * anchor; +@property(nonatomic, assign) double transparency; +@property(nonatomic, assign) double bearing; +@property(nonatomic, assign) double zIndex; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) BOOL clickable; +@property(nonatomic, strong, nullable) NSNumber * zoomLevel; @end /// Information passed to the platform view creation. @interface FGMPlatformMapViewCreationParams : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype) - makeWithInitialCameraPosition:(FGMPlatformCameraPosition *)initialCameraPosition - mapConfiguration:(FGMPlatformMapConfiguration *)mapConfiguration - initialCircles:(NSArray *)initialCircles - initialMarkers:(NSArray *)initialMarkers - initialPolygons:(NSArray *)initialPolygons - initialPolylines:(NSArray *)initialPolylines - initialHeatmaps:(NSArray *)initialHeatmaps - initialTileOverlays:(NSArray *)initialTileOverlays - initialClusterManagers:(NSArray *)initialClusterManagers - initialGroundOverlays:(NSArray *)initialGroundOverlays; -@property(nonatomic, strong) FGMPlatformCameraPosition *initialCameraPosition; -@property(nonatomic, strong) FGMPlatformMapConfiguration *mapConfiguration; -@property(nonatomic, copy) NSArray *initialCircles; -@property(nonatomic, copy) NSArray *initialMarkers; -@property(nonatomic, copy) NSArray *initialPolygons; -@property(nonatomic, copy) NSArray *initialPolylines; -@property(nonatomic, copy) NSArray *initialHeatmaps; -@property(nonatomic, copy) NSArray *initialTileOverlays; -@property(nonatomic, copy) NSArray *initialClusterManagers; -@property(nonatomic, copy) NSArray *initialGroundOverlays; ++ (instancetype)makeWithInitialCameraPosition:(FGMPlatformCameraPosition *)initialCameraPosition + mapConfiguration:(FGMPlatformMapConfiguration *)mapConfiguration + initialCircles:(NSArray *)initialCircles + initialMarkers:(NSArray *)initialMarkers + initialPolygons:(NSArray *)initialPolygons + initialPolylines:(NSArray *)initialPolylines + initialHeatmaps:(NSArray *)initialHeatmaps + initialTileOverlays:(NSArray *)initialTileOverlays + initialClusterManagers:(NSArray *)initialClusterManagers + initialGroundOverlays:(NSArray *)initialGroundOverlays; +@property(nonatomic, strong) FGMPlatformCameraPosition * initialCameraPosition; +@property(nonatomic, strong) FGMPlatformMapConfiguration * mapConfiguration; +@property(nonatomic, copy) NSArray * initialCircles; +@property(nonatomic, copy) NSArray * initialMarkers; +@property(nonatomic, copy) NSArray * initialPolygons; +@property(nonatomic, copy) NSArray * initialPolylines; +@property(nonatomic, copy) NSArray * initialHeatmaps; +@property(nonatomic, copy) NSArray * initialTileOverlays; +@property(nonatomic, copy) NSArray * initialClusterManagers; +@property(nonatomic, copy) NSArray * initialGroundOverlays; @end /// Pigeon equivalent of MapConfiguration. @interface FGMPlatformMapConfiguration : NSObject + (instancetype)makeWithCompassEnabled:(nullable NSNumber *)compassEnabled - cameraTargetBounds:(nullable FGMPlatformCameraTargetBounds *)cameraTargetBounds - mapType:(nullable FGMPlatformMapTypeBox *)mapType - minMaxZoomPreference:(nullable FGMPlatformZoomRange *)minMaxZoomPreference - rotateGesturesEnabled:(nullable NSNumber *)rotateGesturesEnabled - scrollGesturesEnabled:(nullable NSNumber *)scrollGesturesEnabled - tiltGesturesEnabled:(nullable NSNumber *)tiltGesturesEnabled - trackCameraPosition:(nullable NSNumber *)trackCameraPosition - zoomGesturesEnabled:(nullable NSNumber *)zoomGesturesEnabled - myLocationEnabled:(nullable NSNumber *)myLocationEnabled - myLocationButtonEnabled:(nullable NSNumber *)myLocationButtonEnabled - padding:(nullable FGMPlatformEdgeInsets *)padding - indoorViewEnabled:(nullable NSNumber *)indoorViewEnabled - trafficEnabled:(nullable NSNumber *)trafficEnabled - buildingsEnabled:(nullable NSNumber *)buildingsEnabled - cloudMapId:(nullable NSString *)cloudMapId - style:(nullable NSString *)style; -@property(nonatomic, strong, nullable) NSNumber *compassEnabled; -@property(nonatomic, strong, nullable) FGMPlatformCameraTargetBounds *cameraTargetBounds; -@property(nonatomic, strong, nullable) FGMPlatformMapTypeBox *mapType; -@property(nonatomic, strong, nullable) FGMPlatformZoomRange *minMaxZoomPreference; -@property(nonatomic, strong, nullable) NSNumber *rotateGesturesEnabled; -@property(nonatomic, strong, nullable) NSNumber *scrollGesturesEnabled; -@property(nonatomic, strong, nullable) NSNumber *tiltGesturesEnabled; -@property(nonatomic, strong, nullable) NSNumber *trackCameraPosition; -@property(nonatomic, strong, nullable) NSNumber *zoomGesturesEnabled; -@property(nonatomic, strong, nullable) NSNumber *myLocationEnabled; -@property(nonatomic, strong, nullable) NSNumber *myLocationButtonEnabled; -@property(nonatomic, strong, nullable) FGMPlatformEdgeInsets *padding; -@property(nonatomic, strong, nullable) NSNumber *indoorViewEnabled; -@property(nonatomic, strong, nullable) NSNumber *trafficEnabled; -@property(nonatomic, strong, nullable) NSNumber *buildingsEnabled; -@property(nonatomic, copy, nullable) NSString *cloudMapId; -@property(nonatomic, copy, nullable) NSString *style; + cameraTargetBounds:(nullable FGMPlatformCameraTargetBounds *)cameraTargetBounds + mapType:(nullable FGMPlatformMapTypeBox *)mapType + minMaxZoomPreference:(nullable FGMPlatformZoomRange *)minMaxZoomPreference + rotateGesturesEnabled:(nullable NSNumber *)rotateGesturesEnabled + scrollGesturesEnabled:(nullable NSNumber *)scrollGesturesEnabled + tiltGesturesEnabled:(nullable NSNumber *)tiltGesturesEnabled + trackCameraPosition:(nullable NSNumber *)trackCameraPosition + zoomGesturesEnabled:(nullable NSNumber *)zoomGesturesEnabled + myLocationEnabled:(nullable NSNumber *)myLocationEnabled + myLocationButtonEnabled:(nullable NSNumber *)myLocationButtonEnabled + padding:(nullable FGMPlatformEdgeInsets *)padding + indoorViewEnabled:(nullable NSNumber *)indoorViewEnabled + trafficEnabled:(nullable NSNumber *)trafficEnabled + buildingsEnabled:(nullable NSNumber *)buildingsEnabled + cloudMapId:(nullable NSString *)cloudMapId + style:(nullable NSString *)style; +@property(nonatomic, strong, nullable) NSNumber * compassEnabled; +@property(nonatomic, strong, nullable) FGMPlatformCameraTargetBounds * cameraTargetBounds; +@property(nonatomic, strong, nullable) FGMPlatformMapTypeBox * mapType; +@property(nonatomic, strong, nullable) FGMPlatformZoomRange * minMaxZoomPreference; +@property(nonatomic, strong, nullable) NSNumber * rotateGesturesEnabled; +@property(nonatomic, strong, nullable) NSNumber * scrollGesturesEnabled; +@property(nonatomic, strong, nullable) NSNumber * tiltGesturesEnabled; +@property(nonatomic, strong, nullable) NSNumber * trackCameraPosition; +@property(nonatomic, strong, nullable) NSNumber * zoomGesturesEnabled; +@property(nonatomic, strong, nullable) NSNumber * myLocationEnabled; +@property(nonatomic, strong, nullable) NSNumber * myLocationButtonEnabled; +@property(nonatomic, strong, nullable) FGMPlatformEdgeInsets * padding; +@property(nonatomic, strong, nullable) NSNumber * indoorViewEnabled; +@property(nonatomic, strong, nullable) NSNumber * trafficEnabled; +@property(nonatomic, strong, nullable) NSNumber * buildingsEnabled; +@property(nonatomic, copy, nullable) NSString * cloudMapId; +@property(nonatomic, copy, nullable) NSString * style; @end /// Pigeon representation of an x,y coordinate. @interface FGMPlatformPoint : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithX:(double)x y:(double)y; -@property(nonatomic, assign) double x; -@property(nonatomic, assign) double y; ++ (instancetype)makeWithX:(double )x + y:(double )y; +@property(nonatomic, assign) double x; +@property(nonatomic, assign) double y; @end /// Pigeon representation of a size. @interface FGMPlatformSize : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithWidth:(double)width height:(double)height; -@property(nonatomic, assign) double width; -@property(nonatomic, assign) double height; ++ (instancetype)makeWithWidth:(double )width + height:(double )height; +@property(nonatomic, assign) double width; +@property(nonatomic, assign) double height; @end /// Pigeon equivalent of GMSTileLayer properties. @interface FGMPlatformTileLayer : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithVisible:(BOOL)visible - fadeIn:(BOOL)fadeIn - opacity:(double)opacity - zIndex:(NSInteger)zIndex; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) BOOL fadeIn; -@property(nonatomic, assign) double opacity; -@property(nonatomic, assign) NSInteger zIndex; ++ (instancetype)makeWithVisible:(BOOL )visible + fadeIn:(BOOL )fadeIn + opacity:(double )opacity + zIndex:(NSInteger )zIndex; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) BOOL fadeIn; +@property(nonatomic, assign) double opacity; +@property(nonatomic, assign) NSInteger zIndex; @end /// Pigeon equivalent of MinMaxZoomPreference. @interface FGMPlatformZoomRange : NSObject -+ (instancetype)makeWithMin:(nullable NSNumber *)min max:(nullable NSNumber *)max; -@property(nonatomic, strong, nullable) NSNumber *min; -@property(nonatomic, strong, nullable) NSNumber *max; ++ (instancetype)makeWithMin:(nullable NSNumber *)min + max:(nullable NSNumber *)max; +@property(nonatomic, strong, nullable) NSNumber * min; +@property(nonatomic, strong, nullable) NSNumber * max; @end /// Pigeon equivalent of [BitmapDescriptor]. As there are multiple disjoint @@ -581,7 +582,7 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { @interface FGMPlatformBitmap : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithBitmap:(id)bitmap; ++ (instancetype)makeWithBitmap:(id )bitmap; /// One of [PlatformBitmapAssetMap], [PlatformBitmapAsset], /// [PlatformBitmapAssetImage], [PlatformBitmapBytesMap], /// [PlatformBitmapBytes], or [PlatformBitmapDefaultMarker]. @@ -589,13 +590,13 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// approach allows for the different bitmap implementations to be valid /// argument and return types of the API methods. See /// https://github.com/flutter/flutter/issues/117819. -@property(nonatomic, strong) id bitmap; +@property(nonatomic, strong) id bitmap; @end /// Pigeon equivalent of [DefaultMarker]. @interface FGMPlatformBitmapDefaultMarker : NSObject + (instancetype)makeWithHue:(nullable NSNumber *)hue; -@property(nonatomic, strong, nullable) NSNumber *hue; +@property(nonatomic, strong, nullable) NSNumber * hue; @end /// Pigeon equivalent of [BytesBitmap]. @@ -603,18 +604,19 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithByteData:(FlutterStandardTypedData *)byteData - size:(nullable FGMPlatformSize *)size; -@property(nonatomic, strong) FlutterStandardTypedData *byteData; -@property(nonatomic, strong, nullable) FGMPlatformSize *size; + size:(nullable FGMPlatformSize *)size; +@property(nonatomic, strong) FlutterStandardTypedData * byteData; +@property(nonatomic, strong, nullable) FGMPlatformSize * size; @end /// Pigeon equivalent of [AssetBitmap]. @interface FGMPlatformBitmapAsset : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithName:(NSString *)name pkg:(nullable NSString *)pkg; -@property(nonatomic, copy) NSString *name; -@property(nonatomic, copy, nullable) NSString *pkg; ++ (instancetype)makeWithName:(NSString *)name + pkg:(nullable NSString *)pkg; +@property(nonatomic, copy) NSString * name; +@property(nonatomic, copy, nullable) NSString * pkg; @end /// Pigeon equivalent of [AssetImageBitmap]. @@ -622,11 +624,11 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithName:(NSString *)name - scale:(double)scale - size:(nullable FGMPlatformSize *)size; -@property(nonatomic, copy) NSString *name; -@property(nonatomic, assign) double scale; -@property(nonatomic, strong, nullable) FGMPlatformSize *size; + scale:(double )scale + size:(nullable FGMPlatformSize *)size; +@property(nonatomic, copy) NSString * name; +@property(nonatomic, assign) double scale; +@property(nonatomic, strong, nullable) FGMPlatformSize * size; @end /// Pigeon equivalent of [AssetMapBitmap]. @@ -634,15 +636,15 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithAssetName:(NSString *)assetName - bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling - imagePixelRatio:(double)imagePixelRatio - width:(nullable NSNumber *)width - height:(nullable NSNumber *)height; -@property(nonatomic, copy) NSString *assetName; + bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling + imagePixelRatio:(double )imagePixelRatio + width:(nullable NSNumber *)width + height:(nullable NSNumber *)height; +@property(nonatomic, copy) NSString * assetName; @property(nonatomic, assign) FGMPlatformMapBitmapScaling bitmapScaling; -@property(nonatomic, assign) double imagePixelRatio; -@property(nonatomic, strong, nullable) NSNumber *width; -@property(nonatomic, strong, nullable) NSNumber *height; +@property(nonatomic, assign) double imagePixelRatio; +@property(nonatomic, strong, nullable) NSNumber * width; +@property(nonatomic, strong, nullable) NSNumber * height; @end /// Pigeon equivalent of [BytesMapBitmap]. @@ -650,15 +652,15 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithByteData:(FlutterStandardTypedData *)byteData - bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling - imagePixelRatio:(double)imagePixelRatio - width:(nullable NSNumber *)width - height:(nullable NSNumber *)height; -@property(nonatomic, strong) FlutterStandardTypedData *byteData; + bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling + imagePixelRatio:(double )imagePixelRatio + width:(nullable NSNumber *)width + height:(nullable NSNumber *)height; +@property(nonatomic, strong) FlutterStandardTypedData * byteData; @property(nonatomic, assign) FGMPlatformMapBitmapScaling bitmapScaling; -@property(nonatomic, assign) double imagePixelRatio; -@property(nonatomic, strong, nullable) NSNumber *width; -@property(nonatomic, strong, nullable) NSNumber *height; +@property(nonatomic, assign) double imagePixelRatio; +@property(nonatomic, strong, nullable) NSNumber * width; +@property(nonatomic, strong, nullable) NSNumber * height; @end /// The codec used by all APIs. @@ -674,85 +676,53 @@ NSObject *FGMGetMessagesCodec(void); /// /// Only non-null configuration values will result in updates; options with /// null values will remain unchanged. -- (void)updateWithMapConfiguration:(FGMPlatformMapConfiguration *)configuration - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateWithMapConfiguration:(FGMPlatformMapConfiguration *)configuration error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of circles on the map. -- (void)updateCirclesByAdding:(NSArray *)toAdd - changing:(NSArray *)toChange - removing:(NSArray *)idsToRemove - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateCirclesByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of heatmaps on the map. -- (void)updateHeatmapsByAdding:(NSArray *)toAdd - changing:(NSArray *)toChange - removing:(NSArray *)idsToRemove - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateHeatmapsByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of custer managers for clusters on the map. -- (void)updateClusterManagersByAdding:(NSArray *)toAdd - removing:(NSArray *)idsToRemove - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateClusterManagersByAdding:(NSArray *)toAdd removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of markers on the map. -- (void)updateMarkersByAdding:(NSArray *)toAdd - changing:(NSArray *)toChange - removing:(NSArray *)idsToRemove - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateMarkersByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of polygonss on the map. -- (void)updatePolygonsByAdding:(NSArray *)toAdd - changing:(NSArray *)toChange - removing:(NSArray *)idsToRemove - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updatePolygonsByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of polylines on the map. -- (void)updatePolylinesByAdding:(NSArray *)toAdd - changing:(NSArray *)toChange - removing:(NSArray *)idsToRemove - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updatePolylinesByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of tile overlays on the map. -- (void)updateTileOverlaysByAdding:(NSArray *)toAdd - changing:(NSArray *)toChange - removing:(NSArray *)idsToRemove - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateTileOverlaysByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of ground overlays on the map. -- (void)updateGroundOverlaysByAdding:(NSArray *)toAdd - changing:(NSArray *)toChange - removing:(NSArray *)idsToRemove - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateGroundOverlaysByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; /// Gets the screen coordinate for the given map location. /// /// @return `nil` only when `error != nil`. -- (nullable FGMPlatformPoint *)screenCoordinatesForLatLng:(FGMPlatformLatLng *)latLng - error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable FGMPlatformPoint *)screenCoordinatesForLatLng:(FGMPlatformLatLng *)latLng error:(FlutterError *_Nullable *_Nonnull)error; /// Gets the map location for the given screen coordinate. /// /// @return `nil` only when `error != nil`. -- (nullable FGMPlatformLatLng *)latLngForScreenCoordinate:(FGMPlatformPoint *)screenCoordinate - error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable FGMPlatformLatLng *)latLngForScreenCoordinate:(FGMPlatformPoint *)screenCoordinate error:(FlutterError *_Nullable *_Nonnull)error; /// Gets the map region currently displayed on the map. /// /// @return `nil` only when `error != nil`. - (nullable FGMPlatformLatLngBounds *)visibleMapRegion:(FlutterError *_Nullable *_Nonnull)error; /// Moves the camera according to [cameraUpdate] immediately, with no /// animation. -- (void)moveCameraWithUpdate:(FGMPlatformCameraUpdate *)cameraUpdate - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)moveCameraWithUpdate:(FGMPlatformCameraUpdate *)cameraUpdate error:(FlutterError *_Nullable *_Nonnull)error; /// Moves the camera according to [cameraUpdate], animating the update. -- (void)animateCameraWithUpdate:(FGMPlatformCameraUpdate *)cameraUpdate - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)animateCameraWithUpdate:(FGMPlatformCameraUpdate *)cameraUpdate error:(FlutterError *_Nullable *_Nonnull)error; /// Gets the current map zoom level. /// /// @return `nil` only when `error != nil`. - (nullable NSNumber *)currentZoomLevel:(FlutterError *_Nullable *_Nonnull)error; /// Show the info window for the marker with the given ID. -- (void)showInfoWindowForMarkerWithIdentifier:(NSString *)markerId - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)showInfoWindowForMarkerWithIdentifier:(NSString *)markerId error:(FlutterError *_Nullable *_Nonnull)error; /// Hide the info window for the marker with the given ID. -- (void)hideInfoWindowForMarkerWithIdentifier:(NSString *)markerId - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)hideInfoWindowForMarkerWithIdentifier:(NSString *)markerId error:(FlutterError *_Nullable *_Nonnull)error; /// Returns true if the marker with the given ID is currently displaying its /// info window. /// /// @return `nil` only when `error != nil`. -- (nullable NSNumber *) - isShowingInfoWindowForMarkerWithIdentifier:(NSString *)markerId - error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable NSNumber *)isShowingInfoWindowForMarkerWithIdentifier:(NSString *)markerId error:(FlutterError *_Nullable *_Nonnull)error; /// Sets the style to the given map style string, where an empty string /// indicates that the style should be cleared. /// @@ -766,93 +736,66 @@ NSObject *FGMGetMessagesCodec(void); /// is no way to return failures from map initialization. - (nullable NSString *)lastStyleError:(FlutterError *_Nullable *_Nonnull)error; /// Clears the cache of tiles previously requseted from the tile provider. -- (void)clearTileCacheForOverlayWithIdentifier:(NSString *)tileOverlayId - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)clearTileCacheForOverlayWithIdentifier:(NSString *)tileOverlayId error:(FlutterError *_Nullable *_Nonnull)error; /// Takes a snapshot of the map and returns its image data. -- (nullable FlutterStandardTypedData *)takeSnapshotWithError: - (FlutterError *_Nullable *_Nonnull)error; +- (nullable FlutterStandardTypedData *)takeSnapshotWithError:(FlutterError *_Nullable *_Nonnull)error; @end -extern void SetUpFGMMapsApi(id binaryMessenger, - NSObject *_Nullable api); +extern void SetUpFGMMapsApi(id binaryMessenger, NSObject *_Nullable api); + +extern void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObject *_Nullable api, NSString *messageChannelSuffix); -extern void SetUpFGMMapsApiWithSuffix(id binaryMessenger, - NSObject *_Nullable api, - NSString *messageChannelSuffix); /// Interface for calls from the native SDK to Dart. @interface FGMMapsCallbackApi : NSObject - (instancetype)initWithBinaryMessenger:(id)binaryMessenger; -- (instancetype)initWithBinaryMessenger:(id)binaryMessenger - messageChannelSuffix:(nullable NSString *)messageChannelSuffix; +- (instancetype)initWithBinaryMessenger:(id)binaryMessenger messageChannelSuffix:(nullable NSString *)messageChannelSuffix; /// Called when the map camera starts moving. - (void)didStartCameraMoveWithCompletion:(void (^)(FlutterError *_Nullable))completion; /// Called when the map camera moves. -- (void)didMoveCameraToPosition:(FGMPlatformCameraPosition *)cameraPosition - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didMoveCameraToPosition:(FGMPlatformCameraPosition *)cameraPosition completion:(void (^)(FlutterError *_Nullable))completion; /// Called when the map camera stops moving. - (void)didIdleCameraWithCompletion:(void (^)(FlutterError *_Nullable))completion; /// Called when the map, not a specifc map object, is tapped. -- (void)didTapAtPosition:(FGMPlatformLatLng *)position - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapAtPosition:(FGMPlatformLatLng *)position completion:(void (^)(FlutterError *_Nullable))completion; /// Called when the map, not a specifc map object, is long pressed. -- (void)didLongPressAtPosition:(FGMPlatformLatLng *)position - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didLongPressAtPosition:(FGMPlatformLatLng *)position completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a marker is tapped. -- (void)didTapMarkerWithIdentifier:(NSString *)markerId - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapMarkerWithIdentifier:(NSString *)markerId completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a marker drag starts. -- (void)didStartDragForMarkerWithIdentifier:(NSString *)markerId - atPosition:(FGMPlatformLatLng *)position - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didStartDragForMarkerWithIdentifier:(NSString *)markerId atPosition:(FGMPlatformLatLng *)position completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a marker drag updates. -- (void)didDragMarkerWithIdentifier:(NSString *)markerId - atPosition:(FGMPlatformLatLng *)position - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didDragMarkerWithIdentifier:(NSString *)markerId atPosition:(FGMPlatformLatLng *)position completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a marker drag ends. -- (void)didEndDragForMarkerWithIdentifier:(NSString *)markerId - atPosition:(FGMPlatformLatLng *)position - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didEndDragForMarkerWithIdentifier:(NSString *)markerId atPosition:(FGMPlatformLatLng *)position completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a marker's info window is tapped. -- (void)didTapInfoWindowOfMarkerWithIdentifier:(NSString *)markerId - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapInfoWindowOfMarkerWithIdentifier:(NSString *)markerId completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a circle is tapped. -- (void)didTapCircleWithIdentifier:(NSString *)circleId - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapCircleWithIdentifier:(NSString *)circleId completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a marker cluster is tapped. -- (void)didTapCluster:(FGMPlatformCluster *)cluster - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapCluster:(FGMPlatformCluster *)cluster completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a polygon is tapped. -- (void)didTapPolygonWithIdentifier:(NSString *)polygonId - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapPolygonWithIdentifier:(NSString *)polygonId completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a polyline is tapped. -- (void)didTapPolylineWithIdentifier:(NSString *)polylineId - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapPolylineWithIdentifier:(NSString *)polylineId completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a ground overlay is tapped. -- (void)didTapGroundOverlayWithIdentifier:(NSString *)groundOverlayId - completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapGroundOverlayWithIdentifier:(NSString *)groundOverlayId completion:(void (^)(FlutterError *_Nullable))completion; /// Called to get data for a map tile. -- (void)tileWithOverlayIdentifier:(NSString *)tileOverlayId - location:(FGMPlatformPoint *)location - zoom:(NSInteger)zoom - completion:(void (^)(FGMPlatformTile *_Nullable, - FlutterError *_Nullable))completion; +- (void)tileWithOverlayIdentifier:(NSString *)tileOverlayId location:(FGMPlatformPoint *)location zoom:(NSInteger)zoom completion:(void (^)(FGMPlatformTile *_Nullable, FlutterError *_Nullable))completion; @end + /// Dummy interface to force generation of the platform view creation params, /// which are not used in any Pigeon calls, only the platform view creation /// call made internally by Flutter. @protocol FGMMapsPlatformViewApi -- (void)createViewType:(nullable FGMPlatformMapViewCreationParams *)type - error:(FlutterError *_Nullable *_Nonnull)error; +- (void)createViewType:(nullable FGMPlatformMapViewCreationParams *)type error:(FlutterError *_Nullable *_Nonnull)error; @end -extern void SetUpFGMMapsPlatformViewApi(id binaryMessenger, - NSObject *_Nullable api); +extern void SetUpFGMMapsPlatformViewApi(id binaryMessenger, NSObject *_Nullable api); + +extern void SetUpFGMMapsPlatformViewApiWithSuffix(id binaryMessenger, NSObject *_Nullable api, NSString *messageChannelSuffix); -extern void SetUpFGMMapsPlatformViewApiWithSuffix(id binaryMessenger, - NSObject *_Nullable api, - NSString *messageChannelSuffix); /// Inspector API only intended for use in integration tests. @protocol FGMMapsInspectorApi @@ -872,27 +815,17 @@ extern void SetUpFGMMapsPlatformViewApiWithSuffix(id bin - (nullable NSNumber *)isMyLocationButtonEnabledWithError:(FlutterError *_Nullable *_Nonnull)error; /// @return `nil` only when `error != nil`. - (nullable NSNumber *)isTrafficEnabledWithError:(FlutterError *_Nullable *_Nonnull)error; -- (nullable FGMPlatformTileLayer *)tileOverlayWithIdentifier:(NSString *)tileOverlayId - error: - (FlutterError *_Nullable *_Nonnull)error; -- (nullable FGMPlatformGroundOverlay *) - groundOverlayWithIdentifier:(NSString *)groundOverlayId - error:(FlutterError *_Nullable *_Nonnull)error; -- (nullable FGMPlatformHeatmap *)heatmapWithIdentifier:(NSString *)heatmapId - error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable FGMPlatformTileLayer *)tileOverlayWithIdentifier:(NSString *)tileOverlayId error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable FGMPlatformGroundOverlay *)groundOverlayWithIdentifier:(NSString *)groundOverlayId error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable FGMPlatformHeatmap *)heatmapWithIdentifier:(NSString *)heatmapId error:(FlutterError *_Nullable *_Nonnull)error; /// @return `nil` only when `error != nil`. - (nullable FGMPlatformZoomRange *)zoomRange:(FlutterError *_Nullable *_Nonnull)error; /// @return `nil` only when `error != nil`. -- (nullable NSArray *) - clustersWithIdentifier:(NSString *)clusterManagerId - error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable NSArray *)clustersWithIdentifier:(NSString *)clusterManagerId error:(FlutterError *_Nullable *_Nonnull)error; @end -extern void SetUpFGMMapsInspectorApi(id binaryMessenger, - NSObject *_Nullable api); +extern void SetUpFGMMapsInspectorApi(id binaryMessenger, NSObject *_Nullable api); -extern void SetUpFGMMapsInspectorApiWithSuffix(id binaryMessenger, - NSObject *_Nullable api, - NSString *messageChannelSuffix); +extern void SetUpFGMMapsInspectorApiWithSuffix(id binaryMessenger, NSObject *_Nullable api, NSString *messageChannelSuffix); NS_ASSUME_NONNULL_END diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.m index 0ecaf0b8f82d..01c2ffc23928 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.m @@ -1,7 +1,7 @@ // Copyright 2013 The Flutter Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// Autogenerated from Pigeon (v22.7.2), do not edit directly. +// Autogenerated from Pigeon (v22.7.0), do not edit directly. // See also: https://pub.dev/packages/pigeon #import "messages.g.h" @@ -26,12 +26,7 @@ } static FlutterError *createConnectionError(NSString *channelName) { - return [FlutterError - errorWithCode:@"channel-error" - message:[NSString stringWithFormat:@"%@/%@/%@", - @"Unable to establish connection on channel: '", - channelName, @"'."] - details:@""]; + return [FlutterError errorWithCode:@"channel-error" message:[NSString stringWithFormat:@"%@/%@/%@", @"Unable to establish connection on channel: '", channelName, @"'."] details:@""]; } static id GetNullableObjectAtIndex(NSArray *array, NSInteger key) { @@ -233,12 +228,6 @@ + (nullable FGMPlatformCameraTargetBounds *)nullableFromList:(NSArray *)list - (NSArray *)toList; @end -@interface FGMPlatformDoublePair () -+ (FGMPlatformDoublePair *)fromList:(NSArray *)list; -+ (nullable FGMPlatformDoublePair *)nullableFromList:(NSArray *)list; -- (NSArray *)toList; -@end - @interface FGMPlatformGroundOverlay () + (FGMPlatformGroundOverlay *)fromList:(NSArray *)list; + (nullable FGMPlatformGroundOverlay *)nullableFromList:(NSArray *)list; @@ -324,11 +313,11 @@ + (nullable FGMPlatformBitmapBytesMap *)nullableFromList:(NSArray *)list; @end @implementation FGMPlatformCameraPosition -+ (instancetype)makeWithBearing:(double)bearing - target:(FGMPlatformLatLng *)target - tilt:(double)tilt - zoom:(double)zoom { - FGMPlatformCameraPosition *pigeonResult = [[FGMPlatformCameraPosition alloc] init]; ++ (instancetype)makeWithBearing:(double )bearing + target:(FGMPlatformLatLng *)target + tilt:(double )tilt + zoom:(double )zoom { + FGMPlatformCameraPosition* pigeonResult = [[FGMPlatformCameraPosition alloc] init]; pigeonResult.bearing = bearing; pigeonResult.target = target; pigeonResult.tilt = tilt; @@ -357,8 +346,8 @@ + (nullable FGMPlatformCameraPosition *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformCameraUpdate -+ (instancetype)makeWithCameraUpdate:(id)cameraUpdate { - FGMPlatformCameraUpdate *pigeonResult = [[FGMPlatformCameraUpdate alloc] init]; ++ (instancetype)makeWithCameraUpdate:(id )cameraUpdate { + FGMPlatformCameraUpdate* pigeonResult = [[FGMPlatformCameraUpdate alloc] init]; pigeonResult.cameraUpdate = cameraUpdate; return pigeonResult; } @@ -379,14 +368,12 @@ + (nullable FGMPlatformCameraUpdate *)nullableFromList:(NSArray *)list { @implementation FGMPlatformCameraUpdateNewCameraPosition + (instancetype)makeWithCameraPosition:(FGMPlatformCameraPosition *)cameraPosition { - FGMPlatformCameraUpdateNewCameraPosition *pigeonResult = - [[FGMPlatformCameraUpdateNewCameraPosition alloc] init]; + FGMPlatformCameraUpdateNewCameraPosition* pigeonResult = [[FGMPlatformCameraUpdateNewCameraPosition alloc] init]; pigeonResult.cameraPosition = cameraPosition; return pigeonResult; } + (FGMPlatformCameraUpdateNewCameraPosition *)fromList:(NSArray *)list { - FGMPlatformCameraUpdateNewCameraPosition *pigeonResult = - [[FGMPlatformCameraUpdateNewCameraPosition alloc] init]; + FGMPlatformCameraUpdateNewCameraPosition *pigeonResult = [[FGMPlatformCameraUpdateNewCameraPosition alloc] init]; pigeonResult.cameraPosition = GetNullableObjectAtIndex(list, 0); return pigeonResult; } @@ -402,7 +389,7 @@ + (nullable FGMPlatformCameraUpdateNewCameraPosition *)nullableFromList:(NSArray @implementation FGMPlatformCameraUpdateNewLatLng + (instancetype)makeWithLatLng:(FGMPlatformLatLng *)latLng { - FGMPlatformCameraUpdateNewLatLng *pigeonResult = [[FGMPlatformCameraUpdateNewLatLng alloc] init]; + FGMPlatformCameraUpdateNewLatLng* pigeonResult = [[FGMPlatformCameraUpdateNewLatLng alloc] init]; pigeonResult.latLng = latLng; return pigeonResult; } @@ -422,16 +409,15 @@ + (nullable FGMPlatformCameraUpdateNewLatLng *)nullableFromList:(NSArray *)l @end @implementation FGMPlatformCameraUpdateNewLatLngBounds -+ (instancetype)makeWithBounds:(FGMPlatformLatLngBounds *)bounds padding:(double)padding { - FGMPlatformCameraUpdateNewLatLngBounds *pigeonResult = - [[FGMPlatformCameraUpdateNewLatLngBounds alloc] init]; ++ (instancetype)makeWithBounds:(FGMPlatformLatLngBounds *)bounds + padding:(double )padding { + FGMPlatformCameraUpdateNewLatLngBounds* pigeonResult = [[FGMPlatformCameraUpdateNewLatLngBounds alloc] init]; pigeonResult.bounds = bounds; pigeonResult.padding = padding; return pigeonResult; } + (FGMPlatformCameraUpdateNewLatLngBounds *)fromList:(NSArray *)list { - FGMPlatformCameraUpdateNewLatLngBounds *pigeonResult = - [[FGMPlatformCameraUpdateNewLatLngBounds alloc] init]; + FGMPlatformCameraUpdateNewLatLngBounds *pigeonResult = [[FGMPlatformCameraUpdateNewLatLngBounds alloc] init]; pigeonResult.bounds = GetNullableObjectAtIndex(list, 0); pigeonResult.padding = [GetNullableObjectAtIndex(list, 1) doubleValue]; return pigeonResult; @@ -448,16 +434,15 @@ + (nullable FGMPlatformCameraUpdateNewLatLngBounds *)nullableFromList:(NSArray *)list { - FGMPlatformCameraUpdateNewLatLngZoom *pigeonResult = - [[FGMPlatformCameraUpdateNewLatLngZoom alloc] init]; + FGMPlatformCameraUpdateNewLatLngZoom *pigeonResult = [[FGMPlatformCameraUpdateNewLatLngZoom alloc] init]; pigeonResult.latLng = GetNullableObjectAtIndex(list, 0); pigeonResult.zoom = [GetNullableObjectAtIndex(list, 1) doubleValue]; return pigeonResult; @@ -474,8 +459,9 @@ + (nullable FGMPlatformCameraUpdateNewLatLngZoom *)nullableFromList:(NSArray @end @implementation FGMPlatformCameraUpdateScrollBy -+ (instancetype)makeWithDx:(double)dx dy:(double)dy { - FGMPlatformCameraUpdateScrollBy *pigeonResult = [[FGMPlatformCameraUpdateScrollBy alloc] init]; ++ (instancetype)makeWithDx:(double )dx + dy:(double )dy { + FGMPlatformCameraUpdateScrollBy* pigeonResult = [[FGMPlatformCameraUpdateScrollBy alloc] init]; pigeonResult.dx = dx; pigeonResult.dy = dy; return pigeonResult; @@ -498,8 +484,9 @@ + (nullable FGMPlatformCameraUpdateScrollBy *)nullableFromList:(NSArray *)li @end @implementation FGMPlatformCameraUpdateZoomBy -+ (instancetype)makeWithAmount:(double)amount focus:(nullable FGMPlatformPoint *)focus { - FGMPlatformCameraUpdateZoomBy *pigeonResult = [[FGMPlatformCameraUpdateZoomBy alloc] init]; ++ (instancetype)makeWithAmount:(double )amount + focus:(nullable FGMPlatformPoint *)focus { + FGMPlatformCameraUpdateZoomBy* pigeonResult = [[FGMPlatformCameraUpdateZoomBy alloc] init]; pigeonResult.amount = amount; pigeonResult.focus = focus; return pigeonResult; @@ -522,8 +509,8 @@ + (nullable FGMPlatformCameraUpdateZoomBy *)nullableFromList:(NSArray *)list @end @implementation FGMPlatformCameraUpdateZoom -+ (instancetype)makeWithOut:(BOOL)out { - FGMPlatformCameraUpdateZoom *pigeonResult = [[FGMPlatformCameraUpdateZoom alloc] init]; ++ (instancetype)makeWithOut:(BOOL )out { + FGMPlatformCameraUpdateZoom* pigeonResult = [[FGMPlatformCameraUpdateZoom alloc] init]; pigeonResult.out = out; return pigeonResult; } @@ -543,8 +530,8 @@ + (nullable FGMPlatformCameraUpdateZoom *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformCameraUpdateZoomTo -+ (instancetype)makeWithZoom:(double)zoom { - FGMPlatformCameraUpdateZoomTo *pigeonResult = [[FGMPlatformCameraUpdateZoomTo alloc] init]; ++ (instancetype)makeWithZoom:(double )zoom { + FGMPlatformCameraUpdateZoomTo* pigeonResult = [[FGMPlatformCameraUpdateZoomTo alloc] init]; pigeonResult.zoom = zoom; return pigeonResult; } @@ -564,16 +551,16 @@ + (nullable FGMPlatformCameraUpdateZoomTo *)nullableFromList:(NSArray *)list @end @implementation FGMPlatformCircle -+ (instancetype)makeWithConsumeTapEvents:(BOOL)consumeTapEvents - fillColor:(NSInteger)fillColor - strokeColor:(NSInteger)strokeColor - visible:(BOOL)visible - strokeWidth:(NSInteger)strokeWidth - zIndex:(double)zIndex - center:(FGMPlatformLatLng *)center - radius:(double)radius - circleId:(NSString *)circleId { - FGMPlatformCircle *pigeonResult = [[FGMPlatformCircle alloc] init]; ++ (instancetype)makeWithConsumeTapEvents:(BOOL )consumeTapEvents + fillColor:(NSInteger )fillColor + strokeColor:(NSInteger )strokeColor + visible:(BOOL )visible + strokeWidth:(NSInteger )strokeWidth + zIndex:(double )zIndex + center:(FGMPlatformLatLng *)center + radius:(double )radius + circleId:(NSString *)circleId { + FGMPlatformCircle* pigeonResult = [[FGMPlatformCircle alloc] init]; pigeonResult.consumeTapEvents = consumeTapEvents; pigeonResult.fillColor = fillColor; pigeonResult.strokeColor = strokeColor; @@ -617,8 +604,8 @@ + (nullable FGMPlatformCircle *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformHeatmap -+ (instancetype)makeWithJson:(id)json { - FGMPlatformHeatmap *pigeonResult = [[FGMPlatformHeatmap alloc] init]; ++ (instancetype)makeWithJson:(id )json { + FGMPlatformHeatmap* pigeonResult = [[FGMPlatformHeatmap alloc] init]; pigeonResult.json = json; return pigeonResult; } @@ -639,9 +626,9 @@ + (nullable FGMPlatformHeatmap *)nullableFromList:(NSArray *)list { @implementation FGMPlatformInfoWindow + (instancetype)makeWithTitle:(nullable NSString *)title - snippet:(nullable NSString *)snippet - anchor:(FGMPlatformPoint *)anchor { - FGMPlatformInfoWindow *pigeonResult = [[FGMPlatformInfoWindow alloc] init]; + snippet:(nullable NSString *)snippet + anchor:(FGMPlatformPoint *)anchor { + FGMPlatformInfoWindow* pigeonResult = [[FGMPlatformInfoWindow alloc] init]; pigeonResult.title = title; pigeonResult.snippet = snippet; pigeonResult.anchor = anchor; @@ -668,10 +655,10 @@ + (nullable FGMPlatformInfoWindow *)nullableFromList:(NSArray *)list { @implementation FGMPlatformCluster + (instancetype)makeWithClusterManagerId:(NSString *)clusterManagerId - position:(FGMPlatformLatLng *)position - bounds:(FGMPlatformLatLngBounds *)bounds - markerIds:(NSArray *)markerIds { - FGMPlatformCluster *pigeonResult = [[FGMPlatformCluster alloc] init]; + position:(FGMPlatformLatLng *)position + bounds:(FGMPlatformLatLngBounds *)bounds + markerIds:(NSArray *)markerIds { + FGMPlatformCluster* pigeonResult = [[FGMPlatformCluster alloc] init]; pigeonResult.clusterManagerId = clusterManagerId; pigeonResult.position = position; pigeonResult.bounds = bounds; @@ -701,7 +688,7 @@ + (nullable FGMPlatformCluster *)nullableFromList:(NSArray *)list { @implementation FGMPlatformClusterManager + (instancetype)makeWithIdentifier:(NSString *)identifier { - FGMPlatformClusterManager *pigeonResult = [[FGMPlatformClusterManager alloc] init]; + FGMPlatformClusterManager* pigeonResult = [[FGMPlatformClusterManager alloc] init]; pigeonResult.identifier = identifier; return pigeonResult; } @@ -721,20 +708,20 @@ + (nullable FGMPlatformClusterManager *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformMarker -+ (instancetype)makeWithAlpha:(double)alpha - anchor:(FGMPlatformPoint *)anchor - consumeTapEvents:(BOOL)consumeTapEvents - draggable:(BOOL)draggable - flat:(BOOL)flat - icon:(FGMPlatformBitmap *)icon - infoWindow:(FGMPlatformInfoWindow *)infoWindow - position:(FGMPlatformLatLng *)position - rotation:(double)rotation - visible:(BOOL)visible - zIndex:(double)zIndex - markerId:(NSString *)markerId - clusterManagerId:(nullable NSString *)clusterManagerId { - FGMPlatformMarker *pigeonResult = [[FGMPlatformMarker alloc] init]; ++ (instancetype)makeWithAlpha:(double )alpha + anchor:(FGMPlatformPoint *)anchor + consumeTapEvents:(BOOL )consumeTapEvents + draggable:(BOOL )draggable + flat:(BOOL )flat + icon:(FGMPlatformBitmap *)icon + infoWindow:(FGMPlatformInfoWindow *)infoWindow + position:(FGMPlatformLatLng *)position + rotation:(double )rotation + visible:(BOOL )visible + zIndex:(double )zIndex + markerId:(NSString *)markerId + clusterManagerId:(nullable NSString *)clusterManagerId { + FGMPlatformMarker* pigeonResult = [[FGMPlatformMarker alloc] init]; pigeonResult.alpha = alpha; pigeonResult.anchor = anchor; pigeonResult.consumeTapEvents = consumeTapEvents; @@ -791,16 +778,16 @@ + (nullable FGMPlatformMarker *)nullableFromList:(NSArray *)list { @implementation FGMPlatformPolygon + (instancetype)makeWithPolygonId:(NSString *)polygonId - consumesTapEvents:(BOOL)consumesTapEvents - fillColor:(NSInteger)fillColor - geodesic:(BOOL)geodesic - points:(NSArray *)points - holes:(NSArray *> *)holes - visible:(BOOL)visible - strokeColor:(NSInteger)strokeColor - strokeWidth:(NSInteger)strokeWidth - zIndex:(NSInteger)zIndex { - FGMPlatformPolygon *pigeonResult = [[FGMPlatformPolygon alloc] init]; + consumesTapEvents:(BOOL )consumesTapEvents + fillColor:(NSInteger )fillColor + geodesic:(BOOL )geodesic + points:(NSArray *)points + holes:(NSArray *> *)holes + visible:(BOOL )visible + strokeColor:(NSInteger )strokeColor + strokeWidth:(NSInteger )strokeWidth + zIndex:(NSInteger )zIndex { + FGMPlatformPolygon* pigeonResult = [[FGMPlatformPolygon alloc] init]; pigeonResult.polygonId = polygonId; pigeonResult.consumesTapEvents = consumesTapEvents; pigeonResult.fillColor = fillColor; @@ -848,16 +835,16 @@ + (nullable FGMPlatformPolygon *)nullableFromList:(NSArray *)list { @implementation FGMPlatformPolyline + (instancetype)makeWithPolylineId:(NSString *)polylineId - consumesTapEvents:(BOOL)consumesTapEvents - color:(NSInteger)color - geodesic:(BOOL)geodesic - jointType:(FGMPlatformJointType)jointType - patterns:(NSArray *)patterns - points:(NSArray *)points - visible:(BOOL)visible - width:(NSInteger)width - zIndex:(NSInteger)zIndex { - FGMPlatformPolyline *pigeonResult = [[FGMPlatformPolyline alloc] init]; + consumesTapEvents:(BOOL )consumesTapEvents + color:(NSInteger )color + geodesic:(BOOL )geodesic + jointType:(FGMPlatformJointType)jointType + patterns:(NSArray *)patterns + points:(NSArray *)points + visible:(BOOL )visible + width:(NSInteger )width + zIndex:(NSInteger )zIndex { + FGMPlatformPolyline* pigeonResult = [[FGMPlatformPolyline alloc] init]; pigeonResult.polylineId = polylineId; pigeonResult.consumesTapEvents = consumesTapEvents; pigeonResult.color = color; @@ -905,16 +892,16 @@ + (nullable FGMPlatformPolyline *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformPatternItem -+ (instancetype)makeWithType:(FGMPlatformPatternItemType)type length:(nullable NSNumber *)length { - FGMPlatformPatternItem *pigeonResult = [[FGMPlatformPatternItem alloc] init]; ++ (instancetype)makeWithType:(FGMPlatformPatternItemType)type + length:(nullable NSNumber *)length { + FGMPlatformPatternItem* pigeonResult = [[FGMPlatformPatternItem alloc] init]; pigeonResult.type = type; pigeonResult.length = length; return pigeonResult; } + (FGMPlatformPatternItem *)fromList:(NSArray *)list { FGMPlatformPatternItem *pigeonResult = [[FGMPlatformPatternItem alloc] init]; - FGMPlatformPatternItemTypeBox *boxedFGMPlatformPatternItemType = - GetNullableObjectAtIndex(list, 0); + FGMPlatformPatternItemTypeBox *boxedFGMPlatformPatternItemType = GetNullableObjectAtIndex(list, 0); pigeonResult.type = boxedFGMPlatformPatternItemType.value; pigeonResult.length = GetNullableObjectAtIndex(list, 1); return pigeonResult; @@ -931,10 +918,10 @@ + (nullable FGMPlatformPatternItem *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformTile -+ (instancetype)makeWithWidth:(NSInteger)width - height:(NSInteger)height - data:(nullable FlutterStandardTypedData *)data { - FGMPlatformTile *pigeonResult = [[FGMPlatformTile alloc] init]; ++ (instancetype)makeWithWidth:(NSInteger )width + height:(NSInteger )height + data:(nullable FlutterStandardTypedData *)data { + FGMPlatformTile* pigeonResult = [[FGMPlatformTile alloc] init]; pigeonResult.width = width; pigeonResult.height = height; pigeonResult.data = data; @@ -961,12 +948,12 @@ + (nullable FGMPlatformTile *)nullableFromList:(NSArray *)list { @implementation FGMPlatformTileOverlay + (instancetype)makeWithTileOverlayId:(NSString *)tileOverlayId - fadeIn:(BOOL)fadeIn - transparency:(double)transparency - zIndex:(NSInteger)zIndex - visible:(BOOL)visible - tileSize:(NSInteger)tileSize { - FGMPlatformTileOverlay *pigeonResult = [[FGMPlatformTileOverlay alloc] init]; + fadeIn:(BOOL )fadeIn + transparency:(double )transparency + zIndex:(NSInteger )zIndex + visible:(BOOL )visible + tileSize:(NSInteger )tileSize { + FGMPlatformTileOverlay* pigeonResult = [[FGMPlatformTileOverlay alloc] init]; pigeonResult.tileOverlayId = tileOverlayId; pigeonResult.fadeIn = fadeIn; pigeonResult.transparency = transparency; @@ -1001,11 +988,11 @@ + (nullable FGMPlatformTileOverlay *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformEdgeInsets -+ (instancetype)makeWithTop:(double)top - bottom:(double)bottom - left:(double)left - right:(double)right { - FGMPlatformEdgeInsets *pigeonResult = [[FGMPlatformEdgeInsets alloc] init]; ++ (instancetype)makeWithTop:(double )top + bottom:(double )bottom + left:(double )left + right:(double )right { + FGMPlatformEdgeInsets* pigeonResult = [[FGMPlatformEdgeInsets alloc] init]; pigeonResult.top = top; pigeonResult.bottom = bottom; pigeonResult.left = left; @@ -1034,8 +1021,9 @@ + (nullable FGMPlatformEdgeInsets *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformLatLng -+ (instancetype)makeWithLatitude:(double)latitude longitude:(double)longitude { - FGMPlatformLatLng *pigeonResult = [[FGMPlatformLatLng alloc] init]; ++ (instancetype)makeWithLatitude:(double )latitude + longitude:(double )longitude { + FGMPlatformLatLng* pigeonResult = [[FGMPlatformLatLng alloc] init]; pigeonResult.latitude = latitude; pigeonResult.longitude = longitude; return pigeonResult; @@ -1059,8 +1047,8 @@ + (nullable FGMPlatformLatLng *)nullableFromList:(NSArray *)list { @implementation FGMPlatformLatLngBounds + (instancetype)makeWithNortheast:(FGMPlatformLatLng *)northeast - southwest:(FGMPlatformLatLng *)southwest { - FGMPlatformLatLngBounds *pigeonResult = [[FGMPlatformLatLngBounds alloc] init]; + southwest:(FGMPlatformLatLng *)southwest { + FGMPlatformLatLngBounds* pigeonResult = [[FGMPlatformLatLngBounds alloc] init]; pigeonResult.northeast = northeast; pigeonResult.southwest = southwest; return pigeonResult; @@ -1084,7 +1072,7 @@ + (nullable FGMPlatformLatLngBounds *)nullableFromList:(NSArray *)list { @implementation FGMPlatformCameraTargetBounds + (instancetype)makeWithBounds:(nullable FGMPlatformLatLngBounds *)bounds { - FGMPlatformCameraTargetBounds *pigeonResult = [[FGMPlatformCameraTargetBounds alloc] init]; + FGMPlatformCameraTargetBounds* pigeonResult = [[FGMPlatformCameraTargetBounds alloc] init]; pigeonResult.bounds = bounds; return pigeonResult; } @@ -1103,43 +1091,19 @@ + (nullable FGMPlatformCameraTargetBounds *)nullableFromList:(NSArray *)list } @end -@implementation FGMPlatformDoublePair -+ (instancetype)makeWithX:(double)x y:(double)y { - FGMPlatformDoublePair *pigeonResult = [[FGMPlatformDoublePair alloc] init]; - pigeonResult.x = x; - pigeonResult.y = y; - return pigeonResult; -} -+ (FGMPlatformDoublePair *)fromList:(NSArray *)list { - FGMPlatformDoublePair *pigeonResult = [[FGMPlatformDoublePair alloc] init]; - pigeonResult.x = [GetNullableObjectAtIndex(list, 0) doubleValue]; - pigeonResult.y = [GetNullableObjectAtIndex(list, 1) doubleValue]; - return pigeonResult; -} -+ (nullable FGMPlatformDoublePair *)nullableFromList:(NSArray *)list { - return (list) ? [FGMPlatformDoublePair fromList:list] : nil; -} -- (NSArray *)toList { - return @[ - @(self.x), - @(self.y), - ]; -} -@end - @implementation FGMPlatformGroundOverlay + (instancetype)makeWithGroundOverlayId:(NSString *)groundOverlayId - image:(FGMPlatformBitmap *)image - position:(nullable FGMPlatformLatLng *)position - bounds:(nullable FGMPlatformLatLngBounds *)bounds - anchor:(nullable FGMPlatformDoublePair *)anchor - transparency:(double)transparency - bearing:(double)bearing - zIndex:(double)zIndex - visible:(BOOL)visible - clickable:(BOOL)clickable - zoomLevel:(nullable NSNumber *)zoomLevel { - FGMPlatformGroundOverlay *pigeonResult = [[FGMPlatformGroundOverlay alloc] init]; + image:(FGMPlatformBitmap *)image + position:(nullable FGMPlatformLatLng *)position + bounds:(nullable FGMPlatformLatLngBounds *)bounds + anchor:(nullable FGMPlatformPoint *)anchor + transparency:(double )transparency + bearing:(double )bearing + zIndex:(double )zIndex + visible:(BOOL )visible + clickable:(BOOL )clickable + zoomLevel:(nullable NSNumber *)zoomLevel { + FGMPlatformGroundOverlay* pigeonResult = [[FGMPlatformGroundOverlay alloc] init]; pigeonResult.groundOverlayId = groundOverlayId; pigeonResult.image = image; pigeonResult.position = position; @@ -1189,18 +1153,17 @@ + (nullable FGMPlatformGroundOverlay *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformMapViewCreationParams -+ (instancetype) - makeWithInitialCameraPosition:(FGMPlatformCameraPosition *)initialCameraPosition - mapConfiguration:(FGMPlatformMapConfiguration *)mapConfiguration - initialCircles:(NSArray *)initialCircles - initialMarkers:(NSArray *)initialMarkers - initialPolygons:(NSArray *)initialPolygons - initialPolylines:(NSArray *)initialPolylines - initialHeatmaps:(NSArray *)initialHeatmaps - initialTileOverlays:(NSArray *)initialTileOverlays - initialClusterManagers:(NSArray *)initialClusterManagers - initialGroundOverlays:(NSArray *)initialGroundOverlays { - FGMPlatformMapViewCreationParams *pigeonResult = [[FGMPlatformMapViewCreationParams alloc] init]; ++ (instancetype)makeWithInitialCameraPosition:(FGMPlatformCameraPosition *)initialCameraPosition + mapConfiguration:(FGMPlatformMapConfiguration *)mapConfiguration + initialCircles:(NSArray *)initialCircles + initialMarkers:(NSArray *)initialMarkers + initialPolygons:(NSArray *)initialPolygons + initialPolylines:(NSArray *)initialPolylines + initialHeatmaps:(NSArray *)initialHeatmaps + initialTileOverlays:(NSArray *)initialTileOverlays + initialClusterManagers:(NSArray *)initialClusterManagers + initialGroundOverlays:(NSArray *)initialGroundOverlays { + FGMPlatformMapViewCreationParams* pigeonResult = [[FGMPlatformMapViewCreationParams alloc] init]; pigeonResult.initialCameraPosition = initialCameraPosition; pigeonResult.mapConfiguration = mapConfiguration; pigeonResult.initialCircles = initialCircles; @@ -1248,23 +1211,23 @@ + (nullable FGMPlatformMapViewCreationParams *)nullableFromList:(NSArray *)l @implementation FGMPlatformMapConfiguration + (instancetype)makeWithCompassEnabled:(nullable NSNumber *)compassEnabled - cameraTargetBounds:(nullable FGMPlatformCameraTargetBounds *)cameraTargetBounds - mapType:(nullable FGMPlatformMapTypeBox *)mapType - minMaxZoomPreference:(nullable FGMPlatformZoomRange *)minMaxZoomPreference - rotateGesturesEnabled:(nullable NSNumber *)rotateGesturesEnabled - scrollGesturesEnabled:(nullable NSNumber *)scrollGesturesEnabled - tiltGesturesEnabled:(nullable NSNumber *)tiltGesturesEnabled - trackCameraPosition:(nullable NSNumber *)trackCameraPosition - zoomGesturesEnabled:(nullable NSNumber *)zoomGesturesEnabled - myLocationEnabled:(nullable NSNumber *)myLocationEnabled - myLocationButtonEnabled:(nullable NSNumber *)myLocationButtonEnabled - padding:(nullable FGMPlatformEdgeInsets *)padding - indoorViewEnabled:(nullable NSNumber *)indoorViewEnabled - trafficEnabled:(nullable NSNumber *)trafficEnabled - buildingsEnabled:(nullable NSNumber *)buildingsEnabled - cloudMapId:(nullable NSString *)cloudMapId - style:(nullable NSString *)style { - FGMPlatformMapConfiguration *pigeonResult = [[FGMPlatformMapConfiguration alloc] init]; + cameraTargetBounds:(nullable FGMPlatformCameraTargetBounds *)cameraTargetBounds + mapType:(nullable FGMPlatformMapTypeBox *)mapType + minMaxZoomPreference:(nullable FGMPlatformZoomRange *)minMaxZoomPreference + rotateGesturesEnabled:(nullable NSNumber *)rotateGesturesEnabled + scrollGesturesEnabled:(nullable NSNumber *)scrollGesturesEnabled + tiltGesturesEnabled:(nullable NSNumber *)tiltGesturesEnabled + trackCameraPosition:(nullable NSNumber *)trackCameraPosition + zoomGesturesEnabled:(nullable NSNumber *)zoomGesturesEnabled + myLocationEnabled:(nullable NSNumber *)myLocationEnabled + myLocationButtonEnabled:(nullable NSNumber *)myLocationButtonEnabled + padding:(nullable FGMPlatformEdgeInsets *)padding + indoorViewEnabled:(nullable NSNumber *)indoorViewEnabled + trafficEnabled:(nullable NSNumber *)trafficEnabled + buildingsEnabled:(nullable NSNumber *)buildingsEnabled + cloudMapId:(nullable NSString *)cloudMapId + style:(nullable NSString *)style { + FGMPlatformMapConfiguration* pigeonResult = [[FGMPlatformMapConfiguration alloc] init]; pigeonResult.compassEnabled = compassEnabled; pigeonResult.cameraTargetBounds = cameraTargetBounds; pigeonResult.mapType = mapType; @@ -1332,8 +1295,9 @@ + (nullable FGMPlatformMapConfiguration *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformPoint -+ (instancetype)makeWithX:(double)x y:(double)y { - FGMPlatformPoint *pigeonResult = [[FGMPlatformPoint alloc] init]; ++ (instancetype)makeWithX:(double )x + y:(double )y { + FGMPlatformPoint* pigeonResult = [[FGMPlatformPoint alloc] init]; pigeonResult.x = x; pigeonResult.y = y; return pigeonResult; @@ -1356,8 +1320,9 @@ + (nullable FGMPlatformPoint *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformSize -+ (instancetype)makeWithWidth:(double)width height:(double)height { - FGMPlatformSize *pigeonResult = [[FGMPlatformSize alloc] init]; ++ (instancetype)makeWithWidth:(double )width + height:(double )height { + FGMPlatformSize* pigeonResult = [[FGMPlatformSize alloc] init]; pigeonResult.width = width; pigeonResult.height = height; return pigeonResult; @@ -1380,11 +1345,11 @@ + (nullable FGMPlatformSize *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformTileLayer -+ (instancetype)makeWithVisible:(BOOL)visible - fadeIn:(BOOL)fadeIn - opacity:(double)opacity - zIndex:(NSInteger)zIndex { - FGMPlatformTileLayer *pigeonResult = [[FGMPlatformTileLayer alloc] init]; ++ (instancetype)makeWithVisible:(BOOL )visible + fadeIn:(BOOL )fadeIn + opacity:(double )opacity + zIndex:(NSInteger )zIndex { + FGMPlatformTileLayer* pigeonResult = [[FGMPlatformTileLayer alloc] init]; pigeonResult.visible = visible; pigeonResult.fadeIn = fadeIn; pigeonResult.opacity = opacity; @@ -1413,8 +1378,9 @@ + (nullable FGMPlatformTileLayer *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformZoomRange -+ (instancetype)makeWithMin:(nullable NSNumber *)min max:(nullable NSNumber *)max { - FGMPlatformZoomRange *pigeonResult = [[FGMPlatformZoomRange alloc] init]; ++ (instancetype)makeWithMin:(nullable NSNumber *)min + max:(nullable NSNumber *)max { + FGMPlatformZoomRange* pigeonResult = [[FGMPlatformZoomRange alloc] init]; pigeonResult.min = min; pigeonResult.max = max; return pigeonResult; @@ -1437,8 +1403,8 @@ + (nullable FGMPlatformZoomRange *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformBitmap -+ (instancetype)makeWithBitmap:(id)bitmap { - FGMPlatformBitmap *pigeonResult = [[FGMPlatformBitmap alloc] init]; ++ (instancetype)makeWithBitmap:(id )bitmap { + FGMPlatformBitmap* pigeonResult = [[FGMPlatformBitmap alloc] init]; pigeonResult.bitmap = bitmap; return pigeonResult; } @@ -1459,7 +1425,7 @@ + (nullable FGMPlatformBitmap *)nullableFromList:(NSArray *)list { @implementation FGMPlatformBitmapDefaultMarker + (instancetype)makeWithHue:(nullable NSNumber *)hue { - FGMPlatformBitmapDefaultMarker *pigeonResult = [[FGMPlatformBitmapDefaultMarker alloc] init]; + FGMPlatformBitmapDefaultMarker* pigeonResult = [[FGMPlatformBitmapDefaultMarker alloc] init]; pigeonResult.hue = hue; return pigeonResult; } @@ -1480,8 +1446,8 @@ + (nullable FGMPlatformBitmapDefaultMarker *)nullableFromList:(NSArray *)lis @implementation FGMPlatformBitmapBytes + (instancetype)makeWithByteData:(FlutterStandardTypedData *)byteData - size:(nullable FGMPlatformSize *)size { - FGMPlatformBitmapBytes *pigeonResult = [[FGMPlatformBitmapBytes alloc] init]; + size:(nullable FGMPlatformSize *)size { + FGMPlatformBitmapBytes* pigeonResult = [[FGMPlatformBitmapBytes alloc] init]; pigeonResult.byteData = byteData; pigeonResult.size = size; return pigeonResult; @@ -1504,8 +1470,9 @@ + (nullable FGMPlatformBitmapBytes *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformBitmapAsset -+ (instancetype)makeWithName:(NSString *)name pkg:(nullable NSString *)pkg { - FGMPlatformBitmapAsset *pigeonResult = [[FGMPlatformBitmapAsset alloc] init]; ++ (instancetype)makeWithName:(NSString *)name + pkg:(nullable NSString *)pkg { + FGMPlatformBitmapAsset* pigeonResult = [[FGMPlatformBitmapAsset alloc] init]; pigeonResult.name = name; pigeonResult.pkg = pkg; return pigeonResult; @@ -1529,9 +1496,9 @@ + (nullable FGMPlatformBitmapAsset *)nullableFromList:(NSArray *)list { @implementation FGMPlatformBitmapAssetImage + (instancetype)makeWithName:(NSString *)name - scale:(double)scale - size:(nullable FGMPlatformSize *)size { - FGMPlatformBitmapAssetImage *pigeonResult = [[FGMPlatformBitmapAssetImage alloc] init]; + scale:(double )scale + size:(nullable FGMPlatformSize *)size { + FGMPlatformBitmapAssetImage* pigeonResult = [[FGMPlatformBitmapAssetImage alloc] init]; pigeonResult.name = name; pigeonResult.scale = scale; pigeonResult.size = size; @@ -1558,11 +1525,11 @@ + (nullable FGMPlatformBitmapAssetImage *)nullableFromList:(NSArray *)list { @implementation FGMPlatformBitmapAssetMap + (instancetype)makeWithAssetName:(NSString *)assetName - bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling - imagePixelRatio:(double)imagePixelRatio - width:(nullable NSNumber *)width - height:(nullable NSNumber *)height { - FGMPlatformBitmapAssetMap *pigeonResult = [[FGMPlatformBitmapAssetMap alloc] init]; + bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling + imagePixelRatio:(double )imagePixelRatio + width:(nullable NSNumber *)width + height:(nullable NSNumber *)height { + FGMPlatformBitmapAssetMap* pigeonResult = [[FGMPlatformBitmapAssetMap alloc] init]; pigeonResult.assetName = assetName; pigeonResult.bitmapScaling = bitmapScaling; pigeonResult.imagePixelRatio = imagePixelRatio; @@ -1573,8 +1540,7 @@ + (instancetype)makeWithAssetName:(NSString *)assetName + (FGMPlatformBitmapAssetMap *)fromList:(NSArray *)list { FGMPlatformBitmapAssetMap *pigeonResult = [[FGMPlatformBitmapAssetMap alloc] init]; pigeonResult.assetName = GetNullableObjectAtIndex(list, 0); - FGMPlatformMapBitmapScalingBox *boxedFGMPlatformMapBitmapScaling = - GetNullableObjectAtIndex(list, 1); + FGMPlatformMapBitmapScalingBox *boxedFGMPlatformMapBitmapScaling = GetNullableObjectAtIndex(list, 1); pigeonResult.bitmapScaling = boxedFGMPlatformMapBitmapScaling.value; pigeonResult.imagePixelRatio = [GetNullableObjectAtIndex(list, 2) doubleValue]; pigeonResult.width = GetNullableObjectAtIndex(list, 3); @@ -1597,11 +1563,11 @@ + (nullable FGMPlatformBitmapAssetMap *)nullableFromList:(NSArray *)list { @implementation FGMPlatformBitmapBytesMap + (instancetype)makeWithByteData:(FlutterStandardTypedData *)byteData - bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling - imagePixelRatio:(double)imagePixelRatio - width:(nullable NSNumber *)width - height:(nullable NSNumber *)height { - FGMPlatformBitmapBytesMap *pigeonResult = [[FGMPlatformBitmapBytesMap alloc] init]; + bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling + imagePixelRatio:(double )imagePixelRatio + width:(nullable NSNumber *)width + height:(nullable NSNumber *)height { + FGMPlatformBitmapBytesMap* pigeonResult = [[FGMPlatformBitmapBytesMap alloc] init]; pigeonResult.byteData = byteData; pigeonResult.bitmapScaling = bitmapScaling; pigeonResult.imagePixelRatio = imagePixelRatio; @@ -1612,8 +1578,7 @@ + (instancetype)makeWithByteData:(FlutterStandardTypedData *)byteData + (FGMPlatformBitmapBytesMap *)fromList:(NSArray *)list { FGMPlatformBitmapBytesMap *pigeonResult = [[FGMPlatformBitmapBytesMap alloc] init]; pigeonResult.byteData = GetNullableObjectAtIndex(list, 0); - FGMPlatformMapBitmapScalingBox *boxedFGMPlatformMapBitmapScaling = - GetNullableObjectAtIndex(list, 1); + FGMPlatformMapBitmapScalingBox *boxedFGMPlatformMapBitmapScaling = GetNullableObjectAtIndex(list, 1); pigeonResult.bitmapScaling = boxedFGMPlatformMapBitmapScaling.value; pigeonResult.imagePixelRatio = [GetNullableObjectAtIndex(list, 2) doubleValue]; pigeonResult.width = GetNullableObjectAtIndex(list, 3); @@ -1641,107 +1606,97 @@ - (nullable id)readValueOfType:(UInt8)type { switch (type) { case 129: { NSNumber *enumAsNumber = [self readValue]; - return enumAsNumber == nil - ? nil - : [[FGMPlatformMapTypeBox alloc] initWithValue:[enumAsNumber integerValue]]; + return enumAsNumber == nil ? nil : [[FGMPlatformMapTypeBox alloc] initWithValue:[enumAsNumber integerValue]]; } case 130: { NSNumber *enumAsNumber = [self readValue]; - return enumAsNumber == nil - ? nil - : [[FGMPlatformJointTypeBox alloc] initWithValue:[enumAsNumber integerValue]]; + return enumAsNumber == nil ? nil : [[FGMPlatformJointTypeBox alloc] initWithValue:[enumAsNumber integerValue]]; } case 131: { NSNumber *enumAsNumber = [self readValue]; - return enumAsNumber == nil ? nil - : [[FGMPlatformPatternItemTypeBox alloc] - initWithValue:[enumAsNumber integerValue]]; + return enumAsNumber == nil ? nil : [[FGMPlatformPatternItemTypeBox alloc] initWithValue:[enumAsNumber integerValue]]; } case 132: { NSNumber *enumAsNumber = [self readValue]; - return enumAsNumber == nil ? nil - : [[FGMPlatformMapBitmapScalingBox alloc] - initWithValue:[enumAsNumber integerValue]]; + return enumAsNumber == nil ? nil : [[FGMPlatformMapBitmapScalingBox alloc] initWithValue:[enumAsNumber integerValue]]; } - case 133: + case 133: return [FGMPlatformCameraPosition fromList:[self readValue]]; - case 134: + case 134: return [FGMPlatformCameraUpdate fromList:[self readValue]]; - case 135: + case 135: return [FGMPlatformCameraUpdateNewCameraPosition fromList:[self readValue]]; - case 136: + case 136: return [FGMPlatformCameraUpdateNewLatLng fromList:[self readValue]]; - case 137: + case 137: return [FGMPlatformCameraUpdateNewLatLngBounds fromList:[self readValue]]; - case 138: + case 138: return [FGMPlatformCameraUpdateNewLatLngZoom fromList:[self readValue]]; - case 139: + case 139: return [FGMPlatformCameraUpdateScrollBy fromList:[self readValue]]; - case 140: + case 140: return [FGMPlatformCameraUpdateZoomBy fromList:[self readValue]]; - case 141: + case 141: return [FGMPlatformCameraUpdateZoom fromList:[self readValue]]; - case 142: + case 142: return [FGMPlatformCameraUpdateZoomTo fromList:[self readValue]]; - case 143: + case 143: return [FGMPlatformCircle fromList:[self readValue]]; - case 144: + case 144: return [FGMPlatformHeatmap fromList:[self readValue]]; - case 145: + case 145: return [FGMPlatformInfoWindow fromList:[self readValue]]; - case 146: + case 146: return [FGMPlatformCluster fromList:[self readValue]]; - case 147: + case 147: return [FGMPlatformClusterManager fromList:[self readValue]]; - case 148: + case 148: return [FGMPlatformMarker fromList:[self readValue]]; - case 149: + case 149: return [FGMPlatformPolygon fromList:[self readValue]]; - case 150: + case 150: return [FGMPlatformPolyline fromList:[self readValue]]; - case 151: + case 151: return [FGMPlatformPatternItem fromList:[self readValue]]; - case 152: + case 152: return [FGMPlatformTile fromList:[self readValue]]; - case 153: + case 153: return [FGMPlatformTileOverlay fromList:[self readValue]]; - case 154: + case 154: return [FGMPlatformEdgeInsets fromList:[self readValue]]; - case 155: + case 155: return [FGMPlatformLatLng fromList:[self readValue]]; - case 156: + case 156: return [FGMPlatformLatLngBounds fromList:[self readValue]]; - case 157: + case 157: return [FGMPlatformCameraTargetBounds fromList:[self readValue]]; - case 158: - return [FGMPlatformDoublePair fromList:[self readValue]]; - case 159: + case 158: return [FGMPlatformGroundOverlay fromList:[self readValue]]; - case 160: + case 159: return [FGMPlatformMapViewCreationParams fromList:[self readValue]]; - case 161: + case 160: return [FGMPlatformMapConfiguration fromList:[self readValue]]; - case 162: + case 161: return [FGMPlatformPoint fromList:[self readValue]]; - case 163: + case 162: return [FGMPlatformSize fromList:[self readValue]]; - case 164: + case 163: return [FGMPlatformTileLayer fromList:[self readValue]]; - case 165: + case 164: return [FGMPlatformZoomRange fromList:[self readValue]]; - case 166: + case 165: return [FGMPlatformBitmap fromList:[self readValue]]; - case 167: + case 166: return [FGMPlatformBitmapDefaultMarker fromList:[self readValue]]; - case 168: + case 167: return [FGMPlatformBitmapBytes fromList:[self readValue]]; - case 169: + case 168: return [FGMPlatformBitmapAsset fromList:[self readValue]]; - case 170: + case 169: return [FGMPlatformBitmapAssetImage fromList:[self readValue]]; - case 171: + case 170: return [FGMPlatformBitmapAssetMap fromList:[self readValue]]; - case 172: + case 171: return [FGMPlatformBitmapBytesMap fromList:[self readValue]]; default: return [super readValueOfType:type]; @@ -1844,50 +1799,47 @@ - (void)writeValue:(id)value { } else if ([value isKindOfClass:[FGMPlatformCameraTargetBounds class]]) { [self writeByte:157]; [self writeValue:[value toList]]; - } else if ([value isKindOfClass:[FGMPlatformDoublePair class]]) { - [self writeByte:158]; - [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformGroundOverlay class]]) { - [self writeByte:159]; + [self writeByte:158]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformMapViewCreationParams class]]) { - [self writeByte:160]; + [self writeByte:159]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformMapConfiguration class]]) { - [self writeByte:161]; + [self writeByte:160]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformPoint class]]) { - [self writeByte:162]; + [self writeByte:161]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformSize class]]) { - [self writeByte:163]; + [self writeByte:162]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformTileLayer class]]) { - [self writeByte:164]; + [self writeByte:163]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformZoomRange class]]) { - [self writeByte:165]; + [self writeByte:164]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformBitmap class]]) { - [self writeByte:166]; + [self writeByte:165]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformBitmapDefaultMarker class]]) { - [self writeByte:167]; + [self writeByte:166]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformBitmapBytes class]]) { - [self writeByte:168]; + [self writeByte:167]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformBitmapAsset class]]) { - [self writeByte:169]; + [self writeByte:168]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformBitmapAssetImage class]]) { - [self writeByte:170]; + [self writeByte:169]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformBitmapAssetMap class]]) { - [self writeByte:171]; + [self writeByte:170]; [self writeValue:[value toList]]; } else if ([value isKindOfClass:[FGMPlatformBitmapBytesMap class]]) { - [self writeByte:172]; + [self writeByte:171]; [self writeValue:[value toList]]; } else { [super writeValue:value]; @@ -1910,8 +1862,7 @@ - (FlutterStandardReader *)readerWithData:(NSData *)data { static FlutterStandardMessageCodec *sSharedObject = nil; static dispatch_once_t sPred = 0; dispatch_once(&sPred, ^{ - FGMMessagesPigeonCodecReaderWriter *readerWriter = - [[FGMMessagesPigeonCodecReaderWriter alloc] init]; + FGMMessagesPigeonCodecReaderWriter *readerWriter = [[FGMMessagesPigeonCodecReaderWriter alloc] init]; sSharedObject = [FlutterStandardMessageCodec codecWithReaderWriter:readerWriter]; }); return sSharedObject; @@ -1920,24 +1871,17 @@ void SetUpFGMMapsApi(id binaryMessenger, NSObject binaryMessenger, - NSObject *api, NSString *messageChannelSuffix) { - messageChannelSuffix = messageChannelSuffix.length > 0 - ? [NSString stringWithFormat:@".%@", messageChannelSuffix] - : @""; +void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObject *api, NSString *messageChannelSuffix) { + messageChannelSuffix = messageChannelSuffix.length > 0 ? [NSString stringWithFormat: @".%@", messageChannelSuffix] : @""; /// Returns once the map instance is available. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString - stringWithFormat: - @"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.waitForMap", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.waitForMap", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(waitForMapWithError:)], - @"FGMMapsApi api (%@) doesn't respond to @selector(waitForMapWithError:)", api); + NSCAssert([api respondsToSelector:@selector(waitForMapWithError:)], @"FGMMapsApi api (%@) doesn't respond to @selector(waitForMapWithError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; [api waitForMapWithError:&error]; @@ -1952,18 +1896,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, /// Only non-null configuration values will result in updates; options with /// null values will remain unchanged. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.updateMapConfiguration", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMapConfiguration", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert( - [api respondsToSelector:@selector(updateWithMapConfiguration:error:)], - @"FGMMapsApi api (%@) doesn't respond to @selector(updateWithMapConfiguration:error:)", - api); + NSCAssert([api respondsToSelector:@selector(updateWithMapConfiguration:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateWithMapConfiguration:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; FGMPlatformMapConfiguration *arg_configuration = GetNullableObjectAtIndex(args, 0); @@ -1977,29 +1916,20 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Updates the set of circles on the map. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString - stringWithFormat: - @"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateCircles", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateCircles", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateCirclesByAdding:changing:removing:error:)], - @"FGMMapsApi api (%@) doesn't respond to " - @"@selector(updateCirclesByAdding:changing:removing:error:)", - api); + NSCAssert([api respondsToSelector:@selector(updateCirclesByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateCirclesByAdding:changing:removing:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updateCirclesByAdding:arg_toAdd - changing:arg_toChange - removing:arg_idsToRemove - error:&error]; + [api updateCirclesByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -2008,28 +1938,20 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Updates the set of heatmaps on the map. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.updateHeatmaps", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateHeatmaps", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateHeatmapsByAdding:changing:removing:error:)], - @"FGMMapsApi api (%@) doesn't respond to " - @"@selector(updateHeatmapsByAdding:changing:removing:error:)", - api); + NSCAssert([api respondsToSelector:@selector(updateHeatmapsByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateHeatmapsByAdding:changing:removing:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updateHeatmapsByAdding:arg_toAdd - changing:arg_toChange - removing:arg_idsToRemove - error:&error]; + [api updateHeatmapsByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -2038,18 +1960,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Updates the set of custer managers for clusters on the map. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.updateClusterManagers", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateClusterManagers", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateClusterManagersByAdding:removing:error:)], - @"FGMMapsApi api (%@) doesn't respond to " - @"@selector(updateClusterManagersByAdding:removing:error:)", - api); + NSCAssert([api respondsToSelector:@selector(updateClusterManagersByAdding:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateClusterManagersByAdding:removing:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); @@ -2064,29 +1981,20 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Updates the set of markers on the map. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString - stringWithFormat: - @"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMarkers", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMarkers", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateMarkersByAdding:changing:removing:error:)], - @"FGMMapsApi api (%@) doesn't respond to " - @"@selector(updateMarkersByAdding:changing:removing:error:)", - api); + NSCAssert([api respondsToSelector:@selector(updateMarkersByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateMarkersByAdding:changing:removing:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updateMarkersByAdding:arg_toAdd - changing:arg_toChange - removing:arg_idsToRemove - error:&error]; + [api updateMarkersByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -2095,28 +2003,20 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Updates the set of polygonss on the map. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.updatePolygons", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updatePolygons", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updatePolygonsByAdding:changing:removing:error:)], - @"FGMMapsApi api (%@) doesn't respond to " - @"@selector(updatePolygonsByAdding:changing:removing:error:)", - api); + NSCAssert([api respondsToSelector:@selector(updatePolygonsByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updatePolygonsByAdding:changing:removing:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updatePolygonsByAdding:arg_toAdd - changing:arg_toChange - removing:arg_idsToRemove - error:&error]; + [api updatePolygonsByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -2125,29 +2025,20 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Updates the set of polylines on the map. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.updatePolylines", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updatePolylines", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updatePolylinesByAdding: - changing:removing:error:)], - @"FGMMapsApi api (%@) doesn't respond to " - @"@selector(updatePolylinesByAdding:changing:removing:error:)", - api); + NSCAssert([api respondsToSelector:@selector(updatePolylinesByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updatePolylinesByAdding:changing:removing:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updatePolylinesByAdding:arg_toAdd - changing:arg_toChange - removing:arg_idsToRemove - error:&error]; + [api updatePolylinesByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -2156,29 +2047,20 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Updates the set of tile overlays on the map. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.updateTileOverlays", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateTileOverlays", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateTileOverlaysByAdding: - changing:removing:error:)], - @"FGMMapsApi api (%@) doesn't respond to " - @"@selector(updateTileOverlaysByAdding:changing:removing:error:)", - api); + NSCAssert([api respondsToSelector:@selector(updateTileOverlaysByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateTileOverlaysByAdding:changing:removing:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updateTileOverlaysByAdding:arg_toAdd - changing:arg_toChange - removing:arg_idsToRemove - error:&error]; + [api updateTileOverlaysByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -2187,29 +2069,20 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Updates the set of ground overlays on the map. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.updateGroundOverlays", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateGroundOverlays", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateGroundOverlaysByAdding: - changing:removing:error:)], - @"FGMMapsApi api (%@) doesn't respond to " - @"@selector(updateGroundOverlaysByAdding:changing:removing:error:)", - api); + NSCAssert([api respondsToSelector:@selector(updateGroundOverlaysByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateGroundOverlaysByAdding:changing:removing:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updateGroundOverlaysByAdding:arg_toAdd - changing:arg_toChange - removing:arg_idsToRemove - error:&error]; + [api updateGroundOverlaysByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -2218,18 +2091,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Gets the screen coordinate for the given map location. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.getScreenCoordinate", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getScreenCoordinate", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert( - [api respondsToSelector:@selector(screenCoordinatesForLatLng:error:)], - @"FGMMapsApi api (%@) doesn't respond to @selector(screenCoordinatesForLatLng:error:)", - api); + NSCAssert([api respondsToSelector:@selector(screenCoordinatesForLatLng:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(screenCoordinatesForLatLng:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; FGMPlatformLatLng *arg_latLng = GetNullableObjectAtIndex(args, 0); @@ -2243,25 +2111,18 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Gets the map location for the given screen coordinate. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName: - [NSString - stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLatLng", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLatLng", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert( - [api respondsToSelector:@selector(latLngForScreenCoordinate:error:)], - @"FGMMapsApi api (%@) doesn't respond to @selector(latLngForScreenCoordinate:error:)", - api); + NSCAssert([api respondsToSelector:@selector(latLngForScreenCoordinate:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(latLngForScreenCoordinate:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; FGMPlatformPoint *arg_screenCoordinate = GetNullableObjectAtIndex(args, 0); FlutterError *error; - FGMPlatformLatLng *output = [api latLngForScreenCoordinate:arg_screenCoordinate - error:&error]; + FGMPlatformLatLng *output = [api latLngForScreenCoordinate:arg_screenCoordinate error:&error]; callback(wrapResult(output, error)); }]; } else { @@ -2270,16 +2131,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Gets the map region currently displayed on the map. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.getVisibleRegion", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getVisibleRegion", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(visibleMapRegion:)], - @"FGMMapsApi api (%@) doesn't respond to @selector(visibleMapRegion:)", api); + NSCAssert([api respondsToSelector:@selector(visibleMapRegion:)], @"FGMMapsApi api (%@) doesn't respond to @selector(visibleMapRegion:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; FGMPlatformLatLngBounds *output = [api visibleMapRegion:&error]; @@ -2292,18 +2150,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, /// Moves the camera according to [cameraUpdate] immediately, with no /// animation. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString - stringWithFormat: - @"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.moveCamera", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.moveCamera", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(moveCameraWithUpdate:error:)], - @"FGMMapsApi api (%@) doesn't respond to @selector(moveCameraWithUpdate:error:)", - api); + NSCAssert([api respondsToSelector:@selector(moveCameraWithUpdate:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(moveCameraWithUpdate:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; FGMPlatformCameraUpdate *arg_cameraUpdate = GetNullableObjectAtIndex(args, 0); @@ -2317,18 +2170,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Moves the camera according to [cameraUpdate], animating the update. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString - stringWithFormat: - @"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.animateCamera", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.animateCamera", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(animateCameraWithUpdate:error:)], - @"FGMMapsApi api (%@) doesn't respond to @selector(animateCameraWithUpdate:error:)", - api); + NSCAssert([api respondsToSelector:@selector(animateCameraWithUpdate:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(animateCameraWithUpdate:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; FGMPlatformCameraUpdate *arg_cameraUpdate = GetNullableObjectAtIndex(args, 0); @@ -2342,17 +2190,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Gets the current map zoom level. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString - stringWithFormat: - @"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getZoomLevel", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getZoomLevel", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(currentZoomLevel:)], - @"FGMMapsApi api (%@) doesn't respond to @selector(currentZoomLevel:)", api); + NSCAssert([api respondsToSelector:@selector(currentZoomLevel:)], @"FGMMapsApi api (%@) doesn't respond to @selector(currentZoomLevel:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api currentZoomLevel:&error]; @@ -2364,18 +2208,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Show the info window for the marker with the given ID. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.showInfoWindow", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.showInfoWindow", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(showInfoWindowForMarkerWithIdentifier:error:)], - @"FGMMapsApi api (%@) doesn't respond to " - @"@selector(showInfoWindowForMarkerWithIdentifier:error:)", - api); + NSCAssert([api respondsToSelector:@selector(showInfoWindowForMarkerWithIdentifier:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(showInfoWindowForMarkerWithIdentifier:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_markerId = GetNullableObjectAtIndex(args, 0); @@ -2389,18 +2228,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Hide the info window for the marker with the given ID. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.hideInfoWindow", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.hideInfoWindow", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(hideInfoWindowForMarkerWithIdentifier:error:)], - @"FGMMapsApi api (%@) doesn't respond to " - @"@selector(hideInfoWindowForMarkerWithIdentifier:error:)", - api); + NSCAssert([api respondsToSelector:@selector(hideInfoWindowForMarkerWithIdentifier:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(hideInfoWindowForMarkerWithIdentifier:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_markerId = GetNullableObjectAtIndex(args, 0); @@ -2415,25 +2249,18 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, /// Returns true if the marker with the given ID is currently displaying its /// info window. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.isInfoWindowShown", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.isInfoWindowShown", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(isShowingInfoWindowForMarkerWithIdentifier: - error:)], - @"FGMMapsApi api (%@) doesn't respond to " - @"@selector(isShowingInfoWindowForMarkerWithIdentifier:error:)", - api); + NSCAssert([api respondsToSelector:@selector(isShowingInfoWindowForMarkerWithIdentifier:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(isShowingInfoWindowForMarkerWithIdentifier:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_markerId = GetNullableObjectAtIndex(args, 0); FlutterError *error; - NSNumber *output = [api isShowingInfoWindowForMarkerWithIdentifier:arg_markerId - error:&error]; + NSNumber *output = [api isShowingInfoWindowForMarkerWithIdentifier:arg_markerId error:&error]; callback(wrapResult(output, error)); }]; } else { @@ -2446,17 +2273,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, /// If there was an error setting the style, such as an invalid style string, /// returns the error message. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName: - [NSString - stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.setStyle", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.setStyle", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(setStyle:error:)], - @"FGMMapsApi api (%@) doesn't respond to @selector(setStyle:error:)", api); + NSCAssert([api respondsToSelector:@selector(setStyle:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(setStyle:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_style = GetNullableObjectAtIndex(args, 0); @@ -2474,16 +2297,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, /// This allows checking asynchronously for initial style failures, as there /// is no way to return failures from map initialization. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.getLastStyleError", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLastStyleError", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(lastStyleError:)], - @"FGMMapsApi api (%@) doesn't respond to @selector(lastStyleError:)", api); + NSCAssert([api respondsToSelector:@selector(lastStyleError:)], @"FGMMapsApi api (%@) doesn't respond to @selector(lastStyleError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSString *output = [api lastStyleError:&error]; @@ -2495,18 +2315,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Clears the cache of tiles previously requseted from the tile provider. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsApi.clearTileCache", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.clearTileCache", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(clearTileCacheForOverlayWithIdentifier:error:)], - @"FGMMapsApi api (%@) doesn't respond to " - @"@selector(clearTileCacheForOverlayWithIdentifier:error:)", - api); + NSCAssert([api respondsToSelector:@selector(clearTileCacheForOverlayWithIdentifier:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(clearTileCacheForOverlayWithIdentifier:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_tileOverlayId = GetNullableObjectAtIndex(args, 0); @@ -2520,17 +2335,13 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, } /// Takes a snapshot of the map and returns its image data. { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString - stringWithFormat: - @"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.takeSnapshot", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.takeSnapshot", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(takeSnapshotWithError:)], - @"FGMMapsApi api (%@) doesn't respond to @selector(takeSnapshotWithError:)", api); + NSCAssert([api respondsToSelector:@selector(takeSnapshotWithError:)], @"FGMMapsApi api (%@) doesn't respond to @selector(takeSnapshotWithError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; FlutterStandardTypedData *output = [api takeSnapshotWithError:&error]; @@ -2551,450 +2362,335 @@ @implementation FGMMapsCallbackApi - (instancetype)initWithBinaryMessenger:(NSObject *)binaryMessenger { return [self initWithBinaryMessenger:binaryMessenger messageChannelSuffix:@""]; } -- (instancetype)initWithBinaryMessenger:(NSObject *)binaryMessenger - messageChannelSuffix:(nullable NSString *)messageChannelSuffix { +- (instancetype)initWithBinaryMessenger:(NSObject *)binaryMessenger messageChannelSuffix:(nullable NSString*)messageChannelSuffix{ self = [self init]; if (self) { _binaryMessenger = binaryMessenger; - _messageChannelSuffix = [messageChannelSuffix length] == 0 - ? @"" - : [NSString stringWithFormat:@".%@", messageChannelSuffix]; + _messageChannelSuffix = [messageChannelSuffix length] == 0 ? @"" : [NSString stringWithFormat: @".%@", messageChannelSuffix]; } return self; } - (void)didStartCameraMoveWithCompletion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat: - @"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMoveStarted", - _messageChannelSuffix]; + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMoveStarted", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:nil - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didMoveCameraToPosition:(FGMPlatformCameraPosition *)arg_cameraPosition - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:nil reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didMoveCameraToPosition:(FGMPlatformCameraPosition *)arg_cameraPosition completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_cameraPosition ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_cameraPosition ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; } - (void)didIdleCameraWithCompletion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraIdle", - _messageChannelSuffix]; + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraIdle", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:nil - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapAtPosition:(FGMPlatformLatLng *)arg_position - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onTap", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:nil reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapAtPosition:(FGMPlatformLatLng *)arg_position completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onTap", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_position ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didLongPressAtPosition:(FGMPlatformLatLng *)arg_position - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onLongPress", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_position ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didLongPressAtPosition:(FGMPlatformLatLng *)arg_position completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onLongPress", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_position ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapMarkerWithIdentifier:(NSString *)arg_markerId - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerTap", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_position ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapMarkerWithIdentifier:(NSString *)arg_markerId completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerTap", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_markerId ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didStartDragForMarkerWithIdentifier:(NSString *)arg_markerId - atPosition:(FGMPlatformLatLng *)arg_position - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat: - @"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragStart", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_markerId ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didStartDragForMarkerWithIdentifier:(NSString *)arg_markerId atPosition:(FGMPlatformLatLng *)arg_position completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragStart", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_markerId ?: [NSNull null], arg_position ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didDragMarkerWithIdentifier:(NSString *)arg_markerId - atPosition:(FGMPlatformLatLng *)arg_position - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDrag", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_markerId ?: [NSNull null], arg_position ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didDragMarkerWithIdentifier:(NSString *)arg_markerId atPosition:(FGMPlatformLatLng *)arg_position completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDrag", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_markerId ?: [NSNull null], arg_position ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didEndDragForMarkerWithIdentifier:(NSString *)arg_markerId - atPosition:(FGMPlatformLatLng *)arg_position - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat: - @"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragEnd", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_markerId ?: [NSNull null], arg_position ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didEndDragForMarkerWithIdentifier:(NSString *)arg_markerId atPosition:(FGMPlatformLatLng *)arg_position completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragEnd", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_markerId ?: [NSNull null], arg_position ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapInfoWindowOfMarkerWithIdentifier:(NSString *)arg_markerId - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat: - @"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onInfoWindowTap", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_markerId ?: [NSNull null], arg_position ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapInfoWindowOfMarkerWithIdentifier:(NSString *)arg_markerId completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onInfoWindowTap", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_markerId ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapCircleWithIdentifier:(NSString *)arg_circleId - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCircleTap", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_markerId ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapCircleWithIdentifier:(NSString *)arg_circleId completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCircleTap", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_circleId ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapCluster:(FGMPlatformCluster *)arg_cluster - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onClusterTap", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_circleId ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapCluster:(FGMPlatformCluster *)arg_cluster completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onClusterTap", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_cluster ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapPolygonWithIdentifier:(NSString *)arg_polygonId - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolygonTap", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_cluster ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapPolygonWithIdentifier:(NSString *)arg_polygonId completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolygonTap", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_polygonId ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapPolylineWithIdentifier:(NSString *)arg_polylineId - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolylineTap", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_polygonId ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapPolylineWithIdentifier:(NSString *)arg_polylineId completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolylineTap", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_polylineId ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapGroundOverlayWithIdentifier:(NSString *)arg_groundOverlayId - completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat: - @"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onGroundOverlayTap", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_polylineId ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapGroundOverlayWithIdentifier:(NSString *)arg_groundOverlayId completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onGroundOverlayTap", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ arg_groundOverlayId ?: [NSNull null] ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)tileWithOverlayIdentifier:(NSString *)arg_tileOverlayId - location:(FGMPlatformPoint *)arg_location - zoom:(NSInteger)arg_zoom - completion:(void (^)(FGMPlatformTile *_Nullable, - FlutterError *_Nullable))completion { - NSString *channelName = [NSString - stringWithFormat: - @"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile", - _messageChannelSuffix]; + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_groundOverlayId ?: [NSNull null]] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)tileWithOverlayIdentifier:(NSString *)arg_tileOverlayId location:(FGMPlatformPoint *)arg_location zoom:(NSInteger)arg_zoom completion:(void (^)(FGMPlatformTile *_Nullable, FlutterError *_Nullable))completion { + NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile", _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[ - arg_tileOverlayId ?: [NSNull null], arg_location ?: [NSNull null], @(arg_zoom) - ] - reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion(nil, [FlutterError errorWithCode:reply[0] - message:reply[1] - details:reply[2]]); - } else { - FGMPlatformTile *output = reply[0] == [NSNull null] ? nil : reply[0]; - completion(output, nil); - } - } else { - completion(nil, createConnectionError(channelName)); - } - }]; -} -@end - -void SetUpFGMMapsPlatformViewApi(id binaryMessenger, - NSObject *api) { + [FlutterBasicMessageChannel + messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[arg_tileOverlayId ?: [NSNull null], arg_location ?: [NSNull null], @(arg_zoom)] reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion(nil, [FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); + } else { + FGMPlatformTile *output = reply[0] == [NSNull null] ? nil : reply[0]; + completion(output, nil); + } + } else { + completion(nil, createConnectionError(channelName)); + } + }]; +} +@end + +void SetUpFGMMapsPlatformViewApi(id binaryMessenger, NSObject *api) { SetUpFGMMapsPlatformViewApiWithSuffix(binaryMessenger, api, @""); } -void SetUpFGMMapsPlatformViewApiWithSuffix(id binaryMessenger, - NSObject *api, - NSString *messageChannelSuffix) { - messageChannelSuffix = messageChannelSuffix.length > 0 - ? [NSString stringWithFormat:@".%@", messageChannelSuffix] - : @""; +void SetUpFGMMapsPlatformViewApiWithSuffix(id binaryMessenger, NSObject *api, NSString *messageChannelSuffix) { + messageChannelSuffix = messageChannelSuffix.length > 0 ? [NSString stringWithFormat: @".%@", messageChannelSuffix] : @""; { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsPlatformViewApi.createView", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsPlatformViewApi.createView", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert( - [api respondsToSelector:@selector(createViewType:error:)], - @"FGMMapsPlatformViewApi api (%@) doesn't respond to @selector(createViewType:error:)", - api); + NSCAssert([api respondsToSelector:@selector(createViewType:error:)], @"FGMMapsPlatformViewApi api (%@) doesn't respond to @selector(createViewType:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; FGMPlatformMapViewCreationParams *arg_type = GetNullableObjectAtIndex(args, 0); @@ -3007,30 +2703,20 @@ void SetUpFGMMapsPlatformViewApiWithSuffix(id binaryMess } } } -void SetUpFGMMapsInspectorApi(id binaryMessenger, - NSObject *api) { +void SetUpFGMMapsInspectorApi(id binaryMessenger, NSObject *api) { SetUpFGMMapsInspectorApiWithSuffix(binaryMessenger, api, @""); } -void SetUpFGMMapsInspectorApiWithSuffix(id binaryMessenger, - NSObject *api, - NSString *messageChannelSuffix) { - messageChannelSuffix = messageChannelSuffix.length > 0 - ? [NSString stringWithFormat:@".%@", messageChannelSuffix] - : @""; +void SetUpFGMMapsInspectorApiWithSuffix(id binaryMessenger, NSObject *api, NSString *messageChannelSuffix) { + messageChannelSuffix = messageChannelSuffix.length > 0 ? [NSString stringWithFormat: @".%@", messageChannelSuffix] : @""; { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.areBuildingsEnabled", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areBuildingsEnabled", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(areBuildingsEnabledWithError:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to " - @"@selector(areBuildingsEnabledWithError:)", - api); + NSCAssert([api respondsToSelector:@selector(areBuildingsEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(areBuildingsEnabledWithError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api areBuildingsEnabledWithError:&error]; @@ -3041,18 +2727,13 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.areRotateGesturesEnabled", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areRotateGesturesEnabled", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(areRotateGesturesEnabledWithError:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to " - @"@selector(areRotateGesturesEnabledWithError:)", - api); + NSCAssert([api respondsToSelector:@selector(areRotateGesturesEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(areRotateGesturesEnabledWithError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api areRotateGesturesEnabledWithError:&error]; @@ -3063,18 +2744,13 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.areScrollGesturesEnabled", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areScrollGesturesEnabled", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(areScrollGesturesEnabledWithError:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to " - @"@selector(areScrollGesturesEnabledWithError:)", - api); + NSCAssert([api respondsToSelector:@selector(areScrollGesturesEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(areScrollGesturesEnabledWithError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api areScrollGesturesEnabledWithError:&error]; @@ -3085,18 +2761,13 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.areTiltGesturesEnabled", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areTiltGesturesEnabled", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(areTiltGesturesEnabledWithError:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to " - @"@selector(areTiltGesturesEnabledWithError:)", - api); + NSCAssert([api respondsToSelector:@selector(areTiltGesturesEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(areTiltGesturesEnabledWithError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api areTiltGesturesEnabledWithError:&error]; @@ -3107,18 +2778,13 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.areZoomGesturesEnabled", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areZoomGesturesEnabled", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(areZoomGesturesEnabledWithError:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to " - @"@selector(areZoomGesturesEnabledWithError:)", - api); + NSCAssert([api respondsToSelector:@selector(areZoomGesturesEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(areZoomGesturesEnabledWithError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api areZoomGesturesEnabledWithError:&error]; @@ -3129,18 +2795,13 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.isCompassEnabled", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isCompassEnabled", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert( - [api respondsToSelector:@selector(isCompassEnabledWithError:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(isCompassEnabledWithError:)", - api); + NSCAssert([api respondsToSelector:@selector(isCompassEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(isCompassEnabledWithError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api isCompassEnabledWithError:&error]; @@ -3151,18 +2812,13 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.isMyLocationButtonEnabled", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isMyLocationButtonEnabled", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(isMyLocationButtonEnabledWithError:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to " - @"@selector(isMyLocationButtonEnabledWithError:)", - api); + NSCAssert([api respondsToSelector:@selector(isMyLocationButtonEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(isMyLocationButtonEnabledWithError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api isMyLocationButtonEnabledWithError:&error]; @@ -3173,18 +2829,13 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.isTrafficEnabled", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isTrafficEnabled", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert( - [api respondsToSelector:@selector(isTrafficEnabledWithError:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(isTrafficEnabledWithError:)", - api); + NSCAssert([api respondsToSelector:@selector(isTrafficEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(isTrafficEnabledWithError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api isTrafficEnabledWithError:&error]; @@ -3195,24 +2846,18 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.getTileOverlayInfo", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getTileOverlayInfo", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(tileOverlayWithIdentifier:error:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to " - @"@selector(tileOverlayWithIdentifier:error:)", - api); + NSCAssert([api respondsToSelector:@selector(tileOverlayWithIdentifier:error:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(tileOverlayWithIdentifier:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_tileOverlayId = GetNullableObjectAtIndex(args, 0); FlutterError *error; - FGMPlatformTileLayer *output = [api tileOverlayWithIdentifier:arg_tileOverlayId - error:&error]; + FGMPlatformTileLayer *output = [api tileOverlayWithIdentifier:arg_tileOverlayId error:&error]; callback(wrapResult(output, error)); }]; } else { @@ -3220,24 +2865,18 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.getGroundOverlayInfo", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getGroundOverlayInfo", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(groundOverlayWithIdentifier:error:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to " - @"@selector(groundOverlayWithIdentifier:error:)", - api); + NSCAssert([api respondsToSelector:@selector(groundOverlayWithIdentifier:error:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(groundOverlayWithIdentifier:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_groundOverlayId = GetNullableObjectAtIndex(args, 0); FlutterError *error; - FGMPlatformGroundOverlay *output = [api groundOverlayWithIdentifier:arg_groundOverlayId - error:&error]; + FGMPlatformGroundOverlay *output = [api groundOverlayWithIdentifier:arg_groundOverlayId error:&error]; callback(wrapResult(output, error)); }]; } else { @@ -3245,18 +2884,13 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.getHeatmapInfo", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getHeatmapInfo", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(heatmapWithIdentifier:error:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to " - @"@selector(heatmapWithIdentifier:error:)", - api); + NSCAssert([api respondsToSelector:@selector(heatmapWithIdentifier:error:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(heatmapWithIdentifier:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_heatmapId = GetNullableObjectAtIndex(args, 0); @@ -3269,16 +2903,13 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.getZoomRange", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getZoomRange", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(zoomRange:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(zoomRange:)", api); + NSCAssert([api respondsToSelector:@selector(zoomRange:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(zoomRange:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; FGMPlatformZoomRange *output = [api zoomRange:&error]; @@ -3289,24 +2920,18 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", - @"dev.flutter.pigeon.google_maps_flutter_ios." - @"MapsInspectorApi.getClusters", - messageChannelSuffix] + FlutterBasicMessageChannel *channel = + [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getClusters", messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(clustersWithIdentifier:error:)], - @"FGMMapsInspectorApi api (%@) doesn't respond to " - @"@selector(clustersWithIdentifier:error:)", - api); + NSCAssert([api respondsToSelector:@selector(clustersWithIdentifier:error:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(clustersWithIdentifier:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_clusterManagerId = GetNullableObjectAtIndex(args, 0); FlutterError *error; - NSArray *output = [api clustersWithIdentifier:arg_clusterManagerId - error:&error]; + NSArray *output = [api clustersWithIdentifier:arg_clusterManagerId error:&error]; callback(wrapResult(output, error)); }]; } else { diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/lib/src/google_maps_flutter_ios.dart b/packages/google_maps_flutter/google_maps_flutter_ios/lib/src/google_maps_flutter_ios.dart index 66417f2e9317..475c40bcbadb 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/lib/src/google_maps_flutter_ios.dart +++ b/packages/google_maps_flutter/google_maps_flutter_ios/lib/src/google_maps_flutter_ios.dart @@ -628,10 +628,6 @@ class GoogleMapsFlutterIOS extends GoogleMapsFlutterPlatform { return PlatformSize(width: size.width, height: size.height); } - static PlatformDoublePair _platformPairFromOffset(Offset offset) { - return PlatformDoublePair(x: offset.dx, y: offset.dy); - } - static PlatformCircle _platformCircleFromCircle(Circle circle) { return PlatformCircle( consumeTapEvents: circle.consumeTapEvents, @@ -681,7 +677,7 @@ class GoogleMapsFlutterIOS extends GoogleMapsFlutterPlatform { return PlatformGroundOverlay( groundOverlayId: groundOverlay.groundOverlayId.value, anchor: groundOverlay.anchor != null - ? _platformPairFromOffset(groundOverlay.anchor!) + ? _platformPointFromOffset(groundOverlay.anchor!) : null, image: platformBitmapFromBitmapDescriptor(groundOverlay.image), position: groundOverlay.position != null diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/lib/src/messages.g.dart b/packages/google_maps_flutter/google_maps_flutter_ios/lib/src/messages.g.dart index 3f488ac25719..30c71049fbb1 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/lib/src/messages.g.dart +++ b/packages/google_maps_flutter/google_maps_flutter_ios/lib/src/messages.g.dart @@ -1,7 +1,7 @@ // Copyright 2013 The Flutter Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// Autogenerated from Pigeon (v22.7.2), do not edit directly. +// Autogenerated from Pigeon (v22.7.0), do not edit directly. // See also: https://pub.dev/packages/pigeon // ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, prefer_null_aware_operators, omit_local_variable_types, unused_shown_name, unnecessary_import, no_leading_underscores_for_local_identifiers @@ -18,8 +18,7 @@ PlatformException _createConnectionError(String channelName) { ); } -List wrapResponse( - {Object? result, PlatformException? error, bool empty = false}) { +List wrapResponse({Object? result, PlatformException? error, bool empty = false}) { if (empty) { return []; } @@ -935,33 +934,6 @@ class PlatformCameraTargetBounds { } } -/// Pair of double values, such as for an offset or size. -class PlatformDoublePair { - PlatformDoublePair({ - required this.x, - required this.y, - }); - - double x; - - double y; - - Object encode() { - return [ - x, - y, - ]; - } - - static PlatformDoublePair decode(Object result) { - result as List; - return PlatformDoublePair( - x: result[0]! as double, - y: result[1]! as double, - ); - } -} - /// Pigeon equivalent of the GroundOverlay class. class PlatformGroundOverlay { PlatformGroundOverlay({ @@ -986,7 +958,7 @@ class PlatformGroundOverlay { PlatformLatLngBounds? bounds; - PlatformDoublePair? anchor; + PlatformPoint? anchor; double transparency; @@ -1023,7 +995,7 @@ class PlatformGroundOverlay { image: result[1]! as PlatformBitmap, position: result[2] as PlatformLatLng?, bounds: result[3] as PlatformLatLngBounds?, - anchor: result[4] as PlatformDoublePair?, + anchor: result[4] as PlatformPoint?, transparency: result[5]! as double, bearing: result[6]! as double, zIndex: result[7]! as double, @@ -1094,12 +1066,9 @@ class PlatformMapViewCreationParams { initialPolygons: (result[4] as List?)!.cast(), initialPolylines: (result[5] as List?)!.cast(), initialHeatmaps: (result[6] as List?)!.cast(), - initialTileOverlays: - (result[7] as List?)!.cast(), - initialClusterManagers: - (result[8] as List?)!.cast(), - initialGroundOverlays: - (result[9] as List?)!.cast(), + initialTileOverlays: (result[7] as List?)!.cast(), + initialClusterManagers: (result[8] as List?)!.cast(), + initialGroundOverlays: (result[9] as List?)!.cast(), ); } } @@ -1547,6 +1516,7 @@ class PlatformBitmapBytesMap { } } + class _PigeonCodec extends StandardMessageCodec { const _PigeonCodec(); @override @@ -1554,138 +1524,135 @@ class _PigeonCodec extends StandardMessageCodec { if (value is int) { buffer.putUint8(4); buffer.putInt64(value); - } else if (value is PlatformMapType) { + } else if (value is PlatformMapType) { buffer.putUint8(129); writeValue(buffer, value.index); - } else if (value is PlatformJointType) { + } else if (value is PlatformJointType) { buffer.putUint8(130); writeValue(buffer, value.index); - } else if (value is PlatformPatternItemType) { + } else if (value is PlatformPatternItemType) { buffer.putUint8(131); writeValue(buffer, value.index); - } else if (value is PlatformMapBitmapScaling) { + } else if (value is PlatformMapBitmapScaling) { buffer.putUint8(132); writeValue(buffer, value.index); - } else if (value is PlatformCameraPosition) { + } else if (value is PlatformCameraPosition) { buffer.putUint8(133); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdate) { + } else if (value is PlatformCameraUpdate) { buffer.putUint8(134); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateNewCameraPosition) { + } else if (value is PlatformCameraUpdateNewCameraPosition) { buffer.putUint8(135); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateNewLatLng) { + } else if (value is PlatformCameraUpdateNewLatLng) { buffer.putUint8(136); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateNewLatLngBounds) { + } else if (value is PlatformCameraUpdateNewLatLngBounds) { buffer.putUint8(137); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateNewLatLngZoom) { + } else if (value is PlatformCameraUpdateNewLatLngZoom) { buffer.putUint8(138); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateScrollBy) { + } else if (value is PlatformCameraUpdateScrollBy) { buffer.putUint8(139); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateZoomBy) { + } else if (value is PlatformCameraUpdateZoomBy) { buffer.putUint8(140); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateZoom) { + } else if (value is PlatformCameraUpdateZoom) { buffer.putUint8(141); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateZoomTo) { + } else if (value is PlatformCameraUpdateZoomTo) { buffer.putUint8(142); writeValue(buffer, value.encode()); - } else if (value is PlatformCircle) { + } else if (value is PlatformCircle) { buffer.putUint8(143); writeValue(buffer, value.encode()); - } else if (value is PlatformHeatmap) { + } else if (value is PlatformHeatmap) { buffer.putUint8(144); writeValue(buffer, value.encode()); - } else if (value is PlatformInfoWindow) { + } else if (value is PlatformInfoWindow) { buffer.putUint8(145); writeValue(buffer, value.encode()); - } else if (value is PlatformCluster) { + } else if (value is PlatformCluster) { buffer.putUint8(146); writeValue(buffer, value.encode()); - } else if (value is PlatformClusterManager) { + } else if (value is PlatformClusterManager) { buffer.putUint8(147); writeValue(buffer, value.encode()); - } else if (value is PlatformMarker) { + } else if (value is PlatformMarker) { buffer.putUint8(148); writeValue(buffer, value.encode()); - } else if (value is PlatformPolygon) { + } else if (value is PlatformPolygon) { buffer.putUint8(149); writeValue(buffer, value.encode()); - } else if (value is PlatformPolyline) { + } else if (value is PlatformPolyline) { buffer.putUint8(150); writeValue(buffer, value.encode()); - } else if (value is PlatformPatternItem) { + } else if (value is PlatformPatternItem) { buffer.putUint8(151); writeValue(buffer, value.encode()); - } else if (value is PlatformTile) { + } else if (value is PlatformTile) { buffer.putUint8(152); writeValue(buffer, value.encode()); - } else if (value is PlatformTileOverlay) { + } else if (value is PlatformTileOverlay) { buffer.putUint8(153); writeValue(buffer, value.encode()); - } else if (value is PlatformEdgeInsets) { + } else if (value is PlatformEdgeInsets) { buffer.putUint8(154); writeValue(buffer, value.encode()); - } else if (value is PlatformLatLng) { + } else if (value is PlatformLatLng) { buffer.putUint8(155); writeValue(buffer, value.encode()); - } else if (value is PlatformLatLngBounds) { + } else if (value is PlatformLatLngBounds) { buffer.putUint8(156); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraTargetBounds) { + } else if (value is PlatformCameraTargetBounds) { buffer.putUint8(157); writeValue(buffer, value.encode()); - } else if (value is PlatformDoublePair) { + } else if (value is PlatformGroundOverlay) { buffer.putUint8(158); writeValue(buffer, value.encode()); - } else if (value is PlatformGroundOverlay) { + } else if (value is PlatformMapViewCreationParams) { buffer.putUint8(159); writeValue(buffer, value.encode()); - } else if (value is PlatformMapViewCreationParams) { + } else if (value is PlatformMapConfiguration) { buffer.putUint8(160); writeValue(buffer, value.encode()); - } else if (value is PlatformMapConfiguration) { + } else if (value is PlatformPoint) { buffer.putUint8(161); writeValue(buffer, value.encode()); - } else if (value is PlatformPoint) { + } else if (value is PlatformSize) { buffer.putUint8(162); writeValue(buffer, value.encode()); - } else if (value is PlatformSize) { + } else if (value is PlatformTileLayer) { buffer.putUint8(163); writeValue(buffer, value.encode()); - } else if (value is PlatformTileLayer) { + } else if (value is PlatformZoomRange) { buffer.putUint8(164); writeValue(buffer, value.encode()); - } else if (value is PlatformZoomRange) { + } else if (value is PlatformBitmap) { buffer.putUint8(165); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmap) { + } else if (value is PlatformBitmapDefaultMarker) { buffer.putUint8(166); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmapDefaultMarker) { + } else if (value is PlatformBitmapBytes) { buffer.putUint8(167); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmapBytes) { + } else if (value is PlatformBitmapAsset) { buffer.putUint8(168); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmapAsset) { + } else if (value is PlatformBitmapAssetImage) { buffer.putUint8(169); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmapAssetImage) { + } else if (value is PlatformBitmapAssetMap) { buffer.putUint8(170); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmapAssetMap) { + } else if (value is PlatformBitmapBytesMap) { buffer.putUint8(171); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmapBytesMap) { - buffer.putUint8(172); - writeValue(buffer, value.encode()); } else { super.writeValue(buffer, value); } @@ -1694,97 +1661,95 @@ class _PigeonCodec extends StandardMessageCodec { @override Object? readValueOfType(int type, ReadBuffer buffer) { switch (type) { - case 129: + case 129: final int? value = readValue(buffer) as int?; return value == null ? null : PlatformMapType.values[value]; - case 130: + case 130: final int? value = readValue(buffer) as int?; return value == null ? null : PlatformJointType.values[value]; - case 131: + case 131: final int? value = readValue(buffer) as int?; return value == null ? null : PlatformPatternItemType.values[value]; - case 132: + case 132: final int? value = readValue(buffer) as int?; return value == null ? null : PlatformMapBitmapScaling.values[value]; - case 133: + case 133: return PlatformCameraPosition.decode(readValue(buffer)!); - case 134: + case 134: return PlatformCameraUpdate.decode(readValue(buffer)!); - case 135: + case 135: return PlatformCameraUpdateNewCameraPosition.decode(readValue(buffer)!); - case 136: + case 136: return PlatformCameraUpdateNewLatLng.decode(readValue(buffer)!); - case 137: + case 137: return PlatformCameraUpdateNewLatLngBounds.decode(readValue(buffer)!); - case 138: + case 138: return PlatformCameraUpdateNewLatLngZoom.decode(readValue(buffer)!); - case 139: + case 139: return PlatformCameraUpdateScrollBy.decode(readValue(buffer)!); - case 140: + case 140: return PlatformCameraUpdateZoomBy.decode(readValue(buffer)!); - case 141: + case 141: return PlatformCameraUpdateZoom.decode(readValue(buffer)!); - case 142: + case 142: return PlatformCameraUpdateZoomTo.decode(readValue(buffer)!); - case 143: + case 143: return PlatformCircle.decode(readValue(buffer)!); - case 144: + case 144: return PlatformHeatmap.decode(readValue(buffer)!); - case 145: + case 145: return PlatformInfoWindow.decode(readValue(buffer)!); - case 146: + case 146: return PlatformCluster.decode(readValue(buffer)!); - case 147: + case 147: return PlatformClusterManager.decode(readValue(buffer)!); - case 148: + case 148: return PlatformMarker.decode(readValue(buffer)!); - case 149: + case 149: return PlatformPolygon.decode(readValue(buffer)!); - case 150: + case 150: return PlatformPolyline.decode(readValue(buffer)!); - case 151: + case 151: return PlatformPatternItem.decode(readValue(buffer)!); - case 152: + case 152: return PlatformTile.decode(readValue(buffer)!); - case 153: + case 153: return PlatformTileOverlay.decode(readValue(buffer)!); - case 154: + case 154: return PlatformEdgeInsets.decode(readValue(buffer)!); - case 155: + case 155: return PlatformLatLng.decode(readValue(buffer)!); - case 156: + case 156: return PlatformLatLngBounds.decode(readValue(buffer)!); - case 157: + case 157: return PlatformCameraTargetBounds.decode(readValue(buffer)!); - case 158: - return PlatformDoublePair.decode(readValue(buffer)!); - case 159: + case 158: return PlatformGroundOverlay.decode(readValue(buffer)!); - case 160: + case 159: return PlatformMapViewCreationParams.decode(readValue(buffer)!); - case 161: + case 160: return PlatformMapConfiguration.decode(readValue(buffer)!); - case 162: + case 161: return PlatformPoint.decode(readValue(buffer)!); - case 163: + case 162: return PlatformSize.decode(readValue(buffer)!); - case 164: + case 163: return PlatformTileLayer.decode(readValue(buffer)!); - case 165: + case 164: return PlatformZoomRange.decode(readValue(buffer)!); - case 166: + case 165: return PlatformBitmap.decode(readValue(buffer)!); - case 167: + case 166: return PlatformBitmapDefaultMarker.decode(readValue(buffer)!); - case 168: + case 167: return PlatformBitmapBytes.decode(readValue(buffer)!); - case 169: + case 168: return PlatformBitmapAsset.decode(readValue(buffer)!); - case 170: + case 169: return PlatformBitmapAssetImage.decode(readValue(buffer)!); - case 171: + case 170: return PlatformBitmapAssetMap.decode(readValue(buffer)!); - case 172: + case 171: return PlatformBitmapBytesMap.decode(readValue(buffer)!); default: return super.readValueOfType(type, buffer); @@ -1801,8 +1766,7 @@ class MapsApi { /// BinaryMessenger will be used which routes to the host platform. MapsApi({BinaryMessenger? binaryMessenger, String messageChannelSuffix = ''}) : pigeonVar_binaryMessenger = binaryMessenger, - pigeonVar_messageChannelSuffix = - messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; + pigeonVar_messageChannelSuffix = messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; final BinaryMessenger? pigeonVar_binaryMessenger; static const MessageCodec pigeonChannelCodec = _PigeonCodec(); @@ -1811,10 +1775,8 @@ class MapsApi { /// Returns once the map instance is available. Future waitForMap() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.waitForMap$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.waitForMap$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -1838,18 +1800,15 @@ class MapsApi { /// /// Only non-null configuration values will result in updates; options with /// null values will remain unchanged. - Future updateMapConfiguration( - PlatformMapConfiguration configuration) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMapConfiguration$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + Future updateMapConfiguration(PlatformMapConfiguration configuration) async { + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMapConfiguration$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([configuration]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([configuration]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1864,18 +1823,15 @@ class MapsApi { } /// Updates the set of circles on the map. - Future updateCircles(List toAdd, - List toChange, List idsToRemove) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateCircles$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + Future updateCircles(List toAdd, List toChange, List idsToRemove) async { + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateCircles$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1890,18 +1846,15 @@ class MapsApi { } /// Updates the set of heatmaps on the map. - Future updateHeatmaps(List toAdd, - List toChange, List idsToRemove) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateHeatmaps$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + Future updateHeatmaps(List toAdd, List toChange, List idsToRemove) async { + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateHeatmaps$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1916,18 +1869,15 @@ class MapsApi { } /// Updates the set of custer managers for clusters on the map. - Future updateClusterManagers( - List toAdd, List idsToRemove) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateClusterManagers$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + Future updateClusterManagers(List toAdd, List idsToRemove) async { + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateClusterManagers$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([toAdd, idsToRemove]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([toAdd, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1942,18 +1892,15 @@ class MapsApi { } /// Updates the set of markers on the map. - Future updateMarkers(List toAdd, - List toChange, List idsToRemove) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMarkers$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + Future updateMarkers(List toAdd, List toChange, List idsToRemove) async { + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMarkers$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1968,18 +1915,15 @@ class MapsApi { } /// Updates the set of polygonss on the map. - Future updatePolygons(List toAdd, - List toChange, List idsToRemove) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updatePolygons$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + Future updatePolygons(List toAdd, List toChange, List idsToRemove) async { + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updatePolygons$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1994,18 +1938,15 @@ class MapsApi { } /// Updates the set of polylines on the map. - Future updatePolylines(List toAdd, - List toChange, List idsToRemove) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updatePolylines$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + Future updatePolylines(List toAdd, List toChange, List idsToRemove) async { + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updatePolylines$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -2020,18 +1961,15 @@ class MapsApi { } /// Updates the set of tile overlays on the map. - Future updateTileOverlays(List toAdd, - List toChange, List idsToRemove) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateTileOverlays$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + Future updateTileOverlays(List toAdd, List toChange, List idsToRemove) async { + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateTileOverlays$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -2046,18 +1984,15 @@ class MapsApi { } /// Updates the set of ground overlays on the map. - Future updateGroundOverlays(List toAdd, - List toChange, List idsToRemove) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateGroundOverlays$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + Future updateGroundOverlays(List toAdd, List toChange, List idsToRemove) async { + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateGroundOverlays$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -2073,10 +2008,8 @@ class MapsApi { /// Gets the screen coordinate for the given map location. Future getScreenCoordinate(PlatformLatLng latLng) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getScreenCoordinate$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getScreenCoordinate$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2103,16 +2036,14 @@ class MapsApi { /// Gets the map location for the given screen coordinate. Future getLatLng(PlatformPoint screenCoordinate) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLatLng$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLatLng$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([screenCoordinate]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([screenCoordinate]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -2133,10 +2064,8 @@ class MapsApi { /// Gets the map region currently displayed on the map. Future getVisibleRegion() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getVisibleRegion$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getVisibleRegion$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2164,10 +2093,8 @@ class MapsApi { /// Moves the camera according to [cameraUpdate] immediately, with no /// animation. Future moveCamera(PlatformCameraUpdate cameraUpdate) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.moveCamera$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.moveCamera$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2189,10 +2116,8 @@ class MapsApi { /// Moves the camera according to [cameraUpdate], animating the update. Future animateCamera(PlatformCameraUpdate cameraUpdate) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.animateCamera$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.animateCamera$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2214,10 +2139,8 @@ class MapsApi { /// Gets the current map zoom level. Future getZoomLevel() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getZoomLevel$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getZoomLevel$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2244,10 +2167,8 @@ class MapsApi { /// Show the info window for the marker with the given ID. Future showInfoWindow(String markerId) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.showInfoWindow$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.showInfoWindow$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2269,10 +2190,8 @@ class MapsApi { /// Hide the info window for the marker with the given ID. Future hideInfoWindow(String markerId) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.hideInfoWindow$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.hideInfoWindow$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2295,10 +2214,8 @@ class MapsApi { /// Returns true if the marker with the given ID is currently displaying its /// info window. Future isInfoWindowShown(String markerId) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.isInfoWindowShown$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.isInfoWindowShown$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2329,10 +2246,8 @@ class MapsApi { /// If there was an error setting the style, such as an invalid style string, /// returns the error message. Future setStyle(String style) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.setStyle$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.setStyle$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2358,10 +2273,8 @@ class MapsApi { /// This allows checking asynchronously for initial style failures, as there /// is no way to return failures from map initialization. Future getLastStyleError() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLastStyleError$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLastStyleError$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2383,16 +2296,14 @@ class MapsApi { /// Clears the cache of tiles previously requseted from the tile provider. Future clearTileCache(String tileOverlayId) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.clearTileCache$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.clearTileCache$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([tileOverlayId]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([tileOverlayId]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -2408,10 +2319,8 @@ class MapsApi { /// Takes a snapshot of the map and returns its image data. Future takeSnapshot() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.takeSnapshot$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.takeSnapshot$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2482,22 +2391,13 @@ abstract class MapsCallbackApi { void onGroundOverlayTap(String groundOverlayId); /// Called to get data for a map tile. - Future getTileOverlayTile( - String tileOverlayId, PlatformPoint location, int zoom); - - static void setUp( - MapsCallbackApi? api, { - BinaryMessenger? binaryMessenger, - String messageChannelSuffix = '', - }) { - messageChannelSuffix = - messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; + Future getTileOverlayTile(String tileOverlayId, PlatformPoint location, int zoom); + + static void setUp(MapsCallbackApi? api, {BinaryMessenger? binaryMessenger, String messageChannelSuffix = '',}) { + messageChannelSuffix = messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMoveStarted$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMoveStarted$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); @@ -2508,29 +2408,24 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove was null.'); final List args = (message as List?)!; - final PlatformCameraPosition? arg_cameraPosition = - (args[0] as PlatformCameraPosition?); + final PlatformCameraPosition? arg_cameraPosition = (args[0] as PlatformCameraPosition?); assert(arg_cameraPosition != null, 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove was null, expected non-null PlatformCameraPosition.'); try { @@ -2538,19 +2433,15 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraIdle$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraIdle$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); @@ -2561,26 +2452,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onTap$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onTap$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onTap was null.'); final List args = (message as List?)!; final PlatformLatLng? arg_position = (args[0] as PlatformLatLng?); assert(arg_position != null, @@ -2590,26 +2477,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onLongPress$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onLongPress$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onLongPress was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onLongPress was null.'); final List args = (message as List?)!; final PlatformLatLng? arg_position = (args[0] as PlatformLatLng?); assert(arg_position != null, @@ -2619,26 +2502,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerTap$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerTap$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerTap was null.'); final List args = (message as List?)!; final String? arg_markerId = (args[0] as String?); assert(arg_markerId != null, @@ -2648,26 +2527,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragStart$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragStart$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragStart was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragStart was null.'); final List args = (message as List?)!; final String? arg_markerId = (args[0] as String?); assert(arg_markerId != null, @@ -2680,26 +2555,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDrag$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDrag$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDrag was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDrag was null.'); final List args = (message as List?)!; final String? arg_markerId = (args[0] as String?); assert(arg_markerId != null, @@ -2712,26 +2583,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragEnd$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragEnd$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragEnd was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragEnd was null.'); final List args = (message as List?)!; final String? arg_markerId = (args[0] as String?); assert(arg_markerId != null, @@ -2744,26 +2611,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onInfoWindowTap$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onInfoWindowTap$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onInfoWindowTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onInfoWindowTap was null.'); final List args = (message as List?)!; final String? arg_markerId = (args[0] as String?); assert(arg_markerId != null, @@ -2773,26 +2636,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCircleTap$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCircleTap$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCircleTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCircleTap was null.'); final List args = (message as List?)!; final String? arg_circleId = (args[0] as String?); assert(arg_circleId != null, @@ -2802,26 +2661,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onClusterTap$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onClusterTap$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onClusterTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onClusterTap was null.'); final List args = (message as List?)!; final PlatformCluster? arg_cluster = (args[0] as PlatformCluster?); assert(arg_cluster != null, @@ -2831,26 +2686,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolygonTap$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolygonTap$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolygonTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolygonTap was null.'); final List args = (message as List?)!; final String? arg_polygonId = (args[0] as String?); assert(arg_polygonId != null, @@ -2860,26 +2711,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolylineTap$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolylineTap$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolylineTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolylineTap was null.'); final List args = (message as List?)!; final String? arg_polylineId = (args[0] as String?); assert(arg_polylineId != null, @@ -2889,26 +2736,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onGroundOverlayTap$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onGroundOverlayTap$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onGroundOverlayTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onGroundOverlayTap was null.'); final List args = (message as List?)!; final String? arg_groundOverlayId = (args[0] as String?); assert(arg_groundOverlayId != null, @@ -2918,26 +2761,22 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel< - Object?> pigeonVar_channel = BasicMessageChannel< - Object?>( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile$messageChannelSuffix', - pigeonChannelCodec, + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile$messageChannelSuffix', pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile was null.'); final List args = (message as List?)!; final String? arg_tileOverlayId = (args[0] as String?); assert(arg_tileOverlayId != null, @@ -2949,14 +2788,12 @@ abstract class MapsCallbackApi { assert(arg_zoom != null, 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile was null, expected non-null int.'); try { - final PlatformTile output = await api.getTileOverlayTile( - arg_tileOverlayId!, arg_location!, arg_zoom!); + final PlatformTile output = await api.getTileOverlayTile(arg_tileOverlayId!, arg_location!, arg_zoom!); return wrapResponse(result: output); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse( - error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); } }); } @@ -2971,11 +2808,9 @@ class MapsPlatformViewApi { /// Constructor for [MapsPlatformViewApi]. The [binaryMessenger] named argument is /// available for dependency injection. If it is left null, the default /// BinaryMessenger will be used which routes to the host platform. - MapsPlatformViewApi( - {BinaryMessenger? binaryMessenger, String messageChannelSuffix = ''}) + MapsPlatformViewApi({BinaryMessenger? binaryMessenger, String messageChannelSuffix = ''}) : pigeonVar_binaryMessenger = binaryMessenger, - pigeonVar_messageChannelSuffix = - messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; + pigeonVar_messageChannelSuffix = messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; final BinaryMessenger? pigeonVar_binaryMessenger; static const MessageCodec pigeonChannelCodec = _PigeonCodec(); @@ -2983,10 +2818,8 @@ class MapsPlatformViewApi { final String pigeonVar_messageChannelSuffix; Future createView(PlatformMapViewCreationParams? type) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsPlatformViewApi.createView$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsPlatformViewApi.createView$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3012,11 +2845,9 @@ class MapsInspectorApi { /// Constructor for [MapsInspectorApi]. The [binaryMessenger] named argument is /// available for dependency injection. If it is left null, the default /// BinaryMessenger will be used which routes to the host platform. - MapsInspectorApi( - {BinaryMessenger? binaryMessenger, String messageChannelSuffix = ''}) + MapsInspectorApi({BinaryMessenger? binaryMessenger, String messageChannelSuffix = ''}) : pigeonVar_binaryMessenger = binaryMessenger, - pigeonVar_messageChannelSuffix = - messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; + pigeonVar_messageChannelSuffix = messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; final BinaryMessenger? pigeonVar_binaryMessenger; static const MessageCodec pigeonChannelCodec = _PigeonCodec(); @@ -3024,10 +2855,8 @@ class MapsInspectorApi { final String pigeonVar_messageChannelSuffix; Future areBuildingsEnabled() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areBuildingsEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areBuildingsEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3053,10 +2882,8 @@ class MapsInspectorApi { } Future areRotateGesturesEnabled() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areRotateGesturesEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areRotateGesturesEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3082,10 +2909,8 @@ class MapsInspectorApi { } Future areScrollGesturesEnabled() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areScrollGesturesEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areScrollGesturesEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3111,10 +2936,8 @@ class MapsInspectorApi { } Future areTiltGesturesEnabled() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areTiltGesturesEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areTiltGesturesEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3140,10 +2963,8 @@ class MapsInspectorApi { } Future areZoomGesturesEnabled() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areZoomGesturesEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areZoomGesturesEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3169,10 +2990,8 @@ class MapsInspectorApi { } Future isCompassEnabled() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isCompassEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isCompassEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3198,10 +3017,8 @@ class MapsInspectorApi { } Future isMyLocationButtonEnabled() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isMyLocationButtonEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isMyLocationButtonEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3227,10 +3044,8 @@ class MapsInspectorApi { } Future isTrafficEnabled() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isTrafficEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isTrafficEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3256,16 +3071,14 @@ class MapsInspectorApi { } Future getTileOverlayInfo(String tileOverlayId) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getTileOverlayInfo$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getTileOverlayInfo$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([tileOverlayId]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([tileOverlayId]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -3279,18 +3092,15 @@ class MapsInspectorApi { } } - Future getGroundOverlayInfo( - String groundOverlayId) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getGroundOverlayInfo$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + Future getGroundOverlayInfo(String groundOverlayId) async { + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getGroundOverlayInfo$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([groundOverlayId]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([groundOverlayId]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -3305,10 +3115,8 @@ class MapsInspectorApi { } Future getHeatmapInfo(String heatmapId) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getHeatmapInfo$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getHeatmapInfo$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3329,10 +3137,8 @@ class MapsInspectorApi { } Future getZoomRange() async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getZoomRange$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getZoomRange$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3358,16 +3164,14 @@ class MapsInspectorApi { } Future> getClusters(String clusterManagerId) async { - final String pigeonVar_channelName = - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getClusters$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = - BasicMessageChannel( + final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getClusters$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = await pigeonVar_channel - .send([clusterManagerId]) as List?; + final List? pigeonVar_replyList = + await pigeonVar_channel.send([clusterManagerId]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -3382,8 +3186,7 @@ class MapsInspectorApi { message: 'Host platform returned null value for non-null return value.', ); } else { - return (pigeonVar_replyList[0] as List?)! - .cast(); + return (pigeonVar_replyList[0] as List?)!.cast(); } } } diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/pigeons/messages.dart b/packages/google_maps_flutter/google_maps_flutter_ios/pigeons/messages.dart index d754d03287e0..53ad85fa6eaf 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/pigeons/messages.dart +++ b/packages/google_maps_flutter/google_maps_flutter_ios/pigeons/messages.dart @@ -357,14 +357,6 @@ class PlatformCameraTargetBounds { final PlatformLatLngBounds? bounds; } -/// Pair of double values, such as for an offset or size. -class PlatformDoublePair { - PlatformDoublePair(this.x, this.y); - - final double x; - final double y; -} - /// Pigeon equivalent of the GroundOverlay class. class PlatformGroundOverlay { PlatformGroundOverlay({ @@ -385,7 +377,7 @@ class PlatformGroundOverlay { final PlatformBitmap image; final PlatformLatLng? position; final PlatformLatLngBounds? bounds; - final PlatformDoublePair? anchor; + final PlatformPoint? anchor; final double transparency; final double bearing; final double zIndex; From 6cf116dea59fd8b2d5d971ce2e3f86a3f41c5acc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20V=C3=A4limaa?= Date: Wed, 22 Jan 2025 18:42:03 +0800 Subject: [PATCH 3/4] refactor: refactor global functions --- .../RunnerTests/ExtractIconFromDataTests.m | 55 ++++++------------- .../ios/Classes/FGMGroundOverlayController.m | 6 +- .../ios/Classes/FGMImageUtils.h | 4 +- .../ios/Classes/FGMImageUtils.m | 42 +++++++------- .../ios/Classes/GoogleMapMarkerController.m | 2 +- 5 files changed, 45 insertions(+), 64 deletions(-) diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/RunnerTests/ExtractIconFromDataTests.m b/packages/google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/RunnerTests/ExtractIconFromDataTests.m index 01e4f07a5bd5..e0ca11d8e840 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/RunnerTests/ExtractIconFromDataTests.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/RunnerTests/ExtractIconFromDataTests.m @@ -31,9 +31,8 @@ - (void)testExtractIconFromDataAssetAuto { CGFloat screenScale = 3.0; - UIImage *resultImage = [FGMUtils iconFromBitmap:[FGMPlatformBitmap makeWithBitmap:bitmap] - registrar:mockRegistrar - screenScale:screenScale]; + UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); + XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, 1.0); XCTAssertEqual(resultImage.size.width, 1.0); @@ -58,9 +57,7 @@ - (void)testExtractIconFromDataAssetAutoWithScale { CGFloat screenScale = 3.0; - UIImage *resultImage = [FGMUtils iconFromBitmap:[FGMPlatformBitmap makeWithBitmap:bitmap] - registrar:mockRegistrar - screenScale:screenScale]; + UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, 10); @@ -88,9 +85,7 @@ - (void)testExtractIconFromDataAssetAutoAndSizeWithSameAspectRatio { CGFloat screenScale = 3.0; - UIImage *resultImage = [FGMUtils iconFromBitmap:[FGMPlatformBitmap makeWithBitmap:bitmap] - registrar:mockRegistrar - screenScale:screenScale]; + UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(testImage.scale, 1.0); @@ -123,9 +118,7 @@ - (void)testExtractIconFromDataAssetAutoAndSizeWithDifferentAspectRatio { CGFloat screenScale = 3.0; - UIImage *resultImage = [FGMUtils iconFromBitmap:[FGMPlatformBitmap makeWithBitmap:bitmap] - registrar:mockRegistrar - screenScale:screenScale]; + UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, screenScale); XCTAssertEqual(resultImage.size.width, width); @@ -150,9 +143,7 @@ - (void)testExtractIconFromDataAssetNoScaling { CGFloat screenScale = 3.0; - UIImage *resultImage = [FGMUtils iconFromBitmap:[FGMPlatformBitmap makeWithBitmap:bitmap] - registrar:mockRegistrar - screenScale:screenScale]; + UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, 1.0); @@ -177,9 +168,7 @@ - (void)testExtractIconFromDataBytesAuto { CGFloat screenScale = 3.0; - UIImage *resultImage = [FGMUtils iconFromBitmap:[FGMPlatformBitmap makeWithBitmap:bitmap] - registrar:mockRegistrar - screenScale:screenScale]; + UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, 1.0); @@ -204,9 +193,7 @@ - (void)testExtractIconFromDataBytesAutoWithScaling { CGFloat screenScale = 3.0; - UIImage *resultImage = [FGMUtils iconFromBitmap:[FGMPlatformBitmap makeWithBitmap:bitmap] - registrar:mockRegistrar - screenScale:screenScale]; + UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, 10); XCTAssertEqual(resultImage.size.width, 0.1); @@ -232,9 +219,7 @@ - (void)testExtractIconFromDataBytesAutoAndSizeWithSameAspectRatio { CGFloat screenScale = 3.0; - UIImage *resultImage = [FGMUtils iconFromBitmap:[FGMPlatformBitmap makeWithBitmap:bitmap] - registrar:mockRegistrar - screenScale:screenScale]; + UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(testImage.scale, 1.0); @@ -267,9 +252,7 @@ - (void)testExtractIconFromDataBytesAutoAndSizeWithDifferentAspectRatio { CGFloat screenScale = 3.0; - UIImage *resultImage = [FGMUtils iconFromBitmap:[FGMPlatformBitmap makeWithBitmap:bitmap] - registrar:mockRegistrar - screenScale:screenScale]; + UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, screenScale); XCTAssertEqual(resultImage.size.width, width); @@ -293,9 +276,7 @@ - (void)testExtractIconFromDataBytesNoScaling { CGFloat screenScale = 3.0; - UIImage *resultImage = [FGMUtils iconFromBitmap:[FGMPlatformBitmap makeWithBitmap:bitmap] - registrar:mockRegistrar - screenScale:screenScale]; + UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, 1.0); XCTAssertEqual(resultImage.size.width, 1.0); @@ -305,43 +286,43 @@ - (void)testExtractIconFromDataBytesNoScaling { - (void)testIsScalableWithScaleFactorFromSize100x100to10x100 { CGSize originalSize = CGSizeMake(100.0, 100.0); CGSize targetSize = CGSizeMake(10.0, 100.0); - XCTAssertFalse([FGMUtils isScalableWithScaleFactorFromSize:originalSize toSize:targetSize]); + XCTAssertFalse(FGMIsScalableWithScaleFactorFromSize(originalSize, targetSize)); } - (void)testIsScalableWithScaleFactorFromSize100x100to10x10 { CGSize originalSize = CGSizeMake(100.0, 100.0); CGSize targetSize = CGSizeMake(10.0, 10.0); - XCTAssertTrue([FGMUtils isScalableWithScaleFactorFromSize:originalSize toSize:targetSize]); + XCTAssertTrue(FGMIsScalableWithScaleFactorFromSize(originalSize, targetSize)); } - (void)testIsScalableWithScaleFactorFromSize233x200to23x20 { CGSize originalSize = CGSizeMake(233.0, 200.0); CGSize targetSize = CGSizeMake(23.0, 20.0); - XCTAssertTrue([FGMUtils isScalableWithScaleFactorFromSize:originalSize toSize:targetSize]); + XCTAssertTrue(FGMIsScalableWithScaleFactorFromSize(originalSize, targetSize)); } - (void)testIsScalableWithScaleFactorFromSize233x200to22x20 { CGSize originalSize = CGSizeMake(233.0, 200.0); CGSize targetSize = CGSizeMake(22.0, 20.0); - XCTAssertFalse([FGMUtils isScalableWithScaleFactorFromSize:originalSize toSize:targetSize]); + XCTAssertFalse(FGMIsScalableWithScaleFactorFromSize(originalSize, targetSize)); } - (void)testIsScalableWithScaleFactorFromSize200x233to20x23 { CGSize originalSize = CGSizeMake(200.0, 233.0); CGSize targetSize = CGSizeMake(20.0, 23.0); - XCTAssertTrue([FGMUtils isScalableWithScaleFactorFromSize:originalSize toSize:targetSize]); + XCTAssertTrue(FGMIsScalableWithScaleFactorFromSize(originalSize, targetSize)); } - (void)testIsScalableWithScaleFactorFromSize200x233to20x22 { CGSize originalSize = CGSizeMake(200.0, 233.0); CGSize targetSize = CGSizeMake(20.0, 22.0); - XCTAssertFalse([FGMUtils isScalableWithScaleFactorFromSize:originalSize toSize:targetSize]); + XCTAssertFalse(FGMIsScalableWithScaleFactorFromSize(originalSize, targetSize)); } - (void)testIsScalableWithScaleFactorFromSize1024x768to500x250 { CGSize originalSize = CGSizeMake(1024.0, 768.0); CGSize targetSize = CGSizeMake(500.0, 250.0); - XCTAssertFalse([FGMUtils isScalableWithScaleFactorFromSize:originalSize toSize:targetSize]); + XCTAssertFalse(FGMIsScalableWithScaleFactorFromSize(originalSize, targetSize)); } - (UIImage *)createOnePixelImage { diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.m index d5c3f3eace8a..c787abff4bfb 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.m @@ -78,7 +78,7 @@ - (void)updateFromPlatformGroundOverlay:(FGMPlatformGroundOverlay *)groundOverla [self setVisible:groundOverlay.visible]; [self setZIndex:(int)groundOverlay.zIndex]; [self setAnchor:CGPointMake(groundOverlay.anchor.x, groundOverlay.anchor.y)]; - UIImage *image = IconFromBitmap(groundOverlay.image, registrar, screenScale); + UIImage *image = FGMIconFromBitmap(groundOverlay.image, registrar, screenScale); [self setIcon:image]; [self setBearing:groundOverlay.bearing]; [self setTransparency:groundOverlay.transparency]; @@ -149,14 +149,14 @@ - (void)addGroundOverlays:(NSArray *)groundOverlaysT coordinate:CLLocationCoordinate2DMake( groundOverlay.bounds.southwest.latitude, groundOverlay.bounds.southwest.longitude)] - icon:IconFromBitmap(groundOverlay.image, self.registrar, [self getScreenScale])]; + icon:FGMIconFromBitmap(groundOverlay.image, self.registrar, [self getScreenScale])]; } else { NSAssert(groundOverlay.zoomLevel != nil, @"If ground overlay is initialized with position, zoomLevel is required"); gmsOverlay = [GMSGroundOverlay groundOverlayWithPosition:CLLocationCoordinate2DMake(groundOverlay.position.latitude, groundOverlay.position.longitude) - icon:IconFromBitmap(groundOverlay.image, self.registrar, [self getScreenScale]) + icon:FGMIconFromBitmap(groundOverlay.image, self.registrar, [self getScreenScale]) zoomLevel:[groundOverlay.zoomLevel doubleValue]]; } FGMGroundOverlayController *controller = diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.h b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.h index 155b4ecaf459..8a031daf5ecb 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.h +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.h @@ -9,10 +9,10 @@ NS_ASSUME_NONNULL_BEGIN /// Creates a UIImage from Pigeon bitmap. -UIImage *IconFromBitmap(FGMPlatformBitmap *platformBitmap, +UIImage *FGMIconFromBitmap(FGMPlatformBitmap *platformBitmap, NSObject *registrar, CGFloat screenScale); /// Returns a BOOL indicating whether image is considered scalable with the given scale factor from size. -BOOL IsScalableWithScaleFactorFromSize(CGSize originalSize, CGSize targetSize); +BOOL FGMIsScalableWithScaleFactorFromSize(CGSize originalSize, CGSize targetSize); NS_ASSUME_NONNULL_END diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.m index 4039fba028f5..76a3cb700931 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.m @@ -5,15 +5,15 @@ #import "FGMImageUtils.h" #import "Foundation/Foundation.h" -static UIImage * ScaleImage(UIImage *image, double scale); -static UIImage * ScaledImageWithScale(UIImage *image, CGFloat scale); -static UIImage * ScaledImageWithSize(UIImage *image, CGSize size); -static UIImage * ScaledImage(UIImage *image, +static UIImage * scaleImage(UIImage *image, double scale); +static UIImage * scaledImageWithScale(UIImage *image, CGFloat scale); +static UIImage * scaledImageWithSize(UIImage *image, CGSize size); +static UIImage * scaledImage(UIImage *image, NSNumber *width, NSNumber *height, CGFloat screenScale); -UIImage *IconFromBitmap(FGMPlatformBitmap *platformBitmap, +UIImage *FGMIconFromBitmap(FGMPlatformBitmap *platformBitmap, NSObject *registrar, CGFloat screenScale) { assert(screenScale > 0 && "Screen scale must be greater than 0"); @@ -43,7 +43,7 @@ // Refer to the flutter google_maps_flutter_platform_interface package for details. FGMPlatformBitmapAssetImage *bitmapAssetImage = bitmap; image = [UIImage imageNamed:[registrar lookupKeyForAsset:bitmapAssetImage.name]]; - image = ScaleImage(image, bitmapAssetImage.scale); + image = scaleImage(image, bitmapAssetImage.scale); } else if ([bitmap isKindOfClass:[FGMPlatformBitmapBytes class]]) { // Deprecated: This message handling for 'fromBytes' has been replaced by 'bytes'. // Refer to the flutter google_maps_flutter_platform_interface package for details. @@ -65,10 +65,10 @@ NSNumber *width = bitmapAssetMap.width; NSNumber *height = bitmapAssetMap.height; if (width || height) { - image = ScaledImageWithScale(image, screenScale); - image = ScaledImage(image, width, height, screenScale); + image = scaledImageWithScale(image, screenScale); + image = scaledImage(image, width, height, screenScale); } else { - image = ScaledImageWithScale(image, bitmapAssetMap.imagePixelRatio); + image = scaledImageWithScale(image, bitmapAssetMap.imagePixelRatio); } } } else if ([bitmap isKindOfClass:[FGMPlatformBitmapBytesMap class]]) { @@ -83,10 +83,10 @@ if (width || height) { // Before scaling the image, image must be in screenScale. - image = ScaledImageWithScale(image, screenScale); - image = ScaledImage(image, width, height, screenScale); + image = scaledImageWithScale(image, screenScale); + image = scaledImage(image, width, height, screenScale); } else { - image = ScaledImageWithScale(image, bitmapBytesMap.imagePixelRatio); + image = scaledImageWithScale(image, bitmapBytesMap.imagePixelRatio); } } else { // No scaling, load image from bytes without scale parameter. @@ -106,7 +106,7 @@ /// flutter google_maps_flutter_platform_interface package which has been replaced by 'bytes' /// message handling. It will be removed when the deprecated image bitmap description type /// 'fromBytes' is removed from the platform interface. -UIImage * ScaleImage(UIImage *image, double scale) { +UIImage * scaleImage(UIImage *image, double scale) { if (fabs(scale - 1) > 1e-3) { return [UIImage imageWithCGImage:[image CGImage] scale:(image.scale * scale) @@ -123,7 +123,7 @@ /// @param image The UIImage to scale. /// @param scale The factor by which to scale the image. /// @return UIImage Returns the scaled UIImage. -UIImage * ScaledImageWithScale(UIImage *image, CGFloat scale) { +UIImage * scaledImageWithScale(UIImage *image, CGFloat scale) { if (fabs(scale - image.scale) > DBL_EPSILON) { return [UIImage imageWithCGImage:[image CGImage] scale:scale @@ -140,7 +140,7 @@ /// @param image The UIImage to scale. /// @param size The target CGSize to scale the image to. /// @return UIImage Returns the scaled UIImage. -UIImage * ScaledImageWithSize(UIImage *image, CGSize size) { +UIImage * scaledImageWithSize(UIImage *image, CGSize size) { CGFloat originalPixelWidth = image.size.width * image.scale; CGFloat originalPixelHeight = image.size.height * image.scale; @@ -159,11 +159,11 @@ // Check if the aspect ratios are approximately equal. CGSize originalPixelSize = CGSizeMake(originalPixelWidth, originalPixelHeight); - if (IsScalableWithScaleFactorFromSize(originalPixelSize, size)) { + if (FGMIsScalableWithScaleFactorFromSize(originalPixelSize, size)) { // Scaled image has close to same aspect ratio, // updating image scale instead of resizing image. CGFloat factor = originalPixelWidth / size.width; - return ScaledImageWithScale(image, image.scale * factor); + return scaledImageWithScale(image, image.scale * factor); } else { // Aspect ratios differ significantly, resize the image. UIGraphicsImageRendererFormat *format = [UIGraphicsImageRendererFormat defaultFormat]; @@ -177,7 +177,7 @@ }]; // Return image with proper scaling. - return ScaledImageWithScale(newImage, image.scale); + return scaledImageWithScale(newImage, image.scale); } } @@ -189,7 +189,7 @@ /// @param height The target height to scale the image to. /// @param screenScale The current screen scale. /// @return UIImage Returns the scaled UIImage. -UIImage * ScaledImage(UIImage *image, +UIImage * scaledImage(UIImage *image, NSNumber *width, NSNumber *height, CGFloat screenScale) { @@ -212,10 +212,10 @@ CGSize targetSize = CGSizeMake(round(targetWidth * screenScale), round(targetHeight * screenScale)); - return ScaledImageWithSize(image, targetSize); + return scaledImageWithSize(image, targetSize); } -BOOL IsScalableWithScaleFactorFromSize(CGSize originalSize, CGSize targetSize) { +BOOL FGMIsScalableWithScaleFactorFromSize(CGSize originalSize, CGSize targetSize) { // Select the scaling factor based on the longer side to have good precision. CGFloat scaleFactor = (originalSize.width > originalSize.height) ? (targetSize.width / originalSize.width) diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/GoogleMapMarkerController.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/GoogleMapMarkerController.m index 3a0d0b827503..cdb9d3d388f2 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/GoogleMapMarkerController.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/GoogleMapMarkerController.m @@ -113,7 +113,7 @@ - (void)updateFromPlatformMarker:(FGMPlatformMarker *)platformMarker [self setAlpha:platformMarker.alpha]; [self setAnchor:FGMGetCGPointForPigeonPoint(platformMarker.anchor)]; [self setDraggable:platformMarker.draggable]; - UIImage *image = IconFromBitmap(platformMarker.icon, registrar, screenScale); + UIImage *image = FGMIconFromBitmap(platformMarker.icon, registrar, screenScale); [self setIcon:image]; [self setFlat:platformMarker.flat]; [self setConsumeTapEvents:platformMarker.consumeTapEvents]; From a6e8d461bcdf12b49a67edf4d47c5516479388bb Mon Sep 17 00:00:00 2001 From: Joonas Kerttula Date: Wed, 22 Jan 2025 16:25:52 +0200 Subject: [PATCH 4/4] Format ios code --- .../RunnerTests/ExtractIconFromDataTests.m | 30 +- .../ios/Classes/FGMGroundOverlayController.m | 6 +- .../ios/Classes/FGMImageUtils.h | 6 +- .../ios/Classes/FGMImageUtils.m | 25 +- .../ios/Classes/FLTGoogleMapJSONConversions.m | 4 +- .../ios/Classes/GoogleMapMarkerController.m | 2 +- .../google_maps_flutter_ios-umbrella.h | 2 +- .../ios/Classes/messages.g.h | 729 +++---- .../ios/Classes/messages.g.m | 1786 ++++++++++------- .../lib/src/messages.g.dart | 751 ++++--- 10 files changed, 1954 insertions(+), 1387 deletions(-) diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/RunnerTests/ExtractIconFromDataTests.m b/packages/google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/RunnerTests/ExtractIconFromDataTests.m index e0ca11d8e840..73e9e11575c0 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/RunnerTests/ExtractIconFromDataTests.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/RunnerTests/ExtractIconFromDataTests.m @@ -31,7 +31,8 @@ - (void)testExtractIconFromDataAssetAuto { CGFloat screenScale = 3.0; - UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); + UIImage *resultImage = + FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, 1.0); @@ -57,7 +58,8 @@ - (void)testExtractIconFromDataAssetAutoWithScale { CGFloat screenScale = 3.0; - UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); + UIImage *resultImage = + FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, 10); @@ -85,7 +87,8 @@ - (void)testExtractIconFromDataAssetAutoAndSizeWithSameAspectRatio { CGFloat screenScale = 3.0; - UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); + UIImage *resultImage = + FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(testImage.scale, 1.0); @@ -118,7 +121,8 @@ - (void)testExtractIconFromDataAssetAutoAndSizeWithDifferentAspectRatio { CGFloat screenScale = 3.0; - UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); + UIImage *resultImage = + FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, screenScale); XCTAssertEqual(resultImage.size.width, width); @@ -143,7 +147,8 @@ - (void)testExtractIconFromDataAssetNoScaling { CGFloat screenScale = 3.0; - UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); + UIImage *resultImage = + FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, 1.0); @@ -168,7 +173,8 @@ - (void)testExtractIconFromDataBytesAuto { CGFloat screenScale = 3.0; - UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); + UIImage *resultImage = + FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, 1.0); @@ -193,7 +199,8 @@ - (void)testExtractIconFromDataBytesAutoWithScaling { CGFloat screenScale = 3.0; - UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); + UIImage *resultImage = + FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, 10); XCTAssertEqual(resultImage.size.width, 0.1); @@ -219,7 +226,8 @@ - (void)testExtractIconFromDataBytesAutoAndSizeWithSameAspectRatio { CGFloat screenScale = 3.0; - UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); + UIImage *resultImage = + FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(testImage.scale, 1.0); @@ -252,7 +260,8 @@ - (void)testExtractIconFromDataBytesAutoAndSizeWithDifferentAspectRatio { CGFloat screenScale = 3.0; - UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); + UIImage *resultImage = + FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, screenScale); XCTAssertEqual(resultImage.size.width, width); @@ -276,7 +285,8 @@ - (void)testExtractIconFromDataBytesNoScaling { CGFloat screenScale = 3.0; - UIImage *resultImage = FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); + UIImage *resultImage = + FGMIconFromBitmap([FGMPlatformBitmap makeWithBitmap:bitmap], mockRegistrar, screenScale); XCTAssertNotNil(resultImage); XCTAssertEqual(resultImage.scale, 1.0); XCTAssertEqual(resultImage.size.width, 1.0); diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.m index c787abff4bfb..29d9e2e4c5a0 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMGroundOverlayController.m @@ -149,14 +149,16 @@ - (void)addGroundOverlays:(NSArray *)groundOverlaysT coordinate:CLLocationCoordinate2DMake( groundOverlay.bounds.southwest.latitude, groundOverlay.bounds.southwest.longitude)] - icon:FGMIconFromBitmap(groundOverlay.image, self.registrar, [self getScreenScale])]; + icon:FGMIconFromBitmap(groundOverlay.image, self.registrar, + [self getScreenScale])]; } else { NSAssert(groundOverlay.zoomLevel != nil, @"If ground overlay is initialized with position, zoomLevel is required"); gmsOverlay = [GMSGroundOverlay groundOverlayWithPosition:CLLocationCoordinate2DMake(groundOverlay.position.latitude, groundOverlay.position.longitude) - icon:FGMIconFromBitmap(groundOverlay.image, self.registrar, [self getScreenScale]) + icon:FGMIconFromBitmap(groundOverlay.image, self.registrar, + [self getScreenScale]) zoomLevel:[groundOverlay.zoomLevel doubleValue]]; } FGMGroundOverlayController *controller = diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.h b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.h index 8a031daf5ecb..8aa1bcb67934 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.h +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.h @@ -10,9 +10,9 @@ NS_ASSUME_NONNULL_BEGIN /// Creates a UIImage from Pigeon bitmap. UIImage *FGMIconFromBitmap(FGMPlatformBitmap *platformBitmap, - NSObject *registrar, - CGFloat screenScale); -/// Returns a BOOL indicating whether image is considered scalable with the given scale factor from size. + NSObject *registrar, CGFloat screenScale); +/// Returns a BOOL indicating whether image is considered scalable with the given scale factor from +/// size. BOOL FGMIsScalableWithScaleFactorFromSize(CGSize originalSize, CGSize targetSize); NS_ASSUME_NONNULL_END diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.m index 76a3cb700931..5ad77a94e1ab 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FGMImageUtils.m @@ -5,17 +5,13 @@ #import "FGMImageUtils.h" #import "Foundation/Foundation.h" -static UIImage * scaleImage(UIImage *image, double scale); -static UIImage * scaledImageWithScale(UIImage *image, CGFloat scale); -static UIImage * scaledImageWithSize(UIImage *image, CGSize size); -static UIImage * scaledImage(UIImage *image, - NSNumber *width, - NSNumber *height, - CGFloat screenScale); +static UIImage *scaleImage(UIImage *image, double scale); +static UIImage *scaledImageWithScale(UIImage *image, CGFloat scale); +static UIImage *scaledImageWithSize(UIImage *image, CGSize size); +static UIImage *scaledImage(UIImage *image, NSNumber *width, NSNumber *height, CGFloat screenScale); UIImage *FGMIconFromBitmap(FGMPlatformBitmap *platformBitmap, - NSObject *registrar, - CGFloat screenScale) { + NSObject *registrar, CGFloat screenScale) { assert(screenScale > 0 && "Screen scale must be greater than 0"); // See comment in messages.dart for why this is so loosely typed. See also // https://github.com/flutter/flutter/issues/117819. @@ -106,7 +102,7 @@ /// flutter google_maps_flutter_platform_interface package which has been replaced by 'bytes' /// message handling. It will be removed when the deprecated image bitmap description type /// 'fromBytes' is removed from the platform interface. -UIImage * scaleImage(UIImage *image, double scale) { +UIImage *scaleImage(UIImage *image, double scale) { if (fabs(scale - 1) > 1e-3) { return [UIImage imageWithCGImage:[image CGImage] scale:(image.scale * scale) @@ -123,7 +119,7 @@ /// @param image The UIImage to scale. /// @param scale The factor by which to scale the image. /// @return UIImage Returns the scaled UIImage. -UIImage * scaledImageWithScale(UIImage *image, CGFloat scale) { +UIImage *scaledImageWithScale(UIImage *image, CGFloat scale) { if (fabs(scale - image.scale) > DBL_EPSILON) { return [UIImage imageWithCGImage:[image CGImage] scale:scale @@ -140,7 +136,7 @@ /// @param image The UIImage to scale. /// @param size The target CGSize to scale the image to. /// @return UIImage Returns the scaled UIImage. -UIImage * scaledImageWithSize(UIImage *image, CGSize size) { +UIImage *scaledImageWithSize(UIImage *image, CGSize size) { CGFloat originalPixelWidth = image.size.width * image.scale; CGFloat originalPixelHeight = image.size.height * image.scale; @@ -189,10 +185,7 @@ /// @param height The target height to scale the image to. /// @param screenScale The current screen scale. /// @return UIImage Returns the scaled UIImage. -UIImage * scaledImage(UIImage *image, - NSNumber *width, - NSNumber *height, - CGFloat screenScale) { +UIImage *scaledImage(UIImage *image, NSNumber *width, NSNumber *height, CGFloat screenScale) { if (!width && !height) { return image; } diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FLTGoogleMapJSONConversions.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FLTGoogleMapJSONConversions.m index 2b9ac010a294..8b3a644eec6f 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FLTGoogleMapJSONConversions.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/FLTGoogleMapJSONConversions.m @@ -138,7 +138,7 @@ GMSMapViewType FGMGetMapViewTypeForPigeonMapType(FGMPlatformMapType type) { .southWest .longitude]] anchor:[FGMPlatformPoint makeWithX:groundOverlay.anchor.x - y:groundOverlay.anchor.y] + y:groundOverlay.anchor.y] transparency:1.0f - groundOverlay.opacity bearing:groundOverlay.bearing zIndex:groundOverlay.zIndex @@ -154,7 +154,7 @@ GMSMapViewType FGMGetMapViewTypeForPigeonMapType(FGMPlatformMapType type) { longitude:groundOverlay.position.longitude] bounds:nil anchor:[FGMPlatformPoint makeWithX:groundOverlay.anchor.x - y:groundOverlay.anchor.y] + y:groundOverlay.anchor.y] transparency:1.0f - groundOverlay.opacity bearing:groundOverlay.bearing zIndex:groundOverlay.zIndex diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/GoogleMapMarkerController.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/GoogleMapMarkerController.m index cdb9d3d388f2..a76915d7d20c 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/GoogleMapMarkerController.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/GoogleMapMarkerController.m @@ -4,8 +4,8 @@ #import "GoogleMapMarkerController.h" -#import "FGMMarkerUserData.h" #import "FGMImageUtils.h" +#import "FGMMarkerUserData.h" #import "FLTGoogleMapJSONConversions.h" @interface FLTGoogleMapMarkerController () diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/google_maps_flutter_ios-umbrella.h b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/google_maps_flutter_ios-umbrella.h index 20462b321a3f..af821c5ffdfa 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/google_maps_flutter_ios-umbrella.h +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/google_maps_flutter_ios-umbrella.h @@ -5,8 +5,8 @@ #import #import #import -#import #import +#import #import #import #import diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.h b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.h index c289b6673361..9d7bd9326b98 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.h +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.h @@ -110,26 +110,26 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { @interface FGMPlatformCameraPosition : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithBearing:(double )bearing - target:(FGMPlatformLatLng *)target - tilt:(double )tilt - zoom:(double )zoom; -@property(nonatomic, assign) double bearing; -@property(nonatomic, strong) FGMPlatformLatLng * target; -@property(nonatomic, assign) double tilt; -@property(nonatomic, assign) double zoom; ++ (instancetype)makeWithBearing:(double)bearing + target:(FGMPlatformLatLng *)target + tilt:(double)tilt + zoom:(double)zoom; +@property(nonatomic, assign) double bearing; +@property(nonatomic, strong) FGMPlatformLatLng *target; +@property(nonatomic, assign) double tilt; +@property(nonatomic, assign) double zoom; @end /// Pigeon representation of a CameraUpdate. @interface FGMPlatformCameraUpdate : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithCameraUpdate:(id )cameraUpdate; ++ (instancetype)makeWithCameraUpdate:(id)cameraUpdate; /// This Object must be one of the classes below prefixed with /// PlatformCameraUpdate. Each such class represents a different type of /// camera update, and each holds a different set of data, preventing the /// use of a single unified class. -@property(nonatomic, strong) id cameraUpdate; +@property(nonatomic, strong) id cameraUpdate; @end /// Pigeon equivalent of NewCameraPosition @@ -137,7 +137,7 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithCameraPosition:(FGMPlatformCameraPosition *)cameraPosition; -@property(nonatomic, strong) FGMPlatformCameraPosition * cameraPosition; +@property(nonatomic, strong) FGMPlatformCameraPosition *cameraPosition; @end /// Pigeon equivalent of NewLatLng @@ -145,98 +145,94 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithLatLng:(FGMPlatformLatLng *)latLng; -@property(nonatomic, strong) FGMPlatformLatLng * latLng; +@property(nonatomic, strong) FGMPlatformLatLng *latLng; @end /// Pigeon equivalent of NewLatLngBounds @interface FGMPlatformCameraUpdateNewLatLngBounds : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithBounds:(FGMPlatformLatLngBounds *)bounds - padding:(double )padding; -@property(nonatomic, strong) FGMPlatformLatLngBounds * bounds; -@property(nonatomic, assign) double padding; ++ (instancetype)makeWithBounds:(FGMPlatformLatLngBounds *)bounds padding:(double)padding; +@property(nonatomic, strong) FGMPlatformLatLngBounds *bounds; +@property(nonatomic, assign) double padding; @end /// Pigeon equivalent of NewLatLngZoom @interface FGMPlatformCameraUpdateNewLatLngZoom : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithLatLng:(FGMPlatformLatLng *)latLng - zoom:(double )zoom; -@property(nonatomic, strong) FGMPlatformLatLng * latLng; -@property(nonatomic, assign) double zoom; ++ (instancetype)makeWithLatLng:(FGMPlatformLatLng *)latLng zoom:(double)zoom; +@property(nonatomic, strong) FGMPlatformLatLng *latLng; +@property(nonatomic, assign) double zoom; @end /// Pigeon equivalent of ScrollBy @interface FGMPlatformCameraUpdateScrollBy : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithDx:(double )dx - dy:(double )dy; -@property(nonatomic, assign) double dx; -@property(nonatomic, assign) double dy; ++ (instancetype)makeWithDx:(double)dx dy:(double)dy; +@property(nonatomic, assign) double dx; +@property(nonatomic, assign) double dy; @end /// Pigeon equivalent of ZoomBy @interface FGMPlatformCameraUpdateZoomBy : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithAmount:(double )amount - focus:(nullable FGMPlatformPoint *)focus; -@property(nonatomic, assign) double amount; -@property(nonatomic, strong, nullable) FGMPlatformPoint * focus; ++ (instancetype)makeWithAmount:(double)amount focus:(nullable FGMPlatformPoint *)focus; +@property(nonatomic, assign) double amount; +@property(nonatomic, strong, nullable) FGMPlatformPoint *focus; @end /// Pigeon equivalent of ZoomIn/ZoomOut @interface FGMPlatformCameraUpdateZoom : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithOut:(BOOL )out; -@property(nonatomic, assign) BOOL out; ++ (instancetype)makeWithOut:(BOOL)out; +@property(nonatomic, assign) BOOL out; @end /// Pigeon equivalent of ZoomTo @interface FGMPlatformCameraUpdateZoomTo : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithZoom:(double )zoom; -@property(nonatomic, assign) double zoom; ++ (instancetype)makeWithZoom:(double)zoom; +@property(nonatomic, assign) double zoom; @end /// Pigeon equivalent of the Circle class. @interface FGMPlatformCircle : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithConsumeTapEvents:(BOOL )consumeTapEvents - fillColor:(NSInteger )fillColor - strokeColor:(NSInteger )strokeColor - visible:(BOOL )visible - strokeWidth:(NSInteger )strokeWidth - zIndex:(double )zIndex - center:(FGMPlatformLatLng *)center - radius:(double )radius - circleId:(NSString *)circleId; -@property(nonatomic, assign) BOOL consumeTapEvents; -@property(nonatomic, assign) NSInteger fillColor; -@property(nonatomic, assign) NSInteger strokeColor; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) NSInteger strokeWidth; -@property(nonatomic, assign) double zIndex; -@property(nonatomic, strong) FGMPlatformLatLng * center; -@property(nonatomic, assign) double radius; -@property(nonatomic, copy) NSString * circleId; ++ (instancetype)makeWithConsumeTapEvents:(BOOL)consumeTapEvents + fillColor:(NSInteger)fillColor + strokeColor:(NSInteger)strokeColor + visible:(BOOL)visible + strokeWidth:(NSInteger)strokeWidth + zIndex:(double)zIndex + center:(FGMPlatformLatLng *)center + radius:(double)radius + circleId:(NSString *)circleId; +@property(nonatomic, assign) BOOL consumeTapEvents; +@property(nonatomic, assign) NSInteger fillColor; +@property(nonatomic, assign) NSInteger strokeColor; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) NSInteger strokeWidth; +@property(nonatomic, assign) double zIndex; +@property(nonatomic, strong) FGMPlatformLatLng *center; +@property(nonatomic, assign) double radius; +@property(nonatomic, copy) NSString *circleId; @end /// Pigeon equivalent of the Heatmap class. @interface FGMPlatformHeatmap : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithJson:(id )json; ++ (instancetype)makeWithJson:(id)json; /// The heatmap data, as JSON. This should only be set from /// Heatmap.toJson, and the native code must interpret it according to the /// internal implementation details of that method. -@property(nonatomic, strong) id json; +@property(nonatomic, strong) id json; @end /// Pigeon equivalent of the InfoWindow class. @@ -244,11 +240,11 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithTitle:(nullable NSString *)title - snippet:(nullable NSString *)snippet - anchor:(FGMPlatformPoint *)anchor; -@property(nonatomic, copy, nullable) NSString * title; -@property(nonatomic, copy, nullable) NSString * snippet; -@property(nonatomic, strong) FGMPlatformPoint * anchor; + snippet:(nullable NSString *)snippet + anchor:(FGMPlatformPoint *)anchor; +@property(nonatomic, copy, nullable) NSString *title; +@property(nonatomic, copy, nullable) NSString *snippet; +@property(nonatomic, strong) FGMPlatformPoint *anchor; @end /// Pigeon equivalent of Cluster. @@ -256,13 +252,13 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithClusterManagerId:(NSString *)clusterManagerId - position:(FGMPlatformLatLng *)position - bounds:(FGMPlatformLatLngBounds *)bounds - markerIds:(NSArray *)markerIds; -@property(nonatomic, copy) NSString * clusterManagerId; -@property(nonatomic, strong) FGMPlatformLatLng * position; -@property(nonatomic, strong) FGMPlatformLatLngBounds * bounds; -@property(nonatomic, copy) NSArray * markerIds; + position:(FGMPlatformLatLng *)position + bounds:(FGMPlatformLatLngBounds *)bounds + markerIds:(NSArray *)markerIds; +@property(nonatomic, copy) NSString *clusterManagerId; +@property(nonatomic, strong) FGMPlatformLatLng *position; +@property(nonatomic, strong) FGMPlatformLatLngBounds *bounds; +@property(nonatomic, copy) NSArray *markerIds; @end /// Pigeon equivalent of the ClusterManager class. @@ -270,39 +266,39 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithIdentifier:(NSString *)identifier; -@property(nonatomic, copy) NSString * identifier; +@property(nonatomic, copy) NSString *identifier; @end /// Pigeon equivalent of the Marker class. @interface FGMPlatformMarker : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithAlpha:(double )alpha - anchor:(FGMPlatformPoint *)anchor - consumeTapEvents:(BOOL )consumeTapEvents - draggable:(BOOL )draggable - flat:(BOOL )flat - icon:(FGMPlatformBitmap *)icon - infoWindow:(FGMPlatformInfoWindow *)infoWindow - position:(FGMPlatformLatLng *)position - rotation:(double )rotation - visible:(BOOL )visible - zIndex:(double )zIndex - markerId:(NSString *)markerId - clusterManagerId:(nullable NSString *)clusterManagerId; -@property(nonatomic, assign) double alpha; -@property(nonatomic, strong) FGMPlatformPoint * anchor; -@property(nonatomic, assign) BOOL consumeTapEvents; -@property(nonatomic, assign) BOOL draggable; -@property(nonatomic, assign) BOOL flat; -@property(nonatomic, strong) FGMPlatformBitmap * icon; -@property(nonatomic, strong) FGMPlatformInfoWindow * infoWindow; -@property(nonatomic, strong) FGMPlatformLatLng * position; -@property(nonatomic, assign) double rotation; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) double zIndex; -@property(nonatomic, copy) NSString * markerId; -@property(nonatomic, copy, nullable) NSString * clusterManagerId; ++ (instancetype)makeWithAlpha:(double)alpha + anchor:(FGMPlatformPoint *)anchor + consumeTapEvents:(BOOL)consumeTapEvents + draggable:(BOOL)draggable + flat:(BOOL)flat + icon:(FGMPlatformBitmap *)icon + infoWindow:(FGMPlatformInfoWindow *)infoWindow + position:(FGMPlatformLatLng *)position + rotation:(double)rotation + visible:(BOOL)visible + zIndex:(double)zIndex + markerId:(NSString *)markerId + clusterManagerId:(nullable NSString *)clusterManagerId; +@property(nonatomic, assign) double alpha; +@property(nonatomic, strong) FGMPlatformPoint *anchor; +@property(nonatomic, assign) BOOL consumeTapEvents; +@property(nonatomic, assign) BOOL draggable; +@property(nonatomic, assign) BOOL flat; +@property(nonatomic, strong) FGMPlatformBitmap *icon; +@property(nonatomic, strong) FGMPlatformInfoWindow *infoWindow; +@property(nonatomic, strong) FGMPlatformLatLng *position; +@property(nonatomic, assign) double rotation; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) double zIndex; +@property(nonatomic, copy) NSString *markerId; +@property(nonatomic, copy, nullable) NSString *clusterManagerId; @end /// Pigeon equivalent of the Polygon class. @@ -310,25 +306,25 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithPolygonId:(NSString *)polygonId - consumesTapEvents:(BOOL )consumesTapEvents - fillColor:(NSInteger )fillColor - geodesic:(BOOL )geodesic - points:(NSArray *)points - holes:(NSArray *> *)holes - visible:(BOOL )visible - strokeColor:(NSInteger )strokeColor - strokeWidth:(NSInteger )strokeWidth - zIndex:(NSInteger )zIndex; -@property(nonatomic, copy) NSString * polygonId; -@property(nonatomic, assign) BOOL consumesTapEvents; -@property(nonatomic, assign) NSInteger fillColor; -@property(nonatomic, assign) BOOL geodesic; -@property(nonatomic, copy) NSArray * points; -@property(nonatomic, copy) NSArray *> * holes; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) NSInteger strokeColor; -@property(nonatomic, assign) NSInteger strokeWidth; -@property(nonatomic, assign) NSInteger zIndex; + consumesTapEvents:(BOOL)consumesTapEvents + fillColor:(NSInteger)fillColor + geodesic:(BOOL)geodesic + points:(NSArray *)points + holes:(NSArray *> *)holes + visible:(BOOL)visible + strokeColor:(NSInteger)strokeColor + strokeWidth:(NSInteger)strokeWidth + zIndex:(NSInteger)zIndex; +@property(nonatomic, copy) NSString *polygonId; +@property(nonatomic, assign) BOOL consumesTapEvents; +@property(nonatomic, assign) NSInteger fillColor; +@property(nonatomic, assign) BOOL geodesic; +@property(nonatomic, copy) NSArray *points; +@property(nonatomic, copy) NSArray *> *holes; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) NSInteger strokeColor; +@property(nonatomic, assign) NSInteger strokeWidth; +@property(nonatomic, assign) NSInteger zIndex; @end /// Pigeon equivalent of the Polyline class. @@ -336,49 +332,48 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithPolylineId:(NSString *)polylineId - consumesTapEvents:(BOOL )consumesTapEvents - color:(NSInteger )color - geodesic:(BOOL )geodesic - jointType:(FGMPlatformJointType)jointType - patterns:(NSArray *)patterns - points:(NSArray *)points - visible:(BOOL )visible - width:(NSInteger )width - zIndex:(NSInteger )zIndex; -@property(nonatomic, copy) NSString * polylineId; -@property(nonatomic, assign) BOOL consumesTapEvents; -@property(nonatomic, assign) NSInteger color; -@property(nonatomic, assign) BOOL geodesic; + consumesTapEvents:(BOOL)consumesTapEvents + color:(NSInteger)color + geodesic:(BOOL)geodesic + jointType:(FGMPlatformJointType)jointType + patterns:(NSArray *)patterns + points:(NSArray *)points + visible:(BOOL)visible + width:(NSInteger)width + zIndex:(NSInteger)zIndex; +@property(nonatomic, copy) NSString *polylineId; +@property(nonatomic, assign) BOOL consumesTapEvents; +@property(nonatomic, assign) NSInteger color; +@property(nonatomic, assign) BOOL geodesic; /// The joint type. @property(nonatomic, assign) FGMPlatformJointType jointType; /// The pattern data, as a list of pattern items. -@property(nonatomic, copy) NSArray * patterns; -@property(nonatomic, copy) NSArray * points; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) NSInteger width; -@property(nonatomic, assign) NSInteger zIndex; +@property(nonatomic, copy) NSArray *patterns; +@property(nonatomic, copy) NSArray *points; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) NSInteger width; +@property(nonatomic, assign) NSInteger zIndex; @end /// Pigeon equivalent of the PatternItem class. @interface FGMPlatformPatternItem : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithType:(FGMPlatformPatternItemType)type - length:(nullable NSNumber *)length; ++ (instancetype)makeWithType:(FGMPlatformPatternItemType)type length:(nullable NSNumber *)length; @property(nonatomic, assign) FGMPlatformPatternItemType type; -@property(nonatomic, strong, nullable) NSNumber * length; +@property(nonatomic, strong, nullable) NSNumber *length; @end /// Pigeon equivalent of the Tile class. @interface FGMPlatformTile : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithWidth:(NSInteger )width - height:(NSInteger )height - data:(nullable FlutterStandardTypedData *)data; -@property(nonatomic, assign) NSInteger width; -@property(nonatomic, assign) NSInteger height; -@property(nonatomic, strong, nullable) FlutterStandardTypedData * data; ++ (instancetype)makeWithWidth:(NSInteger)width + height:(NSInteger)height + data:(nullable FlutterStandardTypedData *)data; +@property(nonatomic, assign) NSInteger width; +@property(nonatomic, assign) NSInteger height; +@property(nonatomic, strong, nullable) FlutterStandardTypedData *data; @end /// Pigeon equivalent of the TileOverlay class. @@ -386,41 +381,37 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithTileOverlayId:(NSString *)tileOverlayId - fadeIn:(BOOL )fadeIn - transparency:(double )transparency - zIndex:(NSInteger )zIndex - visible:(BOOL )visible - tileSize:(NSInteger )tileSize; -@property(nonatomic, copy) NSString * tileOverlayId; -@property(nonatomic, assign) BOOL fadeIn; -@property(nonatomic, assign) double transparency; -@property(nonatomic, assign) NSInteger zIndex; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) NSInteger tileSize; + fadeIn:(BOOL)fadeIn + transparency:(double)transparency + zIndex:(NSInteger)zIndex + visible:(BOOL)visible + tileSize:(NSInteger)tileSize; +@property(nonatomic, copy) NSString *tileOverlayId; +@property(nonatomic, assign) BOOL fadeIn; +@property(nonatomic, assign) double transparency; +@property(nonatomic, assign) NSInteger zIndex; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) NSInteger tileSize; @end /// Pigeon equivalent of Flutter's EdgeInsets. @interface FGMPlatformEdgeInsets : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithTop:(double )top - bottom:(double )bottom - left:(double )left - right:(double )right; -@property(nonatomic, assign) double top; -@property(nonatomic, assign) double bottom; -@property(nonatomic, assign) double left; -@property(nonatomic, assign) double right; ++ (instancetype)makeWithTop:(double)top bottom:(double)bottom left:(double)left right:(double)right; +@property(nonatomic, assign) double top; +@property(nonatomic, assign) double bottom; +@property(nonatomic, assign) double left; +@property(nonatomic, assign) double right; @end /// Pigeon equivalent of LatLng. @interface FGMPlatformLatLng : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithLatitude:(double )latitude - longitude:(double )longitude; -@property(nonatomic, assign) double latitude; -@property(nonatomic, assign) double longitude; ++ (instancetype)makeWithLatitude:(double)latitude longitude:(double)longitude; +@property(nonatomic, assign) double latitude; +@property(nonatomic, assign) double longitude; @end /// Pigeon equivalent of LatLngBounds. @@ -428,9 +419,9 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithNortheast:(FGMPlatformLatLng *)northeast - southwest:(FGMPlatformLatLng *)southwest; -@property(nonatomic, strong) FGMPlatformLatLng * northeast; -@property(nonatomic, strong) FGMPlatformLatLng * southwest; + southwest:(FGMPlatformLatLng *)southwest; +@property(nonatomic, strong) FGMPlatformLatLng *northeast; +@property(nonatomic, strong) FGMPlatformLatLng *southwest; @end /// Pigeon equivalent of CameraTargetBounds. @@ -439,7 +430,7 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// a target, and having an explicitly unbounded target (null [bounds]). @interface FGMPlatformCameraTargetBounds : NSObject + (instancetype)makeWithBounds:(nullable FGMPlatformLatLngBounds *)bounds; -@property(nonatomic, strong, nullable) FGMPlatformLatLngBounds * bounds; +@property(nonatomic, strong, nullable) FGMPlatformLatLngBounds *bounds; @end /// Pigeon equivalent of the GroundOverlay class. @@ -447,133 +438,131 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithGroundOverlayId:(NSString *)groundOverlayId - image:(FGMPlatformBitmap *)image - position:(nullable FGMPlatformLatLng *)position - bounds:(nullable FGMPlatformLatLngBounds *)bounds - anchor:(nullable FGMPlatformPoint *)anchor - transparency:(double )transparency - bearing:(double )bearing - zIndex:(double )zIndex - visible:(BOOL )visible - clickable:(BOOL )clickable - zoomLevel:(nullable NSNumber *)zoomLevel; -@property(nonatomic, copy) NSString * groundOverlayId; -@property(nonatomic, strong) FGMPlatformBitmap * image; -@property(nonatomic, strong, nullable) FGMPlatformLatLng * position; -@property(nonatomic, strong, nullable) FGMPlatformLatLngBounds * bounds; -@property(nonatomic, strong, nullable) FGMPlatformPoint * anchor; -@property(nonatomic, assign) double transparency; -@property(nonatomic, assign) double bearing; -@property(nonatomic, assign) double zIndex; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) BOOL clickable; -@property(nonatomic, strong, nullable) NSNumber * zoomLevel; + image:(FGMPlatformBitmap *)image + position:(nullable FGMPlatformLatLng *)position + bounds:(nullable FGMPlatformLatLngBounds *)bounds + anchor:(nullable FGMPlatformPoint *)anchor + transparency:(double)transparency + bearing:(double)bearing + zIndex:(double)zIndex + visible:(BOOL)visible + clickable:(BOOL)clickable + zoomLevel:(nullable NSNumber *)zoomLevel; +@property(nonatomic, copy) NSString *groundOverlayId; +@property(nonatomic, strong) FGMPlatformBitmap *image; +@property(nonatomic, strong, nullable) FGMPlatformLatLng *position; +@property(nonatomic, strong, nullable) FGMPlatformLatLngBounds *bounds; +@property(nonatomic, strong, nullable) FGMPlatformPoint *anchor; +@property(nonatomic, assign) double transparency; +@property(nonatomic, assign) double bearing; +@property(nonatomic, assign) double zIndex; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) BOOL clickable; +@property(nonatomic, strong, nullable) NSNumber *zoomLevel; @end /// Information passed to the platform view creation. @interface FGMPlatformMapViewCreationParams : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithInitialCameraPosition:(FGMPlatformCameraPosition *)initialCameraPosition - mapConfiguration:(FGMPlatformMapConfiguration *)mapConfiguration - initialCircles:(NSArray *)initialCircles - initialMarkers:(NSArray *)initialMarkers - initialPolygons:(NSArray *)initialPolygons - initialPolylines:(NSArray *)initialPolylines - initialHeatmaps:(NSArray *)initialHeatmaps - initialTileOverlays:(NSArray *)initialTileOverlays - initialClusterManagers:(NSArray *)initialClusterManagers - initialGroundOverlays:(NSArray *)initialGroundOverlays; -@property(nonatomic, strong) FGMPlatformCameraPosition * initialCameraPosition; -@property(nonatomic, strong) FGMPlatformMapConfiguration * mapConfiguration; -@property(nonatomic, copy) NSArray * initialCircles; -@property(nonatomic, copy) NSArray * initialMarkers; -@property(nonatomic, copy) NSArray * initialPolygons; -@property(nonatomic, copy) NSArray * initialPolylines; -@property(nonatomic, copy) NSArray * initialHeatmaps; -@property(nonatomic, copy) NSArray * initialTileOverlays; -@property(nonatomic, copy) NSArray * initialClusterManagers; -@property(nonatomic, copy) NSArray * initialGroundOverlays; ++ (instancetype) + makeWithInitialCameraPosition:(FGMPlatformCameraPosition *)initialCameraPosition + mapConfiguration:(FGMPlatformMapConfiguration *)mapConfiguration + initialCircles:(NSArray *)initialCircles + initialMarkers:(NSArray *)initialMarkers + initialPolygons:(NSArray *)initialPolygons + initialPolylines:(NSArray *)initialPolylines + initialHeatmaps:(NSArray *)initialHeatmaps + initialTileOverlays:(NSArray *)initialTileOverlays + initialClusterManagers:(NSArray *)initialClusterManagers + initialGroundOverlays:(NSArray *)initialGroundOverlays; +@property(nonatomic, strong) FGMPlatformCameraPosition *initialCameraPosition; +@property(nonatomic, strong) FGMPlatformMapConfiguration *mapConfiguration; +@property(nonatomic, copy) NSArray *initialCircles; +@property(nonatomic, copy) NSArray *initialMarkers; +@property(nonatomic, copy) NSArray *initialPolygons; +@property(nonatomic, copy) NSArray *initialPolylines; +@property(nonatomic, copy) NSArray *initialHeatmaps; +@property(nonatomic, copy) NSArray *initialTileOverlays; +@property(nonatomic, copy) NSArray *initialClusterManagers; +@property(nonatomic, copy) NSArray *initialGroundOverlays; @end /// Pigeon equivalent of MapConfiguration. @interface FGMPlatformMapConfiguration : NSObject + (instancetype)makeWithCompassEnabled:(nullable NSNumber *)compassEnabled - cameraTargetBounds:(nullable FGMPlatformCameraTargetBounds *)cameraTargetBounds - mapType:(nullable FGMPlatformMapTypeBox *)mapType - minMaxZoomPreference:(nullable FGMPlatformZoomRange *)minMaxZoomPreference - rotateGesturesEnabled:(nullable NSNumber *)rotateGesturesEnabled - scrollGesturesEnabled:(nullable NSNumber *)scrollGesturesEnabled - tiltGesturesEnabled:(nullable NSNumber *)tiltGesturesEnabled - trackCameraPosition:(nullable NSNumber *)trackCameraPosition - zoomGesturesEnabled:(nullable NSNumber *)zoomGesturesEnabled - myLocationEnabled:(nullable NSNumber *)myLocationEnabled - myLocationButtonEnabled:(nullable NSNumber *)myLocationButtonEnabled - padding:(nullable FGMPlatformEdgeInsets *)padding - indoorViewEnabled:(nullable NSNumber *)indoorViewEnabled - trafficEnabled:(nullable NSNumber *)trafficEnabled - buildingsEnabled:(nullable NSNumber *)buildingsEnabled - cloudMapId:(nullable NSString *)cloudMapId - style:(nullable NSString *)style; -@property(nonatomic, strong, nullable) NSNumber * compassEnabled; -@property(nonatomic, strong, nullable) FGMPlatformCameraTargetBounds * cameraTargetBounds; -@property(nonatomic, strong, nullable) FGMPlatformMapTypeBox * mapType; -@property(nonatomic, strong, nullable) FGMPlatformZoomRange * minMaxZoomPreference; -@property(nonatomic, strong, nullable) NSNumber * rotateGesturesEnabled; -@property(nonatomic, strong, nullable) NSNumber * scrollGesturesEnabled; -@property(nonatomic, strong, nullable) NSNumber * tiltGesturesEnabled; -@property(nonatomic, strong, nullable) NSNumber * trackCameraPosition; -@property(nonatomic, strong, nullable) NSNumber * zoomGesturesEnabled; -@property(nonatomic, strong, nullable) NSNumber * myLocationEnabled; -@property(nonatomic, strong, nullable) NSNumber * myLocationButtonEnabled; -@property(nonatomic, strong, nullable) FGMPlatformEdgeInsets * padding; -@property(nonatomic, strong, nullable) NSNumber * indoorViewEnabled; -@property(nonatomic, strong, nullable) NSNumber * trafficEnabled; -@property(nonatomic, strong, nullable) NSNumber * buildingsEnabled; -@property(nonatomic, copy, nullable) NSString * cloudMapId; -@property(nonatomic, copy, nullable) NSString * style; + cameraTargetBounds:(nullable FGMPlatformCameraTargetBounds *)cameraTargetBounds + mapType:(nullable FGMPlatformMapTypeBox *)mapType + minMaxZoomPreference:(nullable FGMPlatformZoomRange *)minMaxZoomPreference + rotateGesturesEnabled:(nullable NSNumber *)rotateGesturesEnabled + scrollGesturesEnabled:(nullable NSNumber *)scrollGesturesEnabled + tiltGesturesEnabled:(nullable NSNumber *)tiltGesturesEnabled + trackCameraPosition:(nullable NSNumber *)trackCameraPosition + zoomGesturesEnabled:(nullable NSNumber *)zoomGesturesEnabled + myLocationEnabled:(nullable NSNumber *)myLocationEnabled + myLocationButtonEnabled:(nullable NSNumber *)myLocationButtonEnabled + padding:(nullable FGMPlatformEdgeInsets *)padding + indoorViewEnabled:(nullable NSNumber *)indoorViewEnabled + trafficEnabled:(nullable NSNumber *)trafficEnabled + buildingsEnabled:(nullable NSNumber *)buildingsEnabled + cloudMapId:(nullable NSString *)cloudMapId + style:(nullable NSString *)style; +@property(nonatomic, strong, nullable) NSNumber *compassEnabled; +@property(nonatomic, strong, nullable) FGMPlatformCameraTargetBounds *cameraTargetBounds; +@property(nonatomic, strong, nullable) FGMPlatformMapTypeBox *mapType; +@property(nonatomic, strong, nullable) FGMPlatformZoomRange *minMaxZoomPreference; +@property(nonatomic, strong, nullable) NSNumber *rotateGesturesEnabled; +@property(nonatomic, strong, nullable) NSNumber *scrollGesturesEnabled; +@property(nonatomic, strong, nullable) NSNumber *tiltGesturesEnabled; +@property(nonatomic, strong, nullable) NSNumber *trackCameraPosition; +@property(nonatomic, strong, nullable) NSNumber *zoomGesturesEnabled; +@property(nonatomic, strong, nullable) NSNumber *myLocationEnabled; +@property(nonatomic, strong, nullable) NSNumber *myLocationButtonEnabled; +@property(nonatomic, strong, nullable) FGMPlatformEdgeInsets *padding; +@property(nonatomic, strong, nullable) NSNumber *indoorViewEnabled; +@property(nonatomic, strong, nullable) NSNumber *trafficEnabled; +@property(nonatomic, strong, nullable) NSNumber *buildingsEnabled; +@property(nonatomic, copy, nullable) NSString *cloudMapId; +@property(nonatomic, copy, nullable) NSString *style; @end /// Pigeon representation of an x,y coordinate. @interface FGMPlatformPoint : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithX:(double )x - y:(double )y; -@property(nonatomic, assign) double x; -@property(nonatomic, assign) double y; ++ (instancetype)makeWithX:(double)x y:(double)y; +@property(nonatomic, assign) double x; +@property(nonatomic, assign) double y; @end /// Pigeon representation of a size. @interface FGMPlatformSize : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithWidth:(double )width - height:(double )height; -@property(nonatomic, assign) double width; -@property(nonatomic, assign) double height; ++ (instancetype)makeWithWidth:(double)width height:(double)height; +@property(nonatomic, assign) double width; +@property(nonatomic, assign) double height; @end /// Pigeon equivalent of GMSTileLayer properties. @interface FGMPlatformTileLayer : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithVisible:(BOOL )visible - fadeIn:(BOOL )fadeIn - opacity:(double )opacity - zIndex:(NSInteger )zIndex; -@property(nonatomic, assign) BOOL visible; -@property(nonatomic, assign) BOOL fadeIn; -@property(nonatomic, assign) double opacity; -@property(nonatomic, assign) NSInteger zIndex; ++ (instancetype)makeWithVisible:(BOOL)visible + fadeIn:(BOOL)fadeIn + opacity:(double)opacity + zIndex:(NSInteger)zIndex; +@property(nonatomic, assign) BOOL visible; +@property(nonatomic, assign) BOOL fadeIn; +@property(nonatomic, assign) double opacity; +@property(nonatomic, assign) NSInteger zIndex; @end /// Pigeon equivalent of MinMaxZoomPreference. @interface FGMPlatformZoomRange : NSObject -+ (instancetype)makeWithMin:(nullable NSNumber *)min - max:(nullable NSNumber *)max; -@property(nonatomic, strong, nullable) NSNumber * min; -@property(nonatomic, strong, nullable) NSNumber * max; ++ (instancetype)makeWithMin:(nullable NSNumber *)min max:(nullable NSNumber *)max; +@property(nonatomic, strong, nullable) NSNumber *min; +@property(nonatomic, strong, nullable) NSNumber *max; @end /// Pigeon equivalent of [BitmapDescriptor]. As there are multiple disjoint @@ -582,7 +571,7 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { @interface FGMPlatformBitmap : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithBitmap:(id )bitmap; ++ (instancetype)makeWithBitmap:(id)bitmap; /// One of [PlatformBitmapAssetMap], [PlatformBitmapAsset], /// [PlatformBitmapAssetImage], [PlatformBitmapBytesMap], /// [PlatformBitmapBytes], or [PlatformBitmapDefaultMarker]. @@ -590,13 +579,13 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// approach allows for the different bitmap implementations to be valid /// argument and return types of the API methods. See /// https://github.com/flutter/flutter/issues/117819. -@property(nonatomic, strong) id bitmap; +@property(nonatomic, strong) id bitmap; @end /// Pigeon equivalent of [DefaultMarker]. @interface FGMPlatformBitmapDefaultMarker : NSObject + (instancetype)makeWithHue:(nullable NSNumber *)hue; -@property(nonatomic, strong, nullable) NSNumber * hue; +@property(nonatomic, strong, nullable) NSNumber *hue; @end /// Pigeon equivalent of [BytesBitmap]. @@ -604,19 +593,18 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithByteData:(FlutterStandardTypedData *)byteData - size:(nullable FGMPlatformSize *)size; -@property(nonatomic, strong) FlutterStandardTypedData * byteData; -@property(nonatomic, strong, nullable) FGMPlatformSize * size; + size:(nullable FGMPlatformSize *)size; +@property(nonatomic, strong) FlutterStandardTypedData *byteData; +@property(nonatomic, strong, nullable) FGMPlatformSize *size; @end /// Pigeon equivalent of [AssetBitmap]. @interface FGMPlatformBitmapAsset : NSObject /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; -+ (instancetype)makeWithName:(NSString *)name - pkg:(nullable NSString *)pkg; -@property(nonatomic, copy) NSString * name; -@property(nonatomic, copy, nullable) NSString * pkg; ++ (instancetype)makeWithName:(NSString *)name pkg:(nullable NSString *)pkg; +@property(nonatomic, copy) NSString *name; +@property(nonatomic, copy, nullable) NSString *pkg; @end /// Pigeon equivalent of [AssetImageBitmap]. @@ -624,11 +612,11 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithName:(NSString *)name - scale:(double )scale - size:(nullable FGMPlatformSize *)size; -@property(nonatomic, copy) NSString * name; -@property(nonatomic, assign) double scale; -@property(nonatomic, strong, nullable) FGMPlatformSize * size; + scale:(double)scale + size:(nullable FGMPlatformSize *)size; +@property(nonatomic, copy) NSString *name; +@property(nonatomic, assign) double scale; +@property(nonatomic, strong, nullable) FGMPlatformSize *size; @end /// Pigeon equivalent of [AssetMapBitmap]. @@ -636,15 +624,15 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithAssetName:(NSString *)assetName - bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling - imagePixelRatio:(double )imagePixelRatio - width:(nullable NSNumber *)width - height:(nullable NSNumber *)height; -@property(nonatomic, copy) NSString * assetName; + bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling + imagePixelRatio:(double)imagePixelRatio + width:(nullable NSNumber *)width + height:(nullable NSNumber *)height; +@property(nonatomic, copy) NSString *assetName; @property(nonatomic, assign) FGMPlatformMapBitmapScaling bitmapScaling; -@property(nonatomic, assign) double imagePixelRatio; -@property(nonatomic, strong, nullable) NSNumber * width; -@property(nonatomic, strong, nullable) NSNumber * height; +@property(nonatomic, assign) double imagePixelRatio; +@property(nonatomic, strong, nullable) NSNumber *width; +@property(nonatomic, strong, nullable) NSNumber *height; @end /// Pigeon equivalent of [BytesMapBitmap]. @@ -652,15 +640,15 @@ typedef NS_ENUM(NSUInteger, FGMPlatformMapBitmapScaling) { /// `init` unavailable to enforce nonnull fields, see the `make` class method. - (instancetype)init NS_UNAVAILABLE; + (instancetype)makeWithByteData:(FlutterStandardTypedData *)byteData - bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling - imagePixelRatio:(double )imagePixelRatio - width:(nullable NSNumber *)width - height:(nullable NSNumber *)height; -@property(nonatomic, strong) FlutterStandardTypedData * byteData; + bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling + imagePixelRatio:(double)imagePixelRatio + width:(nullable NSNumber *)width + height:(nullable NSNumber *)height; +@property(nonatomic, strong) FlutterStandardTypedData *byteData; @property(nonatomic, assign) FGMPlatformMapBitmapScaling bitmapScaling; -@property(nonatomic, assign) double imagePixelRatio; -@property(nonatomic, strong, nullable) NSNumber * width; -@property(nonatomic, strong, nullable) NSNumber * height; +@property(nonatomic, assign) double imagePixelRatio; +@property(nonatomic, strong, nullable) NSNumber *width; +@property(nonatomic, strong, nullable) NSNumber *height; @end /// The codec used by all APIs. @@ -676,53 +664,85 @@ NSObject *FGMGetMessagesCodec(void); /// /// Only non-null configuration values will result in updates; options with /// null values will remain unchanged. -- (void)updateWithMapConfiguration:(FGMPlatformMapConfiguration *)configuration error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateWithMapConfiguration:(FGMPlatformMapConfiguration *)configuration + error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of circles on the map. -- (void)updateCirclesByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateCirclesByAdding:(NSArray *)toAdd + changing:(NSArray *)toChange + removing:(NSArray *)idsToRemove + error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of heatmaps on the map. -- (void)updateHeatmapsByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateHeatmapsByAdding:(NSArray *)toAdd + changing:(NSArray *)toChange + removing:(NSArray *)idsToRemove + error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of custer managers for clusters on the map. -- (void)updateClusterManagersByAdding:(NSArray *)toAdd removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateClusterManagersByAdding:(NSArray *)toAdd + removing:(NSArray *)idsToRemove + error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of markers on the map. -- (void)updateMarkersByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateMarkersByAdding:(NSArray *)toAdd + changing:(NSArray *)toChange + removing:(NSArray *)idsToRemove + error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of polygonss on the map. -- (void)updatePolygonsByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updatePolygonsByAdding:(NSArray *)toAdd + changing:(NSArray *)toChange + removing:(NSArray *)idsToRemove + error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of polylines on the map. -- (void)updatePolylinesByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updatePolylinesByAdding:(NSArray *)toAdd + changing:(NSArray *)toChange + removing:(NSArray *)idsToRemove + error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of tile overlays on the map. -- (void)updateTileOverlaysByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateTileOverlaysByAdding:(NSArray *)toAdd + changing:(NSArray *)toChange + removing:(NSArray *)idsToRemove + error:(FlutterError *_Nullable *_Nonnull)error; /// Updates the set of ground overlays on the map. -- (void)updateGroundOverlaysByAdding:(NSArray *)toAdd changing:(NSArray *)toChange removing:(NSArray *)idsToRemove error:(FlutterError *_Nullable *_Nonnull)error; +- (void)updateGroundOverlaysByAdding:(NSArray *)toAdd + changing:(NSArray *)toChange + removing:(NSArray *)idsToRemove + error:(FlutterError *_Nullable *_Nonnull)error; /// Gets the screen coordinate for the given map location. /// /// @return `nil` only when `error != nil`. -- (nullable FGMPlatformPoint *)screenCoordinatesForLatLng:(FGMPlatformLatLng *)latLng error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable FGMPlatformPoint *)screenCoordinatesForLatLng:(FGMPlatformLatLng *)latLng + error:(FlutterError *_Nullable *_Nonnull)error; /// Gets the map location for the given screen coordinate. /// /// @return `nil` only when `error != nil`. -- (nullable FGMPlatformLatLng *)latLngForScreenCoordinate:(FGMPlatformPoint *)screenCoordinate error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable FGMPlatformLatLng *)latLngForScreenCoordinate:(FGMPlatformPoint *)screenCoordinate + error:(FlutterError *_Nullable *_Nonnull)error; /// Gets the map region currently displayed on the map. /// /// @return `nil` only when `error != nil`. - (nullable FGMPlatformLatLngBounds *)visibleMapRegion:(FlutterError *_Nullable *_Nonnull)error; /// Moves the camera according to [cameraUpdate] immediately, with no /// animation. -- (void)moveCameraWithUpdate:(FGMPlatformCameraUpdate *)cameraUpdate error:(FlutterError *_Nullable *_Nonnull)error; +- (void)moveCameraWithUpdate:(FGMPlatformCameraUpdate *)cameraUpdate + error:(FlutterError *_Nullable *_Nonnull)error; /// Moves the camera according to [cameraUpdate], animating the update. -- (void)animateCameraWithUpdate:(FGMPlatformCameraUpdate *)cameraUpdate error:(FlutterError *_Nullable *_Nonnull)error; +- (void)animateCameraWithUpdate:(FGMPlatformCameraUpdate *)cameraUpdate + error:(FlutterError *_Nullable *_Nonnull)error; /// Gets the current map zoom level. /// /// @return `nil` only when `error != nil`. - (nullable NSNumber *)currentZoomLevel:(FlutterError *_Nullable *_Nonnull)error; /// Show the info window for the marker with the given ID. -- (void)showInfoWindowForMarkerWithIdentifier:(NSString *)markerId error:(FlutterError *_Nullable *_Nonnull)error; +- (void)showInfoWindowForMarkerWithIdentifier:(NSString *)markerId + error:(FlutterError *_Nullable *_Nonnull)error; /// Hide the info window for the marker with the given ID. -- (void)hideInfoWindowForMarkerWithIdentifier:(NSString *)markerId error:(FlutterError *_Nullable *_Nonnull)error; +- (void)hideInfoWindowForMarkerWithIdentifier:(NSString *)markerId + error:(FlutterError *_Nullable *_Nonnull)error; /// Returns true if the marker with the given ID is currently displaying its /// info window. /// /// @return `nil` only when `error != nil`. -- (nullable NSNumber *)isShowingInfoWindowForMarkerWithIdentifier:(NSString *)markerId error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable NSNumber *) + isShowingInfoWindowForMarkerWithIdentifier:(NSString *)markerId + error:(FlutterError *_Nullable *_Nonnull)error; /// Sets the style to the given map style string, where an empty string /// indicates that the style should be cleared. /// @@ -736,66 +756,93 @@ NSObject *FGMGetMessagesCodec(void); /// is no way to return failures from map initialization. - (nullable NSString *)lastStyleError:(FlutterError *_Nullable *_Nonnull)error; /// Clears the cache of tiles previously requseted from the tile provider. -- (void)clearTileCacheForOverlayWithIdentifier:(NSString *)tileOverlayId error:(FlutterError *_Nullable *_Nonnull)error; +- (void)clearTileCacheForOverlayWithIdentifier:(NSString *)tileOverlayId + error:(FlutterError *_Nullable *_Nonnull)error; /// Takes a snapshot of the map and returns its image data. -- (nullable FlutterStandardTypedData *)takeSnapshotWithError:(FlutterError *_Nullable *_Nonnull)error; +- (nullable FlutterStandardTypedData *)takeSnapshotWithError: + (FlutterError *_Nullable *_Nonnull)error; @end -extern void SetUpFGMMapsApi(id binaryMessenger, NSObject *_Nullable api); - -extern void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObject *_Nullable api, NSString *messageChannelSuffix); +extern void SetUpFGMMapsApi(id binaryMessenger, + NSObject *_Nullable api); +extern void SetUpFGMMapsApiWithSuffix(id binaryMessenger, + NSObject *_Nullable api, + NSString *messageChannelSuffix); /// Interface for calls from the native SDK to Dart. @interface FGMMapsCallbackApi : NSObject - (instancetype)initWithBinaryMessenger:(id)binaryMessenger; -- (instancetype)initWithBinaryMessenger:(id)binaryMessenger messageChannelSuffix:(nullable NSString *)messageChannelSuffix; +- (instancetype)initWithBinaryMessenger:(id)binaryMessenger + messageChannelSuffix:(nullable NSString *)messageChannelSuffix; /// Called when the map camera starts moving. - (void)didStartCameraMoveWithCompletion:(void (^)(FlutterError *_Nullable))completion; /// Called when the map camera moves. -- (void)didMoveCameraToPosition:(FGMPlatformCameraPosition *)cameraPosition completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didMoveCameraToPosition:(FGMPlatformCameraPosition *)cameraPosition + completion:(void (^)(FlutterError *_Nullable))completion; /// Called when the map camera stops moving. - (void)didIdleCameraWithCompletion:(void (^)(FlutterError *_Nullable))completion; /// Called when the map, not a specifc map object, is tapped. -- (void)didTapAtPosition:(FGMPlatformLatLng *)position completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapAtPosition:(FGMPlatformLatLng *)position + completion:(void (^)(FlutterError *_Nullable))completion; /// Called when the map, not a specifc map object, is long pressed. -- (void)didLongPressAtPosition:(FGMPlatformLatLng *)position completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didLongPressAtPosition:(FGMPlatformLatLng *)position + completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a marker is tapped. -- (void)didTapMarkerWithIdentifier:(NSString *)markerId completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapMarkerWithIdentifier:(NSString *)markerId + completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a marker drag starts. -- (void)didStartDragForMarkerWithIdentifier:(NSString *)markerId atPosition:(FGMPlatformLatLng *)position completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didStartDragForMarkerWithIdentifier:(NSString *)markerId + atPosition:(FGMPlatformLatLng *)position + completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a marker drag updates. -- (void)didDragMarkerWithIdentifier:(NSString *)markerId atPosition:(FGMPlatformLatLng *)position completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didDragMarkerWithIdentifier:(NSString *)markerId + atPosition:(FGMPlatformLatLng *)position + completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a marker drag ends. -- (void)didEndDragForMarkerWithIdentifier:(NSString *)markerId atPosition:(FGMPlatformLatLng *)position completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didEndDragForMarkerWithIdentifier:(NSString *)markerId + atPosition:(FGMPlatformLatLng *)position + completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a marker's info window is tapped. -- (void)didTapInfoWindowOfMarkerWithIdentifier:(NSString *)markerId completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapInfoWindowOfMarkerWithIdentifier:(NSString *)markerId + completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a circle is tapped. -- (void)didTapCircleWithIdentifier:(NSString *)circleId completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapCircleWithIdentifier:(NSString *)circleId + completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a marker cluster is tapped. -- (void)didTapCluster:(FGMPlatformCluster *)cluster completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapCluster:(FGMPlatformCluster *)cluster + completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a polygon is tapped. -- (void)didTapPolygonWithIdentifier:(NSString *)polygonId completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapPolygonWithIdentifier:(NSString *)polygonId + completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a polyline is tapped. -- (void)didTapPolylineWithIdentifier:(NSString *)polylineId completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapPolylineWithIdentifier:(NSString *)polylineId + completion:(void (^)(FlutterError *_Nullable))completion; /// Called when a ground overlay is tapped. -- (void)didTapGroundOverlayWithIdentifier:(NSString *)groundOverlayId completion:(void (^)(FlutterError *_Nullable))completion; +- (void)didTapGroundOverlayWithIdentifier:(NSString *)groundOverlayId + completion:(void (^)(FlutterError *_Nullable))completion; /// Called to get data for a map tile. -- (void)tileWithOverlayIdentifier:(NSString *)tileOverlayId location:(FGMPlatformPoint *)location zoom:(NSInteger)zoom completion:(void (^)(FGMPlatformTile *_Nullable, FlutterError *_Nullable))completion; +- (void)tileWithOverlayIdentifier:(NSString *)tileOverlayId + location:(FGMPlatformPoint *)location + zoom:(NSInteger)zoom + completion:(void (^)(FGMPlatformTile *_Nullable, + FlutterError *_Nullable))completion; @end - /// Dummy interface to force generation of the platform view creation params, /// which are not used in any Pigeon calls, only the platform view creation /// call made internally by Flutter. @protocol FGMMapsPlatformViewApi -- (void)createViewType:(nullable FGMPlatformMapViewCreationParams *)type error:(FlutterError *_Nullable *_Nonnull)error; +- (void)createViewType:(nullable FGMPlatformMapViewCreationParams *)type + error:(FlutterError *_Nullable *_Nonnull)error; @end -extern void SetUpFGMMapsPlatformViewApi(id binaryMessenger, NSObject *_Nullable api); - -extern void SetUpFGMMapsPlatformViewApiWithSuffix(id binaryMessenger, NSObject *_Nullable api, NSString *messageChannelSuffix); +extern void SetUpFGMMapsPlatformViewApi(id binaryMessenger, + NSObject *_Nullable api); +extern void SetUpFGMMapsPlatformViewApiWithSuffix(id binaryMessenger, + NSObject *_Nullable api, + NSString *messageChannelSuffix); /// Inspector API only intended for use in integration tests. @protocol FGMMapsInspectorApi @@ -815,17 +862,27 @@ extern void SetUpFGMMapsPlatformViewApiWithSuffix(id bin - (nullable NSNumber *)isMyLocationButtonEnabledWithError:(FlutterError *_Nullable *_Nonnull)error; /// @return `nil` only when `error != nil`. - (nullable NSNumber *)isTrafficEnabledWithError:(FlutterError *_Nullable *_Nonnull)error; -- (nullable FGMPlatformTileLayer *)tileOverlayWithIdentifier:(NSString *)tileOverlayId error:(FlutterError *_Nullable *_Nonnull)error; -- (nullable FGMPlatformGroundOverlay *)groundOverlayWithIdentifier:(NSString *)groundOverlayId error:(FlutterError *_Nullable *_Nonnull)error; -- (nullable FGMPlatformHeatmap *)heatmapWithIdentifier:(NSString *)heatmapId error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable FGMPlatformTileLayer *)tileOverlayWithIdentifier:(NSString *)tileOverlayId + error: + (FlutterError *_Nullable *_Nonnull)error; +- (nullable FGMPlatformGroundOverlay *) + groundOverlayWithIdentifier:(NSString *)groundOverlayId + error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable FGMPlatformHeatmap *)heatmapWithIdentifier:(NSString *)heatmapId + error:(FlutterError *_Nullable *_Nonnull)error; /// @return `nil` only when `error != nil`. - (nullable FGMPlatformZoomRange *)zoomRange:(FlutterError *_Nullable *_Nonnull)error; /// @return `nil` only when `error != nil`. -- (nullable NSArray *)clustersWithIdentifier:(NSString *)clusterManagerId error:(FlutterError *_Nullable *_Nonnull)error; +- (nullable NSArray *) + clustersWithIdentifier:(NSString *)clusterManagerId + error:(FlutterError *_Nullable *_Nonnull)error; @end -extern void SetUpFGMMapsInspectorApi(id binaryMessenger, NSObject *_Nullable api); +extern void SetUpFGMMapsInspectorApi(id binaryMessenger, + NSObject *_Nullable api); -extern void SetUpFGMMapsInspectorApiWithSuffix(id binaryMessenger, NSObject *_Nullable api, NSString *messageChannelSuffix); +extern void SetUpFGMMapsInspectorApiWithSuffix(id binaryMessenger, + NSObject *_Nullable api, + NSString *messageChannelSuffix); NS_ASSUME_NONNULL_END diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.m b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.m index 01c2ffc23928..ad8c171a7d76 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.m +++ b/packages/google_maps_flutter/google_maps_flutter_ios/ios/Classes/messages.g.m @@ -26,7 +26,12 @@ } static FlutterError *createConnectionError(NSString *channelName) { - return [FlutterError errorWithCode:@"channel-error" message:[NSString stringWithFormat:@"%@/%@/%@", @"Unable to establish connection on channel: '", channelName, @"'."] details:@""]; + return [FlutterError + errorWithCode:@"channel-error" + message:[NSString stringWithFormat:@"%@/%@/%@", + @"Unable to establish connection on channel: '", + channelName, @"'."] + details:@""]; } static id GetNullableObjectAtIndex(NSArray *array, NSInteger key) { @@ -313,11 +318,11 @@ + (nullable FGMPlatformBitmapBytesMap *)nullableFromList:(NSArray *)list; @end @implementation FGMPlatformCameraPosition -+ (instancetype)makeWithBearing:(double )bearing - target:(FGMPlatformLatLng *)target - tilt:(double )tilt - zoom:(double )zoom { - FGMPlatformCameraPosition* pigeonResult = [[FGMPlatformCameraPosition alloc] init]; ++ (instancetype)makeWithBearing:(double)bearing + target:(FGMPlatformLatLng *)target + tilt:(double)tilt + zoom:(double)zoom { + FGMPlatformCameraPosition *pigeonResult = [[FGMPlatformCameraPosition alloc] init]; pigeonResult.bearing = bearing; pigeonResult.target = target; pigeonResult.tilt = tilt; @@ -346,8 +351,8 @@ + (nullable FGMPlatformCameraPosition *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformCameraUpdate -+ (instancetype)makeWithCameraUpdate:(id )cameraUpdate { - FGMPlatformCameraUpdate* pigeonResult = [[FGMPlatformCameraUpdate alloc] init]; ++ (instancetype)makeWithCameraUpdate:(id)cameraUpdate { + FGMPlatformCameraUpdate *pigeonResult = [[FGMPlatformCameraUpdate alloc] init]; pigeonResult.cameraUpdate = cameraUpdate; return pigeonResult; } @@ -368,12 +373,14 @@ + (nullable FGMPlatformCameraUpdate *)nullableFromList:(NSArray *)list { @implementation FGMPlatformCameraUpdateNewCameraPosition + (instancetype)makeWithCameraPosition:(FGMPlatformCameraPosition *)cameraPosition { - FGMPlatformCameraUpdateNewCameraPosition* pigeonResult = [[FGMPlatformCameraUpdateNewCameraPosition alloc] init]; + FGMPlatformCameraUpdateNewCameraPosition *pigeonResult = + [[FGMPlatformCameraUpdateNewCameraPosition alloc] init]; pigeonResult.cameraPosition = cameraPosition; return pigeonResult; } + (FGMPlatformCameraUpdateNewCameraPosition *)fromList:(NSArray *)list { - FGMPlatformCameraUpdateNewCameraPosition *pigeonResult = [[FGMPlatformCameraUpdateNewCameraPosition alloc] init]; + FGMPlatformCameraUpdateNewCameraPosition *pigeonResult = + [[FGMPlatformCameraUpdateNewCameraPosition alloc] init]; pigeonResult.cameraPosition = GetNullableObjectAtIndex(list, 0); return pigeonResult; } @@ -389,7 +396,7 @@ + (nullable FGMPlatformCameraUpdateNewCameraPosition *)nullableFromList:(NSArray @implementation FGMPlatformCameraUpdateNewLatLng + (instancetype)makeWithLatLng:(FGMPlatformLatLng *)latLng { - FGMPlatformCameraUpdateNewLatLng* pigeonResult = [[FGMPlatformCameraUpdateNewLatLng alloc] init]; + FGMPlatformCameraUpdateNewLatLng *pigeonResult = [[FGMPlatformCameraUpdateNewLatLng alloc] init]; pigeonResult.latLng = latLng; return pigeonResult; } @@ -409,15 +416,16 @@ + (nullable FGMPlatformCameraUpdateNewLatLng *)nullableFromList:(NSArray *)l @end @implementation FGMPlatformCameraUpdateNewLatLngBounds -+ (instancetype)makeWithBounds:(FGMPlatformLatLngBounds *)bounds - padding:(double )padding { - FGMPlatformCameraUpdateNewLatLngBounds* pigeonResult = [[FGMPlatformCameraUpdateNewLatLngBounds alloc] init]; ++ (instancetype)makeWithBounds:(FGMPlatformLatLngBounds *)bounds padding:(double)padding { + FGMPlatformCameraUpdateNewLatLngBounds *pigeonResult = + [[FGMPlatformCameraUpdateNewLatLngBounds alloc] init]; pigeonResult.bounds = bounds; pigeonResult.padding = padding; return pigeonResult; } + (FGMPlatformCameraUpdateNewLatLngBounds *)fromList:(NSArray *)list { - FGMPlatformCameraUpdateNewLatLngBounds *pigeonResult = [[FGMPlatformCameraUpdateNewLatLngBounds alloc] init]; + FGMPlatformCameraUpdateNewLatLngBounds *pigeonResult = + [[FGMPlatformCameraUpdateNewLatLngBounds alloc] init]; pigeonResult.bounds = GetNullableObjectAtIndex(list, 0); pigeonResult.padding = [GetNullableObjectAtIndex(list, 1) doubleValue]; return pigeonResult; @@ -434,15 +442,16 @@ + (nullable FGMPlatformCameraUpdateNewLatLngBounds *)nullableFromList:(NSArray *)list { - FGMPlatformCameraUpdateNewLatLngZoom *pigeonResult = [[FGMPlatformCameraUpdateNewLatLngZoom alloc] init]; + FGMPlatformCameraUpdateNewLatLngZoom *pigeonResult = + [[FGMPlatformCameraUpdateNewLatLngZoom alloc] init]; pigeonResult.latLng = GetNullableObjectAtIndex(list, 0); pigeonResult.zoom = [GetNullableObjectAtIndex(list, 1) doubleValue]; return pigeonResult; @@ -459,9 +468,8 @@ + (nullable FGMPlatformCameraUpdateNewLatLngZoom *)nullableFromList:(NSArray @end @implementation FGMPlatformCameraUpdateScrollBy -+ (instancetype)makeWithDx:(double )dx - dy:(double )dy { - FGMPlatformCameraUpdateScrollBy* pigeonResult = [[FGMPlatformCameraUpdateScrollBy alloc] init]; ++ (instancetype)makeWithDx:(double)dx dy:(double)dy { + FGMPlatformCameraUpdateScrollBy *pigeonResult = [[FGMPlatformCameraUpdateScrollBy alloc] init]; pigeonResult.dx = dx; pigeonResult.dy = dy; return pigeonResult; @@ -484,9 +492,8 @@ + (nullable FGMPlatformCameraUpdateScrollBy *)nullableFromList:(NSArray *)li @end @implementation FGMPlatformCameraUpdateZoomBy -+ (instancetype)makeWithAmount:(double )amount - focus:(nullable FGMPlatformPoint *)focus { - FGMPlatformCameraUpdateZoomBy* pigeonResult = [[FGMPlatformCameraUpdateZoomBy alloc] init]; ++ (instancetype)makeWithAmount:(double)amount focus:(nullable FGMPlatformPoint *)focus { + FGMPlatformCameraUpdateZoomBy *pigeonResult = [[FGMPlatformCameraUpdateZoomBy alloc] init]; pigeonResult.amount = amount; pigeonResult.focus = focus; return pigeonResult; @@ -509,8 +516,8 @@ + (nullable FGMPlatformCameraUpdateZoomBy *)nullableFromList:(NSArray *)list @end @implementation FGMPlatformCameraUpdateZoom -+ (instancetype)makeWithOut:(BOOL )out { - FGMPlatformCameraUpdateZoom* pigeonResult = [[FGMPlatformCameraUpdateZoom alloc] init]; ++ (instancetype)makeWithOut:(BOOL)out { + FGMPlatformCameraUpdateZoom *pigeonResult = [[FGMPlatformCameraUpdateZoom alloc] init]; pigeonResult.out = out; return pigeonResult; } @@ -530,8 +537,8 @@ + (nullable FGMPlatformCameraUpdateZoom *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformCameraUpdateZoomTo -+ (instancetype)makeWithZoom:(double )zoom { - FGMPlatformCameraUpdateZoomTo* pigeonResult = [[FGMPlatformCameraUpdateZoomTo alloc] init]; ++ (instancetype)makeWithZoom:(double)zoom { + FGMPlatformCameraUpdateZoomTo *pigeonResult = [[FGMPlatformCameraUpdateZoomTo alloc] init]; pigeonResult.zoom = zoom; return pigeonResult; } @@ -551,16 +558,16 @@ + (nullable FGMPlatformCameraUpdateZoomTo *)nullableFromList:(NSArray *)list @end @implementation FGMPlatformCircle -+ (instancetype)makeWithConsumeTapEvents:(BOOL )consumeTapEvents - fillColor:(NSInteger )fillColor - strokeColor:(NSInteger )strokeColor - visible:(BOOL )visible - strokeWidth:(NSInteger )strokeWidth - zIndex:(double )zIndex - center:(FGMPlatformLatLng *)center - radius:(double )radius - circleId:(NSString *)circleId { - FGMPlatformCircle* pigeonResult = [[FGMPlatformCircle alloc] init]; ++ (instancetype)makeWithConsumeTapEvents:(BOOL)consumeTapEvents + fillColor:(NSInteger)fillColor + strokeColor:(NSInteger)strokeColor + visible:(BOOL)visible + strokeWidth:(NSInteger)strokeWidth + zIndex:(double)zIndex + center:(FGMPlatformLatLng *)center + radius:(double)radius + circleId:(NSString *)circleId { + FGMPlatformCircle *pigeonResult = [[FGMPlatformCircle alloc] init]; pigeonResult.consumeTapEvents = consumeTapEvents; pigeonResult.fillColor = fillColor; pigeonResult.strokeColor = strokeColor; @@ -604,8 +611,8 @@ + (nullable FGMPlatformCircle *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformHeatmap -+ (instancetype)makeWithJson:(id )json { - FGMPlatformHeatmap* pigeonResult = [[FGMPlatformHeatmap alloc] init]; ++ (instancetype)makeWithJson:(id)json { + FGMPlatformHeatmap *pigeonResult = [[FGMPlatformHeatmap alloc] init]; pigeonResult.json = json; return pigeonResult; } @@ -626,9 +633,9 @@ + (nullable FGMPlatformHeatmap *)nullableFromList:(NSArray *)list { @implementation FGMPlatformInfoWindow + (instancetype)makeWithTitle:(nullable NSString *)title - snippet:(nullable NSString *)snippet - anchor:(FGMPlatformPoint *)anchor { - FGMPlatformInfoWindow* pigeonResult = [[FGMPlatformInfoWindow alloc] init]; + snippet:(nullable NSString *)snippet + anchor:(FGMPlatformPoint *)anchor { + FGMPlatformInfoWindow *pigeonResult = [[FGMPlatformInfoWindow alloc] init]; pigeonResult.title = title; pigeonResult.snippet = snippet; pigeonResult.anchor = anchor; @@ -655,10 +662,10 @@ + (nullable FGMPlatformInfoWindow *)nullableFromList:(NSArray *)list { @implementation FGMPlatformCluster + (instancetype)makeWithClusterManagerId:(NSString *)clusterManagerId - position:(FGMPlatformLatLng *)position - bounds:(FGMPlatformLatLngBounds *)bounds - markerIds:(NSArray *)markerIds { - FGMPlatformCluster* pigeonResult = [[FGMPlatformCluster alloc] init]; + position:(FGMPlatformLatLng *)position + bounds:(FGMPlatformLatLngBounds *)bounds + markerIds:(NSArray *)markerIds { + FGMPlatformCluster *pigeonResult = [[FGMPlatformCluster alloc] init]; pigeonResult.clusterManagerId = clusterManagerId; pigeonResult.position = position; pigeonResult.bounds = bounds; @@ -688,7 +695,7 @@ + (nullable FGMPlatformCluster *)nullableFromList:(NSArray *)list { @implementation FGMPlatformClusterManager + (instancetype)makeWithIdentifier:(NSString *)identifier { - FGMPlatformClusterManager* pigeonResult = [[FGMPlatformClusterManager alloc] init]; + FGMPlatformClusterManager *pigeonResult = [[FGMPlatformClusterManager alloc] init]; pigeonResult.identifier = identifier; return pigeonResult; } @@ -708,20 +715,20 @@ + (nullable FGMPlatformClusterManager *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformMarker -+ (instancetype)makeWithAlpha:(double )alpha - anchor:(FGMPlatformPoint *)anchor - consumeTapEvents:(BOOL )consumeTapEvents - draggable:(BOOL )draggable - flat:(BOOL )flat - icon:(FGMPlatformBitmap *)icon - infoWindow:(FGMPlatformInfoWindow *)infoWindow - position:(FGMPlatformLatLng *)position - rotation:(double )rotation - visible:(BOOL )visible - zIndex:(double )zIndex - markerId:(NSString *)markerId - clusterManagerId:(nullable NSString *)clusterManagerId { - FGMPlatformMarker* pigeonResult = [[FGMPlatformMarker alloc] init]; ++ (instancetype)makeWithAlpha:(double)alpha + anchor:(FGMPlatformPoint *)anchor + consumeTapEvents:(BOOL)consumeTapEvents + draggable:(BOOL)draggable + flat:(BOOL)flat + icon:(FGMPlatformBitmap *)icon + infoWindow:(FGMPlatformInfoWindow *)infoWindow + position:(FGMPlatformLatLng *)position + rotation:(double)rotation + visible:(BOOL)visible + zIndex:(double)zIndex + markerId:(NSString *)markerId + clusterManagerId:(nullable NSString *)clusterManagerId { + FGMPlatformMarker *pigeonResult = [[FGMPlatformMarker alloc] init]; pigeonResult.alpha = alpha; pigeonResult.anchor = anchor; pigeonResult.consumeTapEvents = consumeTapEvents; @@ -778,16 +785,16 @@ + (nullable FGMPlatformMarker *)nullableFromList:(NSArray *)list { @implementation FGMPlatformPolygon + (instancetype)makeWithPolygonId:(NSString *)polygonId - consumesTapEvents:(BOOL )consumesTapEvents - fillColor:(NSInteger )fillColor - geodesic:(BOOL )geodesic - points:(NSArray *)points - holes:(NSArray *> *)holes - visible:(BOOL )visible - strokeColor:(NSInteger )strokeColor - strokeWidth:(NSInteger )strokeWidth - zIndex:(NSInteger )zIndex { - FGMPlatformPolygon* pigeonResult = [[FGMPlatformPolygon alloc] init]; + consumesTapEvents:(BOOL)consumesTapEvents + fillColor:(NSInteger)fillColor + geodesic:(BOOL)geodesic + points:(NSArray *)points + holes:(NSArray *> *)holes + visible:(BOOL)visible + strokeColor:(NSInteger)strokeColor + strokeWidth:(NSInteger)strokeWidth + zIndex:(NSInteger)zIndex { + FGMPlatformPolygon *pigeonResult = [[FGMPlatformPolygon alloc] init]; pigeonResult.polygonId = polygonId; pigeonResult.consumesTapEvents = consumesTapEvents; pigeonResult.fillColor = fillColor; @@ -835,16 +842,16 @@ + (nullable FGMPlatformPolygon *)nullableFromList:(NSArray *)list { @implementation FGMPlatformPolyline + (instancetype)makeWithPolylineId:(NSString *)polylineId - consumesTapEvents:(BOOL )consumesTapEvents - color:(NSInteger )color - geodesic:(BOOL )geodesic - jointType:(FGMPlatformJointType)jointType - patterns:(NSArray *)patterns - points:(NSArray *)points - visible:(BOOL )visible - width:(NSInteger )width - zIndex:(NSInteger )zIndex { - FGMPlatformPolyline* pigeonResult = [[FGMPlatformPolyline alloc] init]; + consumesTapEvents:(BOOL)consumesTapEvents + color:(NSInteger)color + geodesic:(BOOL)geodesic + jointType:(FGMPlatformJointType)jointType + patterns:(NSArray *)patterns + points:(NSArray *)points + visible:(BOOL)visible + width:(NSInteger)width + zIndex:(NSInteger)zIndex { + FGMPlatformPolyline *pigeonResult = [[FGMPlatformPolyline alloc] init]; pigeonResult.polylineId = polylineId; pigeonResult.consumesTapEvents = consumesTapEvents; pigeonResult.color = color; @@ -892,16 +899,16 @@ + (nullable FGMPlatformPolyline *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformPatternItem -+ (instancetype)makeWithType:(FGMPlatformPatternItemType)type - length:(nullable NSNumber *)length { - FGMPlatformPatternItem* pigeonResult = [[FGMPlatformPatternItem alloc] init]; ++ (instancetype)makeWithType:(FGMPlatformPatternItemType)type length:(nullable NSNumber *)length { + FGMPlatformPatternItem *pigeonResult = [[FGMPlatformPatternItem alloc] init]; pigeonResult.type = type; pigeonResult.length = length; return pigeonResult; } + (FGMPlatformPatternItem *)fromList:(NSArray *)list { FGMPlatformPatternItem *pigeonResult = [[FGMPlatformPatternItem alloc] init]; - FGMPlatformPatternItemTypeBox *boxedFGMPlatformPatternItemType = GetNullableObjectAtIndex(list, 0); + FGMPlatformPatternItemTypeBox *boxedFGMPlatformPatternItemType = + GetNullableObjectAtIndex(list, 0); pigeonResult.type = boxedFGMPlatformPatternItemType.value; pigeonResult.length = GetNullableObjectAtIndex(list, 1); return pigeonResult; @@ -918,10 +925,10 @@ + (nullable FGMPlatformPatternItem *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformTile -+ (instancetype)makeWithWidth:(NSInteger )width - height:(NSInteger )height - data:(nullable FlutterStandardTypedData *)data { - FGMPlatformTile* pigeonResult = [[FGMPlatformTile alloc] init]; ++ (instancetype)makeWithWidth:(NSInteger)width + height:(NSInteger)height + data:(nullable FlutterStandardTypedData *)data { + FGMPlatformTile *pigeonResult = [[FGMPlatformTile alloc] init]; pigeonResult.width = width; pigeonResult.height = height; pigeonResult.data = data; @@ -948,12 +955,12 @@ + (nullable FGMPlatformTile *)nullableFromList:(NSArray *)list { @implementation FGMPlatformTileOverlay + (instancetype)makeWithTileOverlayId:(NSString *)tileOverlayId - fadeIn:(BOOL )fadeIn - transparency:(double )transparency - zIndex:(NSInteger )zIndex - visible:(BOOL )visible - tileSize:(NSInteger )tileSize { - FGMPlatformTileOverlay* pigeonResult = [[FGMPlatformTileOverlay alloc] init]; + fadeIn:(BOOL)fadeIn + transparency:(double)transparency + zIndex:(NSInteger)zIndex + visible:(BOOL)visible + tileSize:(NSInteger)tileSize { + FGMPlatformTileOverlay *pigeonResult = [[FGMPlatformTileOverlay alloc] init]; pigeonResult.tileOverlayId = tileOverlayId; pigeonResult.fadeIn = fadeIn; pigeonResult.transparency = transparency; @@ -988,11 +995,11 @@ + (nullable FGMPlatformTileOverlay *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformEdgeInsets -+ (instancetype)makeWithTop:(double )top - bottom:(double )bottom - left:(double )left - right:(double )right { - FGMPlatformEdgeInsets* pigeonResult = [[FGMPlatformEdgeInsets alloc] init]; ++ (instancetype)makeWithTop:(double)top + bottom:(double)bottom + left:(double)left + right:(double)right { + FGMPlatformEdgeInsets *pigeonResult = [[FGMPlatformEdgeInsets alloc] init]; pigeonResult.top = top; pigeonResult.bottom = bottom; pigeonResult.left = left; @@ -1021,9 +1028,8 @@ + (nullable FGMPlatformEdgeInsets *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformLatLng -+ (instancetype)makeWithLatitude:(double )latitude - longitude:(double )longitude { - FGMPlatformLatLng* pigeonResult = [[FGMPlatformLatLng alloc] init]; ++ (instancetype)makeWithLatitude:(double)latitude longitude:(double)longitude { + FGMPlatformLatLng *pigeonResult = [[FGMPlatformLatLng alloc] init]; pigeonResult.latitude = latitude; pigeonResult.longitude = longitude; return pigeonResult; @@ -1047,8 +1053,8 @@ + (nullable FGMPlatformLatLng *)nullableFromList:(NSArray *)list { @implementation FGMPlatformLatLngBounds + (instancetype)makeWithNortheast:(FGMPlatformLatLng *)northeast - southwest:(FGMPlatformLatLng *)southwest { - FGMPlatformLatLngBounds* pigeonResult = [[FGMPlatformLatLngBounds alloc] init]; + southwest:(FGMPlatformLatLng *)southwest { + FGMPlatformLatLngBounds *pigeonResult = [[FGMPlatformLatLngBounds alloc] init]; pigeonResult.northeast = northeast; pigeonResult.southwest = southwest; return pigeonResult; @@ -1072,7 +1078,7 @@ + (nullable FGMPlatformLatLngBounds *)nullableFromList:(NSArray *)list { @implementation FGMPlatformCameraTargetBounds + (instancetype)makeWithBounds:(nullable FGMPlatformLatLngBounds *)bounds { - FGMPlatformCameraTargetBounds* pigeonResult = [[FGMPlatformCameraTargetBounds alloc] init]; + FGMPlatformCameraTargetBounds *pigeonResult = [[FGMPlatformCameraTargetBounds alloc] init]; pigeonResult.bounds = bounds; return pigeonResult; } @@ -1093,17 +1099,17 @@ + (nullable FGMPlatformCameraTargetBounds *)nullableFromList:(NSArray *)list @implementation FGMPlatformGroundOverlay + (instancetype)makeWithGroundOverlayId:(NSString *)groundOverlayId - image:(FGMPlatformBitmap *)image - position:(nullable FGMPlatformLatLng *)position - bounds:(nullable FGMPlatformLatLngBounds *)bounds - anchor:(nullable FGMPlatformPoint *)anchor - transparency:(double )transparency - bearing:(double )bearing - zIndex:(double )zIndex - visible:(BOOL )visible - clickable:(BOOL )clickable - zoomLevel:(nullable NSNumber *)zoomLevel { - FGMPlatformGroundOverlay* pigeonResult = [[FGMPlatformGroundOverlay alloc] init]; + image:(FGMPlatformBitmap *)image + position:(nullable FGMPlatformLatLng *)position + bounds:(nullable FGMPlatformLatLngBounds *)bounds + anchor:(nullable FGMPlatformPoint *)anchor + transparency:(double)transparency + bearing:(double)bearing + zIndex:(double)zIndex + visible:(BOOL)visible + clickable:(BOOL)clickable + zoomLevel:(nullable NSNumber *)zoomLevel { + FGMPlatformGroundOverlay *pigeonResult = [[FGMPlatformGroundOverlay alloc] init]; pigeonResult.groundOverlayId = groundOverlayId; pigeonResult.image = image; pigeonResult.position = position; @@ -1153,17 +1159,18 @@ + (nullable FGMPlatformGroundOverlay *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformMapViewCreationParams -+ (instancetype)makeWithInitialCameraPosition:(FGMPlatformCameraPosition *)initialCameraPosition - mapConfiguration:(FGMPlatformMapConfiguration *)mapConfiguration - initialCircles:(NSArray *)initialCircles - initialMarkers:(NSArray *)initialMarkers - initialPolygons:(NSArray *)initialPolygons - initialPolylines:(NSArray *)initialPolylines - initialHeatmaps:(NSArray *)initialHeatmaps - initialTileOverlays:(NSArray *)initialTileOverlays - initialClusterManagers:(NSArray *)initialClusterManagers - initialGroundOverlays:(NSArray *)initialGroundOverlays { - FGMPlatformMapViewCreationParams* pigeonResult = [[FGMPlatformMapViewCreationParams alloc] init]; ++ (instancetype) + makeWithInitialCameraPosition:(FGMPlatformCameraPosition *)initialCameraPosition + mapConfiguration:(FGMPlatformMapConfiguration *)mapConfiguration + initialCircles:(NSArray *)initialCircles + initialMarkers:(NSArray *)initialMarkers + initialPolygons:(NSArray *)initialPolygons + initialPolylines:(NSArray *)initialPolylines + initialHeatmaps:(NSArray *)initialHeatmaps + initialTileOverlays:(NSArray *)initialTileOverlays + initialClusterManagers:(NSArray *)initialClusterManagers + initialGroundOverlays:(NSArray *)initialGroundOverlays { + FGMPlatformMapViewCreationParams *pigeonResult = [[FGMPlatformMapViewCreationParams alloc] init]; pigeonResult.initialCameraPosition = initialCameraPosition; pigeonResult.mapConfiguration = mapConfiguration; pigeonResult.initialCircles = initialCircles; @@ -1211,23 +1218,23 @@ + (nullable FGMPlatformMapViewCreationParams *)nullableFromList:(NSArray *)l @implementation FGMPlatformMapConfiguration + (instancetype)makeWithCompassEnabled:(nullable NSNumber *)compassEnabled - cameraTargetBounds:(nullable FGMPlatformCameraTargetBounds *)cameraTargetBounds - mapType:(nullable FGMPlatformMapTypeBox *)mapType - minMaxZoomPreference:(nullable FGMPlatformZoomRange *)minMaxZoomPreference - rotateGesturesEnabled:(nullable NSNumber *)rotateGesturesEnabled - scrollGesturesEnabled:(nullable NSNumber *)scrollGesturesEnabled - tiltGesturesEnabled:(nullable NSNumber *)tiltGesturesEnabled - trackCameraPosition:(nullable NSNumber *)trackCameraPosition - zoomGesturesEnabled:(nullable NSNumber *)zoomGesturesEnabled - myLocationEnabled:(nullable NSNumber *)myLocationEnabled - myLocationButtonEnabled:(nullable NSNumber *)myLocationButtonEnabled - padding:(nullable FGMPlatformEdgeInsets *)padding - indoorViewEnabled:(nullable NSNumber *)indoorViewEnabled - trafficEnabled:(nullable NSNumber *)trafficEnabled - buildingsEnabled:(nullable NSNumber *)buildingsEnabled - cloudMapId:(nullable NSString *)cloudMapId - style:(nullable NSString *)style { - FGMPlatformMapConfiguration* pigeonResult = [[FGMPlatformMapConfiguration alloc] init]; + cameraTargetBounds:(nullable FGMPlatformCameraTargetBounds *)cameraTargetBounds + mapType:(nullable FGMPlatformMapTypeBox *)mapType + minMaxZoomPreference:(nullable FGMPlatformZoomRange *)minMaxZoomPreference + rotateGesturesEnabled:(nullable NSNumber *)rotateGesturesEnabled + scrollGesturesEnabled:(nullable NSNumber *)scrollGesturesEnabled + tiltGesturesEnabled:(nullable NSNumber *)tiltGesturesEnabled + trackCameraPosition:(nullable NSNumber *)trackCameraPosition + zoomGesturesEnabled:(nullable NSNumber *)zoomGesturesEnabled + myLocationEnabled:(nullable NSNumber *)myLocationEnabled + myLocationButtonEnabled:(nullable NSNumber *)myLocationButtonEnabled + padding:(nullable FGMPlatformEdgeInsets *)padding + indoorViewEnabled:(nullable NSNumber *)indoorViewEnabled + trafficEnabled:(nullable NSNumber *)trafficEnabled + buildingsEnabled:(nullable NSNumber *)buildingsEnabled + cloudMapId:(nullable NSString *)cloudMapId + style:(nullable NSString *)style { + FGMPlatformMapConfiguration *pigeonResult = [[FGMPlatformMapConfiguration alloc] init]; pigeonResult.compassEnabled = compassEnabled; pigeonResult.cameraTargetBounds = cameraTargetBounds; pigeonResult.mapType = mapType; @@ -1295,9 +1302,8 @@ + (nullable FGMPlatformMapConfiguration *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformPoint -+ (instancetype)makeWithX:(double )x - y:(double )y { - FGMPlatformPoint* pigeonResult = [[FGMPlatformPoint alloc] init]; ++ (instancetype)makeWithX:(double)x y:(double)y { + FGMPlatformPoint *pigeonResult = [[FGMPlatformPoint alloc] init]; pigeonResult.x = x; pigeonResult.y = y; return pigeonResult; @@ -1320,9 +1326,8 @@ + (nullable FGMPlatformPoint *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformSize -+ (instancetype)makeWithWidth:(double )width - height:(double )height { - FGMPlatformSize* pigeonResult = [[FGMPlatformSize alloc] init]; ++ (instancetype)makeWithWidth:(double)width height:(double)height { + FGMPlatformSize *pigeonResult = [[FGMPlatformSize alloc] init]; pigeonResult.width = width; pigeonResult.height = height; return pigeonResult; @@ -1345,11 +1350,11 @@ + (nullable FGMPlatformSize *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformTileLayer -+ (instancetype)makeWithVisible:(BOOL )visible - fadeIn:(BOOL )fadeIn - opacity:(double )opacity - zIndex:(NSInteger )zIndex { - FGMPlatformTileLayer* pigeonResult = [[FGMPlatformTileLayer alloc] init]; ++ (instancetype)makeWithVisible:(BOOL)visible + fadeIn:(BOOL)fadeIn + opacity:(double)opacity + zIndex:(NSInteger)zIndex { + FGMPlatformTileLayer *pigeonResult = [[FGMPlatformTileLayer alloc] init]; pigeonResult.visible = visible; pigeonResult.fadeIn = fadeIn; pigeonResult.opacity = opacity; @@ -1378,9 +1383,8 @@ + (nullable FGMPlatformTileLayer *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformZoomRange -+ (instancetype)makeWithMin:(nullable NSNumber *)min - max:(nullable NSNumber *)max { - FGMPlatformZoomRange* pigeonResult = [[FGMPlatformZoomRange alloc] init]; ++ (instancetype)makeWithMin:(nullable NSNumber *)min max:(nullable NSNumber *)max { + FGMPlatformZoomRange *pigeonResult = [[FGMPlatformZoomRange alloc] init]; pigeonResult.min = min; pigeonResult.max = max; return pigeonResult; @@ -1403,8 +1407,8 @@ + (nullable FGMPlatformZoomRange *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformBitmap -+ (instancetype)makeWithBitmap:(id )bitmap { - FGMPlatformBitmap* pigeonResult = [[FGMPlatformBitmap alloc] init]; ++ (instancetype)makeWithBitmap:(id)bitmap { + FGMPlatformBitmap *pigeonResult = [[FGMPlatformBitmap alloc] init]; pigeonResult.bitmap = bitmap; return pigeonResult; } @@ -1425,7 +1429,7 @@ + (nullable FGMPlatformBitmap *)nullableFromList:(NSArray *)list { @implementation FGMPlatformBitmapDefaultMarker + (instancetype)makeWithHue:(nullable NSNumber *)hue { - FGMPlatformBitmapDefaultMarker* pigeonResult = [[FGMPlatformBitmapDefaultMarker alloc] init]; + FGMPlatformBitmapDefaultMarker *pigeonResult = [[FGMPlatformBitmapDefaultMarker alloc] init]; pigeonResult.hue = hue; return pigeonResult; } @@ -1446,8 +1450,8 @@ + (nullable FGMPlatformBitmapDefaultMarker *)nullableFromList:(NSArray *)lis @implementation FGMPlatformBitmapBytes + (instancetype)makeWithByteData:(FlutterStandardTypedData *)byteData - size:(nullable FGMPlatformSize *)size { - FGMPlatformBitmapBytes* pigeonResult = [[FGMPlatformBitmapBytes alloc] init]; + size:(nullable FGMPlatformSize *)size { + FGMPlatformBitmapBytes *pigeonResult = [[FGMPlatformBitmapBytes alloc] init]; pigeonResult.byteData = byteData; pigeonResult.size = size; return pigeonResult; @@ -1470,9 +1474,8 @@ + (nullable FGMPlatformBitmapBytes *)nullableFromList:(NSArray *)list { @end @implementation FGMPlatformBitmapAsset -+ (instancetype)makeWithName:(NSString *)name - pkg:(nullable NSString *)pkg { - FGMPlatformBitmapAsset* pigeonResult = [[FGMPlatformBitmapAsset alloc] init]; ++ (instancetype)makeWithName:(NSString *)name pkg:(nullable NSString *)pkg { + FGMPlatformBitmapAsset *pigeonResult = [[FGMPlatformBitmapAsset alloc] init]; pigeonResult.name = name; pigeonResult.pkg = pkg; return pigeonResult; @@ -1496,9 +1499,9 @@ + (nullable FGMPlatformBitmapAsset *)nullableFromList:(NSArray *)list { @implementation FGMPlatformBitmapAssetImage + (instancetype)makeWithName:(NSString *)name - scale:(double )scale - size:(nullable FGMPlatformSize *)size { - FGMPlatformBitmapAssetImage* pigeonResult = [[FGMPlatformBitmapAssetImage alloc] init]; + scale:(double)scale + size:(nullable FGMPlatformSize *)size { + FGMPlatformBitmapAssetImage *pigeonResult = [[FGMPlatformBitmapAssetImage alloc] init]; pigeonResult.name = name; pigeonResult.scale = scale; pigeonResult.size = size; @@ -1525,11 +1528,11 @@ + (nullable FGMPlatformBitmapAssetImage *)nullableFromList:(NSArray *)list { @implementation FGMPlatformBitmapAssetMap + (instancetype)makeWithAssetName:(NSString *)assetName - bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling - imagePixelRatio:(double )imagePixelRatio - width:(nullable NSNumber *)width - height:(nullable NSNumber *)height { - FGMPlatformBitmapAssetMap* pigeonResult = [[FGMPlatformBitmapAssetMap alloc] init]; + bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling + imagePixelRatio:(double)imagePixelRatio + width:(nullable NSNumber *)width + height:(nullable NSNumber *)height { + FGMPlatformBitmapAssetMap *pigeonResult = [[FGMPlatformBitmapAssetMap alloc] init]; pigeonResult.assetName = assetName; pigeonResult.bitmapScaling = bitmapScaling; pigeonResult.imagePixelRatio = imagePixelRatio; @@ -1540,7 +1543,8 @@ + (instancetype)makeWithAssetName:(NSString *)assetName + (FGMPlatformBitmapAssetMap *)fromList:(NSArray *)list { FGMPlatformBitmapAssetMap *pigeonResult = [[FGMPlatformBitmapAssetMap alloc] init]; pigeonResult.assetName = GetNullableObjectAtIndex(list, 0); - FGMPlatformMapBitmapScalingBox *boxedFGMPlatformMapBitmapScaling = GetNullableObjectAtIndex(list, 1); + FGMPlatformMapBitmapScalingBox *boxedFGMPlatformMapBitmapScaling = + GetNullableObjectAtIndex(list, 1); pigeonResult.bitmapScaling = boxedFGMPlatformMapBitmapScaling.value; pigeonResult.imagePixelRatio = [GetNullableObjectAtIndex(list, 2) doubleValue]; pigeonResult.width = GetNullableObjectAtIndex(list, 3); @@ -1563,11 +1567,11 @@ + (nullable FGMPlatformBitmapAssetMap *)nullableFromList:(NSArray *)list { @implementation FGMPlatformBitmapBytesMap + (instancetype)makeWithByteData:(FlutterStandardTypedData *)byteData - bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling - imagePixelRatio:(double )imagePixelRatio - width:(nullable NSNumber *)width - height:(nullable NSNumber *)height { - FGMPlatformBitmapBytesMap* pigeonResult = [[FGMPlatformBitmapBytesMap alloc] init]; + bitmapScaling:(FGMPlatformMapBitmapScaling)bitmapScaling + imagePixelRatio:(double)imagePixelRatio + width:(nullable NSNumber *)width + height:(nullable NSNumber *)height { + FGMPlatformBitmapBytesMap *pigeonResult = [[FGMPlatformBitmapBytesMap alloc] init]; pigeonResult.byteData = byteData; pigeonResult.bitmapScaling = bitmapScaling; pigeonResult.imagePixelRatio = imagePixelRatio; @@ -1578,7 +1582,8 @@ + (instancetype)makeWithByteData:(FlutterStandardTypedData *)byteData + (FGMPlatformBitmapBytesMap *)fromList:(NSArray *)list { FGMPlatformBitmapBytesMap *pigeonResult = [[FGMPlatformBitmapBytesMap alloc] init]; pigeonResult.byteData = GetNullableObjectAtIndex(list, 0); - FGMPlatformMapBitmapScalingBox *boxedFGMPlatformMapBitmapScaling = GetNullableObjectAtIndex(list, 1); + FGMPlatformMapBitmapScalingBox *boxedFGMPlatformMapBitmapScaling = + GetNullableObjectAtIndex(list, 1); pigeonResult.bitmapScaling = boxedFGMPlatformMapBitmapScaling.value; pigeonResult.imagePixelRatio = [GetNullableObjectAtIndex(list, 2) doubleValue]; pigeonResult.width = GetNullableObjectAtIndex(list, 3); @@ -1606,97 +1611,105 @@ - (nullable id)readValueOfType:(UInt8)type { switch (type) { case 129: { NSNumber *enumAsNumber = [self readValue]; - return enumAsNumber == nil ? nil : [[FGMPlatformMapTypeBox alloc] initWithValue:[enumAsNumber integerValue]]; + return enumAsNumber == nil + ? nil + : [[FGMPlatformMapTypeBox alloc] initWithValue:[enumAsNumber integerValue]]; } case 130: { NSNumber *enumAsNumber = [self readValue]; - return enumAsNumber == nil ? nil : [[FGMPlatformJointTypeBox alloc] initWithValue:[enumAsNumber integerValue]]; + return enumAsNumber == nil + ? nil + : [[FGMPlatformJointTypeBox alloc] initWithValue:[enumAsNumber integerValue]]; } case 131: { NSNumber *enumAsNumber = [self readValue]; - return enumAsNumber == nil ? nil : [[FGMPlatformPatternItemTypeBox alloc] initWithValue:[enumAsNumber integerValue]]; + return enumAsNumber == nil ? nil + : [[FGMPlatformPatternItemTypeBox alloc] + initWithValue:[enumAsNumber integerValue]]; } case 132: { NSNumber *enumAsNumber = [self readValue]; - return enumAsNumber == nil ? nil : [[FGMPlatformMapBitmapScalingBox alloc] initWithValue:[enumAsNumber integerValue]]; + return enumAsNumber == nil ? nil + : [[FGMPlatformMapBitmapScalingBox alloc] + initWithValue:[enumAsNumber integerValue]]; } - case 133: + case 133: return [FGMPlatformCameraPosition fromList:[self readValue]]; - case 134: + case 134: return [FGMPlatformCameraUpdate fromList:[self readValue]]; - case 135: + case 135: return [FGMPlatformCameraUpdateNewCameraPosition fromList:[self readValue]]; - case 136: + case 136: return [FGMPlatformCameraUpdateNewLatLng fromList:[self readValue]]; - case 137: + case 137: return [FGMPlatformCameraUpdateNewLatLngBounds fromList:[self readValue]]; - case 138: + case 138: return [FGMPlatformCameraUpdateNewLatLngZoom fromList:[self readValue]]; - case 139: + case 139: return [FGMPlatformCameraUpdateScrollBy fromList:[self readValue]]; - case 140: + case 140: return [FGMPlatformCameraUpdateZoomBy fromList:[self readValue]]; - case 141: + case 141: return [FGMPlatformCameraUpdateZoom fromList:[self readValue]]; - case 142: + case 142: return [FGMPlatformCameraUpdateZoomTo fromList:[self readValue]]; - case 143: + case 143: return [FGMPlatformCircle fromList:[self readValue]]; - case 144: + case 144: return [FGMPlatformHeatmap fromList:[self readValue]]; - case 145: + case 145: return [FGMPlatformInfoWindow fromList:[self readValue]]; - case 146: + case 146: return [FGMPlatformCluster fromList:[self readValue]]; - case 147: + case 147: return [FGMPlatformClusterManager fromList:[self readValue]]; - case 148: + case 148: return [FGMPlatformMarker fromList:[self readValue]]; - case 149: + case 149: return [FGMPlatformPolygon fromList:[self readValue]]; - case 150: + case 150: return [FGMPlatformPolyline fromList:[self readValue]]; - case 151: + case 151: return [FGMPlatformPatternItem fromList:[self readValue]]; - case 152: + case 152: return [FGMPlatformTile fromList:[self readValue]]; - case 153: + case 153: return [FGMPlatformTileOverlay fromList:[self readValue]]; - case 154: + case 154: return [FGMPlatformEdgeInsets fromList:[self readValue]]; - case 155: + case 155: return [FGMPlatformLatLng fromList:[self readValue]]; - case 156: + case 156: return [FGMPlatformLatLngBounds fromList:[self readValue]]; - case 157: + case 157: return [FGMPlatformCameraTargetBounds fromList:[self readValue]]; - case 158: + case 158: return [FGMPlatformGroundOverlay fromList:[self readValue]]; - case 159: + case 159: return [FGMPlatformMapViewCreationParams fromList:[self readValue]]; - case 160: + case 160: return [FGMPlatformMapConfiguration fromList:[self readValue]]; - case 161: + case 161: return [FGMPlatformPoint fromList:[self readValue]]; - case 162: + case 162: return [FGMPlatformSize fromList:[self readValue]]; - case 163: + case 163: return [FGMPlatformTileLayer fromList:[self readValue]]; - case 164: + case 164: return [FGMPlatformZoomRange fromList:[self readValue]]; - case 165: + case 165: return [FGMPlatformBitmap fromList:[self readValue]]; - case 166: + case 166: return [FGMPlatformBitmapDefaultMarker fromList:[self readValue]]; - case 167: + case 167: return [FGMPlatformBitmapBytes fromList:[self readValue]]; - case 168: + case 168: return [FGMPlatformBitmapAsset fromList:[self readValue]]; - case 169: + case 169: return [FGMPlatformBitmapAssetImage fromList:[self readValue]]; - case 170: + case 170: return [FGMPlatformBitmapAssetMap fromList:[self readValue]]; - case 171: + case 171: return [FGMPlatformBitmapBytesMap fromList:[self readValue]]; default: return [super readValueOfType:type]; @@ -1862,7 +1875,8 @@ - (FlutterStandardReader *)readerWithData:(NSData *)data { static FlutterStandardMessageCodec *sSharedObject = nil; static dispatch_once_t sPred = 0; dispatch_once(&sPred, ^{ - FGMMessagesPigeonCodecReaderWriter *readerWriter = [[FGMMessagesPigeonCodecReaderWriter alloc] init]; + FGMMessagesPigeonCodecReaderWriter *readerWriter = + [[FGMMessagesPigeonCodecReaderWriter alloc] init]; sSharedObject = [FlutterStandardMessageCodec codecWithReaderWriter:readerWriter]; }); return sSharedObject; @@ -1871,17 +1885,24 @@ void SetUpFGMMapsApi(id binaryMessenger, NSObject binaryMessenger, NSObject *api, NSString *messageChannelSuffix) { - messageChannelSuffix = messageChannelSuffix.length > 0 ? [NSString stringWithFormat: @".%@", messageChannelSuffix] : @""; +void SetUpFGMMapsApiWithSuffix(id binaryMessenger, + NSObject *api, NSString *messageChannelSuffix) { + messageChannelSuffix = messageChannelSuffix.length > 0 + ? [NSString stringWithFormat:@".%@", messageChannelSuffix] + : @""; /// Returns once the map instance is available. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.waitForMap", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString + stringWithFormat: + @"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.waitForMap", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(waitForMapWithError:)], @"FGMMapsApi api (%@) doesn't respond to @selector(waitForMapWithError:)", api); + NSCAssert([api respondsToSelector:@selector(waitForMapWithError:)], + @"FGMMapsApi api (%@) doesn't respond to @selector(waitForMapWithError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; [api waitForMapWithError:&error]; @@ -1896,13 +1917,18 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj /// Only non-null configuration values will result in updates; options with /// null values will remain unchanged. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMapConfiguration", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.updateMapConfiguration", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateWithMapConfiguration:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateWithMapConfiguration:error:)", api); + NSCAssert( + [api respondsToSelector:@selector(updateWithMapConfiguration:error:)], + @"FGMMapsApi api (%@) doesn't respond to @selector(updateWithMapConfiguration:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; FGMPlatformMapConfiguration *arg_configuration = GetNullableObjectAtIndex(args, 0); @@ -1916,20 +1942,29 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Updates the set of circles on the map. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateCircles", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString + stringWithFormat: + @"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateCircles", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateCirclesByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateCirclesByAdding:changing:removing:error:)", api); + NSCAssert([api respondsToSelector:@selector(updateCirclesByAdding:changing:removing:error:)], + @"FGMMapsApi api (%@) doesn't respond to " + @"@selector(updateCirclesByAdding:changing:removing:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updateCirclesByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; + [api updateCirclesByAdding:arg_toAdd + changing:arg_toChange + removing:arg_idsToRemove + error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -1938,20 +1973,28 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Updates the set of heatmaps on the map. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateHeatmaps", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.updateHeatmaps", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateHeatmapsByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateHeatmapsByAdding:changing:removing:error:)", api); + NSCAssert([api respondsToSelector:@selector(updateHeatmapsByAdding:changing:removing:error:)], + @"FGMMapsApi api (%@) doesn't respond to " + @"@selector(updateHeatmapsByAdding:changing:removing:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updateHeatmapsByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; + [api updateHeatmapsByAdding:arg_toAdd + changing:arg_toChange + removing:arg_idsToRemove + error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -1960,13 +2003,18 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Updates the set of custer managers for clusters on the map. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateClusterManagers", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.updateClusterManagers", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateClusterManagersByAdding:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateClusterManagersByAdding:removing:error:)", api); + NSCAssert([api respondsToSelector:@selector(updateClusterManagersByAdding:removing:error:)], + @"FGMMapsApi api (%@) doesn't respond to " + @"@selector(updateClusterManagersByAdding:removing:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); @@ -1981,20 +2029,29 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Updates the set of markers on the map. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMarkers", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString + stringWithFormat: + @"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMarkers", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateMarkersByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateMarkersByAdding:changing:removing:error:)", api); + NSCAssert([api respondsToSelector:@selector(updateMarkersByAdding:changing:removing:error:)], + @"FGMMapsApi api (%@) doesn't respond to " + @"@selector(updateMarkersByAdding:changing:removing:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updateMarkersByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; + [api updateMarkersByAdding:arg_toAdd + changing:arg_toChange + removing:arg_idsToRemove + error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -2003,20 +2060,28 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Updates the set of polygonss on the map. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updatePolygons", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.updatePolygons", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updatePolygonsByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updatePolygonsByAdding:changing:removing:error:)", api); + NSCAssert([api respondsToSelector:@selector(updatePolygonsByAdding:changing:removing:error:)], + @"FGMMapsApi api (%@) doesn't respond to " + @"@selector(updatePolygonsByAdding:changing:removing:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updatePolygonsByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; + [api updatePolygonsByAdding:arg_toAdd + changing:arg_toChange + removing:arg_idsToRemove + error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -2025,20 +2090,29 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Updates the set of polylines on the map. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updatePolylines", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.updatePolylines", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updatePolylinesByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updatePolylinesByAdding:changing:removing:error:)", api); + NSCAssert([api respondsToSelector:@selector(updatePolylinesByAdding: + changing:removing:error:)], + @"FGMMapsApi api (%@) doesn't respond to " + @"@selector(updatePolylinesByAdding:changing:removing:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updatePolylinesByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; + [api updatePolylinesByAdding:arg_toAdd + changing:arg_toChange + removing:arg_idsToRemove + error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -2047,20 +2121,29 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Updates the set of tile overlays on the map. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateTileOverlays", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.updateTileOverlays", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateTileOverlaysByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateTileOverlaysByAdding:changing:removing:error:)", api); + NSCAssert([api respondsToSelector:@selector(updateTileOverlaysByAdding: + changing:removing:error:)], + @"FGMMapsApi api (%@) doesn't respond to " + @"@selector(updateTileOverlaysByAdding:changing:removing:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updateTileOverlaysByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; + [api updateTileOverlaysByAdding:arg_toAdd + changing:arg_toChange + removing:arg_idsToRemove + error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -2069,20 +2152,29 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Updates the set of ground overlays on the map. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateGroundOverlays", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.updateGroundOverlays", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(updateGroundOverlaysByAdding:changing:removing:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(updateGroundOverlaysByAdding:changing:removing:error:)", api); + NSCAssert([api respondsToSelector:@selector(updateGroundOverlaysByAdding: + changing:removing:error:)], + @"FGMMapsApi api (%@) doesn't respond to " + @"@selector(updateGroundOverlaysByAdding:changing:removing:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSArray *arg_toAdd = GetNullableObjectAtIndex(args, 0); NSArray *arg_toChange = GetNullableObjectAtIndex(args, 1); NSArray *arg_idsToRemove = GetNullableObjectAtIndex(args, 2); FlutterError *error; - [api updateGroundOverlaysByAdding:arg_toAdd changing:arg_toChange removing:arg_idsToRemove error:&error]; + [api updateGroundOverlaysByAdding:arg_toAdd + changing:arg_toChange + removing:arg_idsToRemove + error:&error]; callback(wrapResult(nil, error)); }]; } else { @@ -2091,13 +2183,18 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Gets the screen coordinate for the given map location. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getScreenCoordinate", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.getScreenCoordinate", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(screenCoordinatesForLatLng:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(screenCoordinatesForLatLng:error:)", api); + NSCAssert( + [api respondsToSelector:@selector(screenCoordinatesForLatLng:error:)], + @"FGMMapsApi api (%@) doesn't respond to @selector(screenCoordinatesForLatLng:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; FGMPlatformLatLng *arg_latLng = GetNullableObjectAtIndex(args, 0); @@ -2111,18 +2208,25 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Gets the map location for the given screen coordinate. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLatLng", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName: + [NSString + stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLatLng", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(latLngForScreenCoordinate:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(latLngForScreenCoordinate:error:)", api); + NSCAssert( + [api respondsToSelector:@selector(latLngForScreenCoordinate:error:)], + @"FGMMapsApi api (%@) doesn't respond to @selector(latLngForScreenCoordinate:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; FGMPlatformPoint *arg_screenCoordinate = GetNullableObjectAtIndex(args, 0); FlutterError *error; - FGMPlatformLatLng *output = [api latLngForScreenCoordinate:arg_screenCoordinate error:&error]; + FGMPlatformLatLng *output = [api latLngForScreenCoordinate:arg_screenCoordinate + error:&error]; callback(wrapResult(output, error)); }]; } else { @@ -2131,13 +2235,16 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Gets the map region currently displayed on the map. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getVisibleRegion", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.getVisibleRegion", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(visibleMapRegion:)], @"FGMMapsApi api (%@) doesn't respond to @selector(visibleMapRegion:)", api); + NSCAssert([api respondsToSelector:@selector(visibleMapRegion:)], + @"FGMMapsApi api (%@) doesn't respond to @selector(visibleMapRegion:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; FGMPlatformLatLngBounds *output = [api visibleMapRegion:&error]; @@ -2150,13 +2257,18 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj /// Moves the camera according to [cameraUpdate] immediately, with no /// animation. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.moveCamera", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString + stringWithFormat: + @"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.moveCamera", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(moveCameraWithUpdate:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(moveCameraWithUpdate:error:)", api); + NSCAssert([api respondsToSelector:@selector(moveCameraWithUpdate:error:)], + @"FGMMapsApi api (%@) doesn't respond to @selector(moveCameraWithUpdate:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; FGMPlatformCameraUpdate *arg_cameraUpdate = GetNullableObjectAtIndex(args, 0); @@ -2170,13 +2282,18 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Moves the camera according to [cameraUpdate], animating the update. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.animateCamera", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString + stringWithFormat: + @"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.animateCamera", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(animateCameraWithUpdate:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(animateCameraWithUpdate:error:)", api); + NSCAssert([api respondsToSelector:@selector(animateCameraWithUpdate:error:)], + @"FGMMapsApi api (%@) doesn't respond to @selector(animateCameraWithUpdate:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; FGMPlatformCameraUpdate *arg_cameraUpdate = GetNullableObjectAtIndex(args, 0); @@ -2190,13 +2307,17 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Gets the current map zoom level. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getZoomLevel", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString + stringWithFormat: + @"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getZoomLevel", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(currentZoomLevel:)], @"FGMMapsApi api (%@) doesn't respond to @selector(currentZoomLevel:)", api); + NSCAssert([api respondsToSelector:@selector(currentZoomLevel:)], + @"FGMMapsApi api (%@) doesn't respond to @selector(currentZoomLevel:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api currentZoomLevel:&error]; @@ -2208,13 +2329,18 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Show the info window for the marker with the given ID. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.showInfoWindow", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.showInfoWindow", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(showInfoWindowForMarkerWithIdentifier:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(showInfoWindowForMarkerWithIdentifier:error:)", api); + NSCAssert([api respondsToSelector:@selector(showInfoWindowForMarkerWithIdentifier:error:)], + @"FGMMapsApi api (%@) doesn't respond to " + @"@selector(showInfoWindowForMarkerWithIdentifier:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_markerId = GetNullableObjectAtIndex(args, 0); @@ -2228,13 +2354,18 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Hide the info window for the marker with the given ID. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.hideInfoWindow", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.hideInfoWindow", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(hideInfoWindowForMarkerWithIdentifier:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(hideInfoWindowForMarkerWithIdentifier:error:)", api); + NSCAssert([api respondsToSelector:@selector(hideInfoWindowForMarkerWithIdentifier:error:)], + @"FGMMapsApi api (%@) doesn't respond to " + @"@selector(hideInfoWindowForMarkerWithIdentifier:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_markerId = GetNullableObjectAtIndex(args, 0); @@ -2249,18 +2380,25 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj /// Returns true if the marker with the given ID is currently displaying its /// info window. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.isInfoWindowShown", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.isInfoWindowShown", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(isShowingInfoWindowForMarkerWithIdentifier:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(isShowingInfoWindowForMarkerWithIdentifier:error:)", api); + NSCAssert([api respondsToSelector:@selector(isShowingInfoWindowForMarkerWithIdentifier: + error:)], + @"FGMMapsApi api (%@) doesn't respond to " + @"@selector(isShowingInfoWindowForMarkerWithIdentifier:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_markerId = GetNullableObjectAtIndex(args, 0); FlutterError *error; - NSNumber *output = [api isShowingInfoWindowForMarkerWithIdentifier:arg_markerId error:&error]; + NSNumber *output = [api isShowingInfoWindowForMarkerWithIdentifier:arg_markerId + error:&error]; callback(wrapResult(output, error)); }]; } else { @@ -2273,13 +2411,17 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj /// If there was an error setting the style, such as an invalid style string, /// returns the error message. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.setStyle", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName: + [NSString + stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.setStyle", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(setStyle:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(setStyle:error:)", api); + NSCAssert([api respondsToSelector:@selector(setStyle:error:)], + @"FGMMapsApi api (%@) doesn't respond to @selector(setStyle:error:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_style = GetNullableObjectAtIndex(args, 0); @@ -2297,13 +2439,16 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj /// This allows checking asynchronously for initial style failures, as there /// is no way to return failures from map initialization. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLastStyleError", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.getLastStyleError", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(lastStyleError:)], @"FGMMapsApi api (%@) doesn't respond to @selector(lastStyleError:)", api); + NSCAssert([api respondsToSelector:@selector(lastStyleError:)], + @"FGMMapsApi api (%@) doesn't respond to @selector(lastStyleError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSString *output = [api lastStyleError:&error]; @@ -2315,13 +2460,18 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Clears the cache of tiles previously requseted from the tile provider. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.clearTileCache", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsApi.clearTileCache", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(clearTileCacheForOverlayWithIdentifier:error:)], @"FGMMapsApi api (%@) doesn't respond to @selector(clearTileCacheForOverlayWithIdentifier:error:)", api); + NSCAssert([api respondsToSelector:@selector(clearTileCacheForOverlayWithIdentifier:error:)], + @"FGMMapsApi api (%@) doesn't respond to " + @"@selector(clearTileCacheForOverlayWithIdentifier:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_tileOverlayId = GetNullableObjectAtIndex(args, 0); @@ -2335,13 +2485,17 @@ void SetUpFGMMapsApiWithSuffix(id binaryMessenger, NSObj } /// Takes a snapshot of the map and returns its image data. { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.takeSnapshot", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString + stringWithFormat: + @"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.takeSnapshot", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(takeSnapshotWithError:)], @"FGMMapsApi api (%@) doesn't respond to @selector(takeSnapshotWithError:)", api); + NSCAssert([api respondsToSelector:@selector(takeSnapshotWithError:)], + @"FGMMapsApi api (%@) doesn't respond to @selector(takeSnapshotWithError:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; FlutterStandardTypedData *output = [api takeSnapshotWithError:&error]; @@ -2362,335 +2516,450 @@ @implementation FGMMapsCallbackApi - (instancetype)initWithBinaryMessenger:(NSObject *)binaryMessenger { return [self initWithBinaryMessenger:binaryMessenger messageChannelSuffix:@""]; } -- (instancetype)initWithBinaryMessenger:(NSObject *)binaryMessenger messageChannelSuffix:(nullable NSString*)messageChannelSuffix{ +- (instancetype)initWithBinaryMessenger:(NSObject *)binaryMessenger + messageChannelSuffix:(nullable NSString *)messageChannelSuffix { self = [self init]; if (self) { _binaryMessenger = binaryMessenger; - _messageChannelSuffix = [messageChannelSuffix length] == 0 ? @"" : [NSString stringWithFormat: @".%@", messageChannelSuffix]; + _messageChannelSuffix = [messageChannelSuffix length] == 0 + ? @"" + : [NSString stringWithFormat:@".%@", messageChannelSuffix]; } return self; } - (void)didStartCameraMoveWithCompletion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMoveStarted", _messageChannelSuffix]; + NSString *channelName = [NSString + stringWithFormat: + @"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMoveStarted", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:nil reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didMoveCameraToPosition:(FGMPlatformCameraPosition *)arg_cameraPosition completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:nil + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didMoveCameraToPosition:(FGMPlatformCameraPosition *)arg_cameraPosition + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_cameraPosition ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_cameraPosition ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; } - (void)didIdleCameraWithCompletion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraIdle", _messageChannelSuffix]; + NSString *channelName = [NSString + stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraIdle", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:nil reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapAtPosition:(FGMPlatformLatLng *)arg_position completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onTap", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:nil + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapAtPosition:(FGMPlatformLatLng *)arg_position + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onTap", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_position ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didLongPressAtPosition:(FGMPlatformLatLng *)arg_position completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onLongPress", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_position ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didLongPressAtPosition:(FGMPlatformLatLng *)arg_position + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onLongPress", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_position ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapMarkerWithIdentifier:(NSString *)arg_markerId completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerTap", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_position ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapMarkerWithIdentifier:(NSString *)arg_markerId + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerTap", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_markerId ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didStartDragForMarkerWithIdentifier:(NSString *)arg_markerId atPosition:(FGMPlatformLatLng *)arg_position completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragStart", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_markerId ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didStartDragForMarkerWithIdentifier:(NSString *)arg_markerId + atPosition:(FGMPlatformLatLng *)arg_position + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat: + @"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragStart", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_markerId ?: [NSNull null], arg_position ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didDragMarkerWithIdentifier:(NSString *)arg_markerId atPosition:(FGMPlatformLatLng *)arg_position completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDrag", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_markerId ?: [NSNull null], arg_position ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didDragMarkerWithIdentifier:(NSString *)arg_markerId + atPosition:(FGMPlatformLatLng *)arg_position + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDrag", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_markerId ?: [NSNull null], arg_position ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didEndDragForMarkerWithIdentifier:(NSString *)arg_markerId atPosition:(FGMPlatformLatLng *)arg_position completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragEnd", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_markerId ?: [NSNull null], arg_position ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didEndDragForMarkerWithIdentifier:(NSString *)arg_markerId + atPosition:(FGMPlatformLatLng *)arg_position + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat: + @"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragEnd", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_markerId ?: [NSNull null], arg_position ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapInfoWindowOfMarkerWithIdentifier:(NSString *)arg_markerId completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onInfoWindowTap", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_markerId ?: [NSNull null], arg_position ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapInfoWindowOfMarkerWithIdentifier:(NSString *)arg_markerId + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat: + @"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onInfoWindowTap", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_markerId ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapCircleWithIdentifier:(NSString *)arg_circleId completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCircleTap", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_markerId ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapCircleWithIdentifier:(NSString *)arg_circleId + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCircleTap", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_circleId ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapCluster:(FGMPlatformCluster *)arg_cluster completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onClusterTap", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_circleId ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapCluster:(FGMPlatformCluster *)arg_cluster + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onClusterTap", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_cluster ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapPolygonWithIdentifier:(NSString *)arg_polygonId completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolygonTap", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_cluster ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapPolygonWithIdentifier:(NSString *)arg_polygonId + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolygonTap", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_polygonId ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapPolylineWithIdentifier:(NSString *)arg_polylineId completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolylineTap", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_polygonId ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapPolylineWithIdentifier:(NSString *)arg_polylineId + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolylineTap", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_polylineId ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)didTapGroundOverlayWithIdentifier:(NSString *)arg_groundOverlayId completion:(void (^)(FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onGroundOverlayTap", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_polylineId ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)didTapGroundOverlayWithIdentifier:(NSString *)arg_groundOverlayId + completion:(void (^)(FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat: + @"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onGroundOverlayTap", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_groundOverlayId ?: [NSNull null]] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion([FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - completion(nil); - } - } else { - completion(createConnectionError(channelName)); - } - }]; -} -- (void)tileWithOverlayIdentifier:(NSString *)arg_tileOverlayId location:(FGMPlatformPoint *)arg_location zoom:(NSInteger)arg_zoom completion:(void (^)(FGMPlatformTile *_Nullable, FlutterError *_Nullable))completion { - NSString *channelName = [NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile", _messageChannelSuffix]; + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ arg_groundOverlayId ?: [NSNull null] ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion([FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + completion(nil); + } + } else { + completion(createConnectionError(channelName)); + } + }]; +} +- (void)tileWithOverlayIdentifier:(NSString *)arg_tileOverlayId + location:(FGMPlatformPoint *)arg_location + zoom:(NSInteger)arg_zoom + completion:(void (^)(FGMPlatformTile *_Nullable, + FlutterError *_Nullable))completion { + NSString *channelName = [NSString + stringWithFormat: + @"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile", + _messageChannelSuffix]; FlutterBasicMessageChannel *channel = - [FlutterBasicMessageChannel - messageChannelWithName:channelName - binaryMessenger:self.binaryMessenger - codec:FGMGetMessagesCodec()]; - [channel sendMessage:@[arg_tileOverlayId ?: [NSNull null], arg_location ?: [NSNull null], @(arg_zoom)] reply:^(NSArray *reply) { - if (reply != nil) { - if (reply.count > 1) { - completion(nil, [FlutterError errorWithCode:reply[0] message:reply[1] details:reply[2]]); - } else { - FGMPlatformTile *output = reply[0] == [NSNull null] ? nil : reply[0]; - completion(output, nil); - } - } else { - completion(nil, createConnectionError(channelName)); - } - }]; -} -@end - -void SetUpFGMMapsPlatformViewApi(id binaryMessenger, NSObject *api) { + [FlutterBasicMessageChannel messageChannelWithName:channelName + binaryMessenger:self.binaryMessenger + codec:FGMGetMessagesCodec()]; + [channel sendMessage:@[ + arg_tileOverlayId ?: [NSNull null], arg_location ?: [NSNull null], @(arg_zoom) + ] + reply:^(NSArray *reply) { + if (reply != nil) { + if (reply.count > 1) { + completion(nil, [FlutterError errorWithCode:reply[0] + message:reply[1] + details:reply[2]]); + } else { + FGMPlatformTile *output = reply[0] == [NSNull null] ? nil : reply[0]; + completion(output, nil); + } + } else { + completion(nil, createConnectionError(channelName)); + } + }]; +} +@end + +void SetUpFGMMapsPlatformViewApi(id binaryMessenger, + NSObject *api) { SetUpFGMMapsPlatformViewApiWithSuffix(binaryMessenger, api, @""); } -void SetUpFGMMapsPlatformViewApiWithSuffix(id binaryMessenger, NSObject *api, NSString *messageChannelSuffix) { - messageChannelSuffix = messageChannelSuffix.length > 0 ? [NSString stringWithFormat: @".%@", messageChannelSuffix] : @""; +void SetUpFGMMapsPlatformViewApiWithSuffix(id binaryMessenger, + NSObject *api, + NSString *messageChannelSuffix) { + messageChannelSuffix = messageChannelSuffix.length > 0 + ? [NSString stringWithFormat:@".%@", messageChannelSuffix] + : @""; { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsPlatformViewApi.createView", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsPlatformViewApi.createView", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(createViewType:error:)], @"FGMMapsPlatformViewApi api (%@) doesn't respond to @selector(createViewType:error:)", api); + NSCAssert( + [api respondsToSelector:@selector(createViewType:error:)], + @"FGMMapsPlatformViewApi api (%@) doesn't respond to @selector(createViewType:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; FGMPlatformMapViewCreationParams *arg_type = GetNullableObjectAtIndex(args, 0); @@ -2703,20 +2972,30 @@ void SetUpFGMMapsPlatformViewApiWithSuffix(id binaryMess } } } -void SetUpFGMMapsInspectorApi(id binaryMessenger, NSObject *api) { +void SetUpFGMMapsInspectorApi(id binaryMessenger, + NSObject *api) { SetUpFGMMapsInspectorApiWithSuffix(binaryMessenger, api, @""); } -void SetUpFGMMapsInspectorApiWithSuffix(id binaryMessenger, NSObject *api, NSString *messageChannelSuffix) { - messageChannelSuffix = messageChannelSuffix.length > 0 ? [NSString stringWithFormat: @".%@", messageChannelSuffix] : @""; +void SetUpFGMMapsInspectorApiWithSuffix(id binaryMessenger, + NSObject *api, + NSString *messageChannelSuffix) { + messageChannelSuffix = messageChannelSuffix.length > 0 + ? [NSString stringWithFormat:@".%@", messageChannelSuffix] + : @""; { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areBuildingsEnabled", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.areBuildingsEnabled", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(areBuildingsEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(areBuildingsEnabledWithError:)", api); + NSCAssert([api respondsToSelector:@selector(areBuildingsEnabledWithError:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to " + @"@selector(areBuildingsEnabledWithError:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api areBuildingsEnabledWithError:&error]; @@ -2727,13 +3006,18 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areRotateGesturesEnabled", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.areRotateGesturesEnabled", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(areRotateGesturesEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(areRotateGesturesEnabledWithError:)", api); + NSCAssert([api respondsToSelector:@selector(areRotateGesturesEnabledWithError:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to " + @"@selector(areRotateGesturesEnabledWithError:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api areRotateGesturesEnabledWithError:&error]; @@ -2744,13 +3028,18 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areScrollGesturesEnabled", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.areScrollGesturesEnabled", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(areScrollGesturesEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(areScrollGesturesEnabledWithError:)", api); + NSCAssert([api respondsToSelector:@selector(areScrollGesturesEnabledWithError:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to " + @"@selector(areScrollGesturesEnabledWithError:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api areScrollGesturesEnabledWithError:&error]; @@ -2761,13 +3050,18 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areTiltGesturesEnabled", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.areTiltGesturesEnabled", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(areTiltGesturesEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(areTiltGesturesEnabledWithError:)", api); + NSCAssert([api respondsToSelector:@selector(areTiltGesturesEnabledWithError:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to " + @"@selector(areTiltGesturesEnabledWithError:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api areTiltGesturesEnabledWithError:&error]; @@ -2778,13 +3072,18 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areZoomGesturesEnabled", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.areZoomGesturesEnabled", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(areZoomGesturesEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(areZoomGesturesEnabledWithError:)", api); + NSCAssert([api respondsToSelector:@selector(areZoomGesturesEnabledWithError:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to " + @"@selector(areZoomGesturesEnabledWithError:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api areZoomGesturesEnabledWithError:&error]; @@ -2795,13 +3094,18 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isCompassEnabled", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.isCompassEnabled", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(isCompassEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(isCompassEnabledWithError:)", api); + NSCAssert( + [api respondsToSelector:@selector(isCompassEnabledWithError:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(isCompassEnabledWithError:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api isCompassEnabledWithError:&error]; @@ -2812,13 +3116,18 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isMyLocationButtonEnabled", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.isMyLocationButtonEnabled", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(isMyLocationButtonEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(isMyLocationButtonEnabledWithError:)", api); + NSCAssert([api respondsToSelector:@selector(isMyLocationButtonEnabledWithError:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to " + @"@selector(isMyLocationButtonEnabledWithError:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api isMyLocationButtonEnabledWithError:&error]; @@ -2829,13 +3138,18 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isTrafficEnabled", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.isTrafficEnabled", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(isTrafficEnabledWithError:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(isTrafficEnabledWithError:)", api); + NSCAssert( + [api respondsToSelector:@selector(isTrafficEnabledWithError:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(isTrafficEnabledWithError:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; NSNumber *output = [api isTrafficEnabledWithError:&error]; @@ -2846,18 +3160,24 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getTileOverlayInfo", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.getTileOverlayInfo", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(tileOverlayWithIdentifier:error:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(tileOverlayWithIdentifier:error:)", api); + NSCAssert([api respondsToSelector:@selector(tileOverlayWithIdentifier:error:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to " + @"@selector(tileOverlayWithIdentifier:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_tileOverlayId = GetNullableObjectAtIndex(args, 0); FlutterError *error; - FGMPlatformTileLayer *output = [api tileOverlayWithIdentifier:arg_tileOverlayId error:&error]; + FGMPlatformTileLayer *output = [api tileOverlayWithIdentifier:arg_tileOverlayId + error:&error]; callback(wrapResult(output, error)); }]; } else { @@ -2865,18 +3185,24 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getGroundOverlayInfo", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.getGroundOverlayInfo", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(groundOverlayWithIdentifier:error:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(groundOverlayWithIdentifier:error:)", api); + NSCAssert([api respondsToSelector:@selector(groundOverlayWithIdentifier:error:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to " + @"@selector(groundOverlayWithIdentifier:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_groundOverlayId = GetNullableObjectAtIndex(args, 0); FlutterError *error; - FGMPlatformGroundOverlay *output = [api groundOverlayWithIdentifier:arg_groundOverlayId error:&error]; + FGMPlatformGroundOverlay *output = [api groundOverlayWithIdentifier:arg_groundOverlayId + error:&error]; callback(wrapResult(output, error)); }]; } else { @@ -2884,13 +3210,18 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getHeatmapInfo", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.getHeatmapInfo", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(heatmapWithIdentifier:error:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(heatmapWithIdentifier:error:)", api); + NSCAssert([api respondsToSelector:@selector(heatmapWithIdentifier:error:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to " + @"@selector(heatmapWithIdentifier:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_heatmapId = GetNullableObjectAtIndex(args, 0); @@ -2903,13 +3234,16 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getZoomRange", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.getZoomRange", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(zoomRange:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(zoomRange:)", api); + NSCAssert([api respondsToSelector:@selector(zoomRange:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(zoomRange:)", api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { FlutterError *error; FGMPlatformZoomRange *output = [api zoomRange:&error]; @@ -2920,18 +3254,24 @@ void SetUpFGMMapsInspectorApiWithSuffix(id binaryMesseng } } { - FlutterBasicMessageChannel *channel = - [[FlutterBasicMessageChannel alloc] - initWithName:[NSString stringWithFormat:@"%@%@", @"dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getClusters", messageChannelSuffix] + FlutterBasicMessageChannel *channel = [[FlutterBasicMessageChannel alloc] + initWithName:[NSString stringWithFormat:@"%@%@", + @"dev.flutter.pigeon.google_maps_flutter_ios." + @"MapsInspectorApi.getClusters", + messageChannelSuffix] binaryMessenger:binaryMessenger - codec:FGMGetMessagesCodec()]; + codec:FGMGetMessagesCodec()]; if (api) { - NSCAssert([api respondsToSelector:@selector(clustersWithIdentifier:error:)], @"FGMMapsInspectorApi api (%@) doesn't respond to @selector(clustersWithIdentifier:error:)", api); + NSCAssert([api respondsToSelector:@selector(clustersWithIdentifier:error:)], + @"FGMMapsInspectorApi api (%@) doesn't respond to " + @"@selector(clustersWithIdentifier:error:)", + api); [channel setMessageHandler:^(id _Nullable message, FlutterReply callback) { NSArray *args = message; NSString *arg_clusterManagerId = GetNullableObjectAtIndex(args, 0); FlutterError *error; - NSArray *output = [api clustersWithIdentifier:arg_clusterManagerId error:&error]; + NSArray *output = [api clustersWithIdentifier:arg_clusterManagerId + error:&error]; callback(wrapResult(output, error)); }]; } else { diff --git a/packages/google_maps_flutter/google_maps_flutter_ios/lib/src/messages.g.dart b/packages/google_maps_flutter/google_maps_flutter_ios/lib/src/messages.g.dart index 30c71049fbb1..a8745d31afc0 100644 --- a/packages/google_maps_flutter/google_maps_flutter_ios/lib/src/messages.g.dart +++ b/packages/google_maps_flutter/google_maps_flutter_ios/lib/src/messages.g.dart @@ -18,7 +18,8 @@ PlatformException _createConnectionError(String channelName) { ); } -List wrapResponse({Object? result, PlatformException? error, bool empty = false}) { +List wrapResponse( + {Object? result, PlatformException? error, bool empty = false}) { if (empty) { return []; } @@ -1066,9 +1067,12 @@ class PlatformMapViewCreationParams { initialPolygons: (result[4] as List?)!.cast(), initialPolylines: (result[5] as List?)!.cast(), initialHeatmaps: (result[6] as List?)!.cast(), - initialTileOverlays: (result[7] as List?)!.cast(), - initialClusterManagers: (result[8] as List?)!.cast(), - initialGroundOverlays: (result[9] as List?)!.cast(), + initialTileOverlays: + (result[7] as List?)!.cast(), + initialClusterManagers: + (result[8] as List?)!.cast(), + initialGroundOverlays: + (result[9] as List?)!.cast(), ); } } @@ -1516,7 +1520,6 @@ class PlatformBitmapBytesMap { } } - class _PigeonCodec extends StandardMessageCodec { const _PigeonCodec(); @override @@ -1524,133 +1527,133 @@ class _PigeonCodec extends StandardMessageCodec { if (value is int) { buffer.putUint8(4); buffer.putInt64(value); - } else if (value is PlatformMapType) { + } else if (value is PlatformMapType) { buffer.putUint8(129); writeValue(buffer, value.index); - } else if (value is PlatformJointType) { + } else if (value is PlatformJointType) { buffer.putUint8(130); writeValue(buffer, value.index); - } else if (value is PlatformPatternItemType) { + } else if (value is PlatformPatternItemType) { buffer.putUint8(131); writeValue(buffer, value.index); - } else if (value is PlatformMapBitmapScaling) { + } else if (value is PlatformMapBitmapScaling) { buffer.putUint8(132); writeValue(buffer, value.index); - } else if (value is PlatformCameraPosition) { + } else if (value is PlatformCameraPosition) { buffer.putUint8(133); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdate) { + } else if (value is PlatformCameraUpdate) { buffer.putUint8(134); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateNewCameraPosition) { + } else if (value is PlatformCameraUpdateNewCameraPosition) { buffer.putUint8(135); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateNewLatLng) { + } else if (value is PlatformCameraUpdateNewLatLng) { buffer.putUint8(136); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateNewLatLngBounds) { + } else if (value is PlatformCameraUpdateNewLatLngBounds) { buffer.putUint8(137); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateNewLatLngZoom) { + } else if (value is PlatformCameraUpdateNewLatLngZoom) { buffer.putUint8(138); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateScrollBy) { + } else if (value is PlatformCameraUpdateScrollBy) { buffer.putUint8(139); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateZoomBy) { + } else if (value is PlatformCameraUpdateZoomBy) { buffer.putUint8(140); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateZoom) { + } else if (value is PlatformCameraUpdateZoom) { buffer.putUint8(141); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraUpdateZoomTo) { + } else if (value is PlatformCameraUpdateZoomTo) { buffer.putUint8(142); writeValue(buffer, value.encode()); - } else if (value is PlatformCircle) { + } else if (value is PlatformCircle) { buffer.putUint8(143); writeValue(buffer, value.encode()); - } else if (value is PlatformHeatmap) { + } else if (value is PlatformHeatmap) { buffer.putUint8(144); writeValue(buffer, value.encode()); - } else if (value is PlatformInfoWindow) { + } else if (value is PlatformInfoWindow) { buffer.putUint8(145); writeValue(buffer, value.encode()); - } else if (value is PlatformCluster) { + } else if (value is PlatformCluster) { buffer.putUint8(146); writeValue(buffer, value.encode()); - } else if (value is PlatformClusterManager) { + } else if (value is PlatformClusterManager) { buffer.putUint8(147); writeValue(buffer, value.encode()); - } else if (value is PlatformMarker) { + } else if (value is PlatformMarker) { buffer.putUint8(148); writeValue(buffer, value.encode()); - } else if (value is PlatformPolygon) { + } else if (value is PlatformPolygon) { buffer.putUint8(149); writeValue(buffer, value.encode()); - } else if (value is PlatformPolyline) { + } else if (value is PlatformPolyline) { buffer.putUint8(150); writeValue(buffer, value.encode()); - } else if (value is PlatformPatternItem) { + } else if (value is PlatformPatternItem) { buffer.putUint8(151); writeValue(buffer, value.encode()); - } else if (value is PlatformTile) { + } else if (value is PlatformTile) { buffer.putUint8(152); writeValue(buffer, value.encode()); - } else if (value is PlatformTileOverlay) { + } else if (value is PlatformTileOverlay) { buffer.putUint8(153); writeValue(buffer, value.encode()); - } else if (value is PlatformEdgeInsets) { + } else if (value is PlatformEdgeInsets) { buffer.putUint8(154); writeValue(buffer, value.encode()); - } else if (value is PlatformLatLng) { + } else if (value is PlatformLatLng) { buffer.putUint8(155); writeValue(buffer, value.encode()); - } else if (value is PlatformLatLngBounds) { + } else if (value is PlatformLatLngBounds) { buffer.putUint8(156); writeValue(buffer, value.encode()); - } else if (value is PlatformCameraTargetBounds) { + } else if (value is PlatformCameraTargetBounds) { buffer.putUint8(157); writeValue(buffer, value.encode()); - } else if (value is PlatformGroundOverlay) { + } else if (value is PlatformGroundOverlay) { buffer.putUint8(158); writeValue(buffer, value.encode()); - } else if (value is PlatformMapViewCreationParams) { + } else if (value is PlatformMapViewCreationParams) { buffer.putUint8(159); writeValue(buffer, value.encode()); - } else if (value is PlatformMapConfiguration) { + } else if (value is PlatformMapConfiguration) { buffer.putUint8(160); writeValue(buffer, value.encode()); - } else if (value is PlatformPoint) { + } else if (value is PlatformPoint) { buffer.putUint8(161); writeValue(buffer, value.encode()); - } else if (value is PlatformSize) { + } else if (value is PlatformSize) { buffer.putUint8(162); writeValue(buffer, value.encode()); - } else if (value is PlatformTileLayer) { + } else if (value is PlatformTileLayer) { buffer.putUint8(163); writeValue(buffer, value.encode()); - } else if (value is PlatformZoomRange) { + } else if (value is PlatformZoomRange) { buffer.putUint8(164); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmap) { + } else if (value is PlatformBitmap) { buffer.putUint8(165); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmapDefaultMarker) { + } else if (value is PlatformBitmapDefaultMarker) { buffer.putUint8(166); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmapBytes) { + } else if (value is PlatformBitmapBytes) { buffer.putUint8(167); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmapAsset) { + } else if (value is PlatformBitmapAsset) { buffer.putUint8(168); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmapAssetImage) { + } else if (value is PlatformBitmapAssetImage) { buffer.putUint8(169); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmapAssetMap) { + } else if (value is PlatformBitmapAssetMap) { buffer.putUint8(170); writeValue(buffer, value.encode()); - } else if (value is PlatformBitmapBytesMap) { + } else if (value is PlatformBitmapBytesMap) { buffer.putUint8(171); writeValue(buffer, value.encode()); } else { @@ -1661,95 +1664,95 @@ class _PigeonCodec extends StandardMessageCodec { @override Object? readValueOfType(int type, ReadBuffer buffer) { switch (type) { - case 129: + case 129: final int? value = readValue(buffer) as int?; return value == null ? null : PlatformMapType.values[value]; - case 130: + case 130: final int? value = readValue(buffer) as int?; return value == null ? null : PlatformJointType.values[value]; - case 131: + case 131: final int? value = readValue(buffer) as int?; return value == null ? null : PlatformPatternItemType.values[value]; - case 132: + case 132: final int? value = readValue(buffer) as int?; return value == null ? null : PlatformMapBitmapScaling.values[value]; - case 133: + case 133: return PlatformCameraPosition.decode(readValue(buffer)!); - case 134: + case 134: return PlatformCameraUpdate.decode(readValue(buffer)!); - case 135: + case 135: return PlatformCameraUpdateNewCameraPosition.decode(readValue(buffer)!); - case 136: + case 136: return PlatformCameraUpdateNewLatLng.decode(readValue(buffer)!); - case 137: + case 137: return PlatformCameraUpdateNewLatLngBounds.decode(readValue(buffer)!); - case 138: + case 138: return PlatformCameraUpdateNewLatLngZoom.decode(readValue(buffer)!); - case 139: + case 139: return PlatformCameraUpdateScrollBy.decode(readValue(buffer)!); - case 140: + case 140: return PlatformCameraUpdateZoomBy.decode(readValue(buffer)!); - case 141: + case 141: return PlatformCameraUpdateZoom.decode(readValue(buffer)!); - case 142: + case 142: return PlatformCameraUpdateZoomTo.decode(readValue(buffer)!); - case 143: + case 143: return PlatformCircle.decode(readValue(buffer)!); - case 144: + case 144: return PlatformHeatmap.decode(readValue(buffer)!); - case 145: + case 145: return PlatformInfoWindow.decode(readValue(buffer)!); - case 146: + case 146: return PlatformCluster.decode(readValue(buffer)!); - case 147: + case 147: return PlatformClusterManager.decode(readValue(buffer)!); - case 148: + case 148: return PlatformMarker.decode(readValue(buffer)!); - case 149: + case 149: return PlatformPolygon.decode(readValue(buffer)!); - case 150: + case 150: return PlatformPolyline.decode(readValue(buffer)!); - case 151: + case 151: return PlatformPatternItem.decode(readValue(buffer)!); - case 152: + case 152: return PlatformTile.decode(readValue(buffer)!); - case 153: + case 153: return PlatformTileOverlay.decode(readValue(buffer)!); - case 154: + case 154: return PlatformEdgeInsets.decode(readValue(buffer)!); - case 155: + case 155: return PlatformLatLng.decode(readValue(buffer)!); - case 156: + case 156: return PlatformLatLngBounds.decode(readValue(buffer)!); - case 157: + case 157: return PlatformCameraTargetBounds.decode(readValue(buffer)!); - case 158: + case 158: return PlatformGroundOverlay.decode(readValue(buffer)!); - case 159: + case 159: return PlatformMapViewCreationParams.decode(readValue(buffer)!); - case 160: + case 160: return PlatformMapConfiguration.decode(readValue(buffer)!); - case 161: + case 161: return PlatformPoint.decode(readValue(buffer)!); - case 162: + case 162: return PlatformSize.decode(readValue(buffer)!); - case 163: + case 163: return PlatformTileLayer.decode(readValue(buffer)!); - case 164: + case 164: return PlatformZoomRange.decode(readValue(buffer)!); - case 165: + case 165: return PlatformBitmap.decode(readValue(buffer)!); - case 166: + case 166: return PlatformBitmapDefaultMarker.decode(readValue(buffer)!); - case 167: + case 167: return PlatformBitmapBytes.decode(readValue(buffer)!); - case 168: + case 168: return PlatformBitmapAsset.decode(readValue(buffer)!); - case 169: + case 169: return PlatformBitmapAssetImage.decode(readValue(buffer)!); - case 170: + case 170: return PlatformBitmapAssetMap.decode(readValue(buffer)!); - case 171: + case 171: return PlatformBitmapBytesMap.decode(readValue(buffer)!); default: return super.readValueOfType(type, buffer); @@ -1766,7 +1769,8 @@ class MapsApi { /// BinaryMessenger will be used which routes to the host platform. MapsApi({BinaryMessenger? binaryMessenger, String messageChannelSuffix = ''}) : pigeonVar_binaryMessenger = binaryMessenger, - pigeonVar_messageChannelSuffix = messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; + pigeonVar_messageChannelSuffix = + messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; final BinaryMessenger? pigeonVar_binaryMessenger; static const MessageCodec pigeonChannelCodec = _PigeonCodec(); @@ -1775,8 +1779,10 @@ class MapsApi { /// Returns once the map instance is available. Future waitForMap() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.waitForMap$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.waitForMap$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -1800,15 +1806,18 @@ class MapsApi { /// /// Only non-null configuration values will result in updates; options with /// null values will remain unchanged. - Future updateMapConfiguration(PlatformMapConfiguration configuration) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMapConfiguration$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + Future updateMapConfiguration( + PlatformMapConfiguration configuration) async { + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMapConfiguration$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([configuration]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([configuration]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1823,15 +1832,18 @@ class MapsApi { } /// Updates the set of circles on the map. - Future updateCircles(List toAdd, List toChange, List idsToRemove) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateCircles$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + Future updateCircles(List toAdd, + List toChange, List idsToRemove) async { + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateCircles$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1846,15 +1858,18 @@ class MapsApi { } /// Updates the set of heatmaps on the map. - Future updateHeatmaps(List toAdd, List toChange, List idsToRemove) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateHeatmaps$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + Future updateHeatmaps(List toAdd, + List toChange, List idsToRemove) async { + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateHeatmaps$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1869,15 +1884,18 @@ class MapsApi { } /// Updates the set of custer managers for clusters on the map. - Future updateClusterManagers(List toAdd, List idsToRemove) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateClusterManagers$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + Future updateClusterManagers( + List toAdd, List idsToRemove) async { + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateClusterManagers$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([toAdd, idsToRemove]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([toAdd, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1892,15 +1910,18 @@ class MapsApi { } /// Updates the set of markers on the map. - Future updateMarkers(List toAdd, List toChange, List idsToRemove) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMarkers$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + Future updateMarkers(List toAdd, + List toChange, List idsToRemove) async { + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateMarkers$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1915,15 +1936,18 @@ class MapsApi { } /// Updates the set of polygonss on the map. - Future updatePolygons(List toAdd, List toChange, List idsToRemove) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updatePolygons$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + Future updatePolygons(List toAdd, + List toChange, List idsToRemove) async { + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updatePolygons$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1938,15 +1962,18 @@ class MapsApi { } /// Updates the set of polylines on the map. - Future updatePolylines(List toAdd, List toChange, List idsToRemove) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updatePolylines$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + Future updatePolylines(List toAdd, + List toChange, List idsToRemove) async { + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updatePolylines$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1961,15 +1988,18 @@ class MapsApi { } /// Updates the set of tile overlays on the map. - Future updateTileOverlays(List toAdd, List toChange, List idsToRemove) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateTileOverlays$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + Future updateTileOverlays(List toAdd, + List toChange, List idsToRemove) async { + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateTileOverlays$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -1984,15 +2014,18 @@ class MapsApi { } /// Updates the set of ground overlays on the map. - Future updateGroundOverlays(List toAdd, List toChange, List idsToRemove) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateGroundOverlays$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + Future updateGroundOverlays(List toAdd, + List toChange, List idsToRemove) async { + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.updateGroundOverlays$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([toAdd, toChange, idsToRemove]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([toAdd, toChange, idsToRemove]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -2008,8 +2041,10 @@ class MapsApi { /// Gets the screen coordinate for the given map location. Future getScreenCoordinate(PlatformLatLng latLng) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getScreenCoordinate$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getScreenCoordinate$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2036,14 +2071,16 @@ class MapsApi { /// Gets the map location for the given screen coordinate. Future getLatLng(PlatformPoint screenCoordinate) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLatLng$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLatLng$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([screenCoordinate]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([screenCoordinate]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -2064,8 +2101,10 @@ class MapsApi { /// Gets the map region currently displayed on the map. Future getVisibleRegion() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getVisibleRegion$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getVisibleRegion$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2093,8 +2132,10 @@ class MapsApi { /// Moves the camera according to [cameraUpdate] immediately, with no /// animation. Future moveCamera(PlatformCameraUpdate cameraUpdate) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.moveCamera$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.moveCamera$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2116,8 +2157,10 @@ class MapsApi { /// Moves the camera according to [cameraUpdate], animating the update. Future animateCamera(PlatformCameraUpdate cameraUpdate) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.animateCamera$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.animateCamera$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2139,8 +2182,10 @@ class MapsApi { /// Gets the current map zoom level. Future getZoomLevel() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getZoomLevel$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getZoomLevel$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2167,8 +2212,10 @@ class MapsApi { /// Show the info window for the marker with the given ID. Future showInfoWindow(String markerId) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.showInfoWindow$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.showInfoWindow$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2190,8 +2237,10 @@ class MapsApi { /// Hide the info window for the marker with the given ID. Future hideInfoWindow(String markerId) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.hideInfoWindow$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.hideInfoWindow$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2214,8 +2263,10 @@ class MapsApi { /// Returns true if the marker with the given ID is currently displaying its /// info window. Future isInfoWindowShown(String markerId) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.isInfoWindowShown$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.isInfoWindowShown$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2246,8 +2297,10 @@ class MapsApi { /// If there was an error setting the style, such as an invalid style string, /// returns the error message. Future setStyle(String style) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.setStyle$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.setStyle$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2273,8 +2326,10 @@ class MapsApi { /// This allows checking asynchronously for initial style failures, as there /// is no way to return failures from map initialization. Future getLastStyleError() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLastStyleError$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.getLastStyleError$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2296,14 +2351,16 @@ class MapsApi { /// Clears the cache of tiles previously requseted from the tile provider. Future clearTileCache(String tileOverlayId) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.clearTileCache$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.clearTileCache$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([tileOverlayId]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([tileOverlayId]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -2319,8 +2376,10 @@ class MapsApi { /// Takes a snapshot of the map and returns its image data. Future takeSnapshot() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.takeSnapshot$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsApi.takeSnapshot$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2391,13 +2450,22 @@ abstract class MapsCallbackApi { void onGroundOverlayTap(String groundOverlayId); /// Called to get data for a map tile. - Future getTileOverlayTile(String tileOverlayId, PlatformPoint location, int zoom); - - static void setUp(MapsCallbackApi? api, {BinaryMessenger? binaryMessenger, String messageChannelSuffix = '',}) { - messageChannelSuffix = messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; + Future getTileOverlayTile( + String tileOverlayId, PlatformPoint location, int zoom); + + static void setUp( + MapsCallbackApi? api, { + BinaryMessenger? binaryMessenger, + String messageChannelSuffix = '', + }) { + messageChannelSuffix = + messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMoveStarted$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMoveStarted$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); @@ -2408,24 +2476,29 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove was null.'); final List args = (message as List?)!; - final PlatformCameraPosition? arg_cameraPosition = (args[0] as PlatformCameraPosition?); + final PlatformCameraPosition? arg_cameraPosition = + (args[0] as PlatformCameraPosition?); assert(arg_cameraPosition != null, 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraMove was null, expected non-null PlatformCameraPosition.'); try { @@ -2433,15 +2506,19 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraIdle$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCameraIdle$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); @@ -2452,22 +2529,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onTap$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onTap$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onTap was null.'); final List args = (message as List?)!; final PlatformLatLng? arg_position = (args[0] as PlatformLatLng?); assert(arg_position != null, @@ -2477,22 +2558,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onLongPress$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onLongPress$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onLongPress was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onLongPress was null.'); final List args = (message as List?)!; final PlatformLatLng? arg_position = (args[0] as PlatformLatLng?); assert(arg_position != null, @@ -2502,22 +2587,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerTap$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerTap$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerTap was null.'); final List args = (message as List?)!; final String? arg_markerId = (args[0] as String?); assert(arg_markerId != null, @@ -2527,22 +2616,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragStart$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragStart$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragStart was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragStart was null.'); final List args = (message as List?)!; final String? arg_markerId = (args[0] as String?); assert(arg_markerId != null, @@ -2555,22 +2648,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDrag$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDrag$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDrag was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDrag was null.'); final List args = (message as List?)!; final String? arg_markerId = (args[0] as String?); assert(arg_markerId != null, @@ -2583,22 +2680,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragEnd$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragEnd$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragEnd was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onMarkerDragEnd was null.'); final List args = (message as List?)!; final String? arg_markerId = (args[0] as String?); assert(arg_markerId != null, @@ -2611,22 +2712,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onInfoWindowTap$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onInfoWindowTap$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onInfoWindowTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onInfoWindowTap was null.'); final List args = (message as List?)!; final String? arg_markerId = (args[0] as String?); assert(arg_markerId != null, @@ -2636,22 +2741,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCircleTap$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCircleTap$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCircleTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onCircleTap was null.'); final List args = (message as List?)!; final String? arg_circleId = (args[0] as String?); assert(arg_circleId != null, @@ -2661,22 +2770,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onClusterTap$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onClusterTap$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onClusterTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onClusterTap was null.'); final List args = (message as List?)!; final PlatformCluster? arg_cluster = (args[0] as PlatformCluster?); assert(arg_cluster != null, @@ -2686,22 +2799,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolygonTap$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolygonTap$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolygonTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolygonTap was null.'); final List args = (message as List?)!; final String? arg_polygonId = (args[0] as String?); assert(arg_polygonId != null, @@ -2711,22 +2828,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolylineTap$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolylineTap$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolylineTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onPolylineTap was null.'); final List args = (message as List?)!; final String? arg_polylineId = (args[0] as String?); assert(arg_polylineId != null, @@ -2736,22 +2857,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onGroundOverlayTap$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onGroundOverlayTap$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onGroundOverlayTap was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.onGroundOverlayTap was null.'); final List args = (message as List?)!; final String? arg_groundOverlayId = (args[0] as String?); assert(arg_groundOverlayId != null, @@ -2761,22 +2886,26 @@ abstract class MapsCallbackApi { return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } } { - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile$messageChannelSuffix', pigeonChannelCodec, + final BasicMessageChannel< + Object?> pigeonVar_channel = BasicMessageChannel< + Object?>( + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile$messageChannelSuffix', + pigeonChannelCodec, binaryMessenger: binaryMessenger); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { assert(message != null, - 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile was null.'); + 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile was null.'); final List args = (message as List?)!; final String? arg_tileOverlayId = (args[0] as String?); assert(arg_tileOverlayId != null, @@ -2788,12 +2917,14 @@ abstract class MapsCallbackApi { assert(arg_zoom != null, 'Argument for dev.flutter.pigeon.google_maps_flutter_ios.MapsCallbackApi.getTileOverlayTile was null, expected non-null int.'); try { - final PlatformTile output = await api.getTileOverlayTile(arg_tileOverlayId!, arg_location!, arg_zoom!); + final PlatformTile output = await api.getTileOverlayTile( + arg_tileOverlayId!, arg_location!, arg_zoom!); return wrapResponse(result: output); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString())); } }); } @@ -2808,9 +2939,11 @@ class MapsPlatformViewApi { /// Constructor for [MapsPlatformViewApi]. The [binaryMessenger] named argument is /// available for dependency injection. If it is left null, the default /// BinaryMessenger will be used which routes to the host platform. - MapsPlatformViewApi({BinaryMessenger? binaryMessenger, String messageChannelSuffix = ''}) + MapsPlatformViewApi( + {BinaryMessenger? binaryMessenger, String messageChannelSuffix = ''}) : pigeonVar_binaryMessenger = binaryMessenger, - pigeonVar_messageChannelSuffix = messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; + pigeonVar_messageChannelSuffix = + messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; final BinaryMessenger? pigeonVar_binaryMessenger; static const MessageCodec pigeonChannelCodec = _PigeonCodec(); @@ -2818,8 +2951,10 @@ class MapsPlatformViewApi { final String pigeonVar_messageChannelSuffix; Future createView(PlatformMapViewCreationParams? type) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsPlatformViewApi.createView$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsPlatformViewApi.createView$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2845,9 +2980,11 @@ class MapsInspectorApi { /// Constructor for [MapsInspectorApi]. The [binaryMessenger] named argument is /// available for dependency injection. If it is left null, the default /// BinaryMessenger will be used which routes to the host platform. - MapsInspectorApi({BinaryMessenger? binaryMessenger, String messageChannelSuffix = ''}) + MapsInspectorApi( + {BinaryMessenger? binaryMessenger, String messageChannelSuffix = ''}) : pigeonVar_binaryMessenger = binaryMessenger, - pigeonVar_messageChannelSuffix = messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; + pigeonVar_messageChannelSuffix = + messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; final BinaryMessenger? pigeonVar_binaryMessenger; static const MessageCodec pigeonChannelCodec = _PigeonCodec(); @@ -2855,8 +2992,10 @@ class MapsInspectorApi { final String pigeonVar_messageChannelSuffix; Future areBuildingsEnabled() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areBuildingsEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areBuildingsEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2882,8 +3021,10 @@ class MapsInspectorApi { } Future areRotateGesturesEnabled() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areRotateGesturesEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areRotateGesturesEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2909,8 +3050,10 @@ class MapsInspectorApi { } Future areScrollGesturesEnabled() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areScrollGesturesEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areScrollGesturesEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2936,8 +3079,10 @@ class MapsInspectorApi { } Future areTiltGesturesEnabled() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areTiltGesturesEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areTiltGesturesEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2963,8 +3108,10 @@ class MapsInspectorApi { } Future areZoomGesturesEnabled() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areZoomGesturesEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.areZoomGesturesEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -2990,8 +3137,10 @@ class MapsInspectorApi { } Future isCompassEnabled() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isCompassEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isCompassEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3017,8 +3166,10 @@ class MapsInspectorApi { } Future isMyLocationButtonEnabled() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isMyLocationButtonEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isMyLocationButtonEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3044,8 +3195,10 @@ class MapsInspectorApi { } Future isTrafficEnabled() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isTrafficEnabled$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.isTrafficEnabled$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3071,14 +3224,16 @@ class MapsInspectorApi { } Future getTileOverlayInfo(String tileOverlayId) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getTileOverlayInfo$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getTileOverlayInfo$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([tileOverlayId]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([tileOverlayId]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -3092,15 +3247,18 @@ class MapsInspectorApi { } } - Future getGroundOverlayInfo(String groundOverlayId) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getGroundOverlayInfo$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + Future getGroundOverlayInfo( + String groundOverlayId) async { + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getGroundOverlayInfo$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([groundOverlayId]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([groundOverlayId]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -3115,8 +3273,10 @@ class MapsInspectorApi { } Future getHeatmapInfo(String heatmapId) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getHeatmapInfo$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getHeatmapInfo$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3137,8 +3297,10 @@ class MapsInspectorApi { } Future getZoomRange() async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getZoomRange$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getZoomRange$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, @@ -3164,14 +3326,16 @@ class MapsInspectorApi { } Future> getClusters(String clusterManagerId) async { - final String pigeonVar_channelName = 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getClusters$pigeonVar_messageChannelSuffix'; - final BasicMessageChannel pigeonVar_channel = BasicMessageChannel( + final String pigeonVar_channelName = + 'dev.flutter.pigeon.google_maps_flutter_ios.MapsInspectorApi.getClusters$pigeonVar_messageChannelSuffix'; + final BasicMessageChannel pigeonVar_channel = + BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final List? pigeonVar_replyList = - await pigeonVar_channel.send([clusterManagerId]) as List?; + final List? pigeonVar_replyList = await pigeonVar_channel + .send([clusterManagerId]) as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); } else if (pigeonVar_replyList.length > 1) { @@ -3186,7 +3350,8 @@ class MapsInspectorApi { message: 'Host platform returned null value for non-null return value.', ); } else { - return (pigeonVar_replyList[0] as List?)!.cast(); + return (pigeonVar_replyList[0] as List?)! + .cast(); } } }