import 'dart:io';

import 'package:plugin_platform_interface/plugin_platform_interface.dart';

import 'system_share_method_channel.dart';

abstract class SystemSharePlatform extends PlatformInterface {
  /// Constructs a SystemSharePlatform.
  SystemSharePlatform() : super(token: _token);

  static final Object _token = Object();

  static SystemSharePlatform _instance = MethodChannelSystemShare();

  /// The default instance of [SystemSharePlatform] to use.
  ///
  /// Defaults to [MethodChannelSystemShare].
  static SystemSharePlatform get instance => _instance;

  /// Platform-specific implementations should set this with their own
  /// platform-specific class that extends [SystemSharePlatform] when
  /// they register themselves.
  static set instance(SystemSharePlatform instance) {
    PlatformInterface.verifyToken(instance, _token);
    _instance = instance;
  }

  Future<bool> isInstalled(String packageName) async {
    throw UnimplementedError('isInstalled() has not been implemented.');
  }

  Future<void> shareFile(
      String filePath, String packageName, String? shareTitle,
      {String? shareFileType}) async {
    throw UnimplementedError('shareFile() has not been implemented.');
  }
}
