google_maps_flutter_platform_interface 1.0.0+4

  • Readme
  • Changelog
  • Installing
  • new54

google_maps_flutter_platform_interface #

A common platform interface for the google_maps_flutter plugin.

This interface allows platform-specific implementations of the google_maps_flutter plugin, as well as the plugin itself, to ensure they are supporting the same interface.

Usage #

To implement a new platform-specific implementation of google_maps_flutter, extend GoogleMapsFlutterPlatform with an implementation that performs the platform-specific behavior, and when you register your plugin, set the default GoogleMapsFlutterPlatform by calling GoogleMapsFlutterPlatform.instance = MyPlatformGoogleMapsFlutter().

Note on breaking changes #

Strongly prefer non-breaking changes (such as adding a method to the interface) over breaking changes for this package.

See for a discussion on why a less-clean interface is preferable to a breaking change.

1.0.0+4 #

  • Add init method and Move MethodChannel code to MethodChannelGoogleMapsFlutter

1.0.0+3 #

  • Clean up format

1.0.0+2 #

  • Add PlatformInterface methods according to GoogleMapsFlutter

1.0.0+1 #

  • Update README

1.0.0 #

  • Initial release.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:

  google_maps_flutter_platform_interface: ^1.0.0+4

2. Install it

You can install packages from the command line:

with Flutter:

$ flutter pub get

Alternatively, your editor might support flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:

import 'package:google_maps_flutter_platform_interface/google_maps_flutter_platform_interface.dart';
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
Learn more about scoring.

We analyzed this package on Mar 27, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.7.1
  • pana: 0.13.6
  • Flutter: 1.12.13+hotfix.8

Health suggestions

Fix lib/google_maps_flutter_platform_interface.dart. (-1.49 points)

Analysis of lib/google_maps_flutter_platform_interface.dart reported 3 hints:

line 6 col 8: Unused import: 'dart:ui'.

line 9 col 8: Unused import: 'package:meta/meta.dart'.

line 61 col 21: This function has a return type of 'MethodChannel', but doesn't end with a return statement.

Maintenance issues and suggestions

Homepage URL doesn't exist. (-20 points)

At the time of the analysis the homepage field was unreachable.

Maintain an example. (-10 points)

Create a short demo in the example/ directory to show how to use this package.

Common filename patterns include main.dart, example.dart, and google_maps_flutter_platform_interface.dart. Packages with multiple examples should provide example/

For more information see the pub package layout conventions.


Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0-dev.28.0 <3.0.0
flutter 0.0.0
meta ^1.0.5 1.1.8
plugin_platform_interface ^1.0.1 1.0.2
Transitive dependencies
collection 1.14.11 1.14.12
sky_engine 0.0.99
typed_data 1.1.6
vector_math 2.0.8
Dev dependencies
mockito ^4.1.1
pedantic ^1.8.0