flutter_smartscan_plugin_platform_interface.dart 1.1 KB

12345678910111213141516171819202122232425262728293031
  1. import 'package:plugin_platform_interface/plugin_platform_interface.dart';
  2. import 'plugin_method_channel_native.dart'
  3. if (dart.library.html) 'plugin_method_channel_web';
  4. abstract class FlutterSmartscanPluginPlatform extends PlatformInterface {
  5. /// Constructs a FlutterSmartscanPluginPlatform.
  6. FlutterSmartscanPluginPlatform() : super(token: _token);
  7. static final Object _token = Object();
  8. static FlutterSmartscanPluginPlatform _instance =
  9. MethodChannelFlutterSmartscanPlugin();
  10. /// The default instance of [FlutterSmartscanPluginPlatform] to use.
  11. ///
  12. /// Defaults to [MethodChannelFlutterSmartscanPlugin].
  13. static FlutterSmartscanPluginPlatform get instance => _instance;
  14. /// Platform-specific implementations should set this with their own
  15. /// platform-specific class that extends [FlutterSmartscanPluginPlatform] when
  16. /// they register themselves.
  17. static set instance(FlutterSmartscanPluginPlatform instance) {
  18. PlatformInterface.verifyToken(instance, _token);
  19. _instance = instance;
  20. }
  21. Future<String?> getPlatformVersion() {
  22. throw UnimplementedError('platformVersion() has not been implemented.');
  23. }
  24. }