getResourcePath method

Future<String?> getResourcePath()

Get the resource path.

This verb should probably not be here...

Implementation

Future<String?> getResourcePath() async {
  await _waitOpen();
  if (!_isInited) {
    throw Exception('Player is not open');
  }
  if (kIsWeb) {
    return null;
  } else if (Platform.isIOS) {
    var s = await TauPlayerPlatform.instance.getResourcePath(this);
    return s;
  } else {
    return (await getApplicationDocumentsDirectory()).path;
  }
}