get static method
Implementation
static Future<List<DGDirectLinkModel>> get({required String url}) async {
if (url.contains('http://') || url.contains('https://')) {
if (url.contains('ok.ru')) {
return OkRu.get(url);
} else if (url.contains('dropbox.com')) {
return DropBox.get(url);
} else if (url.contains('solidfiles')) {
return SolidFiles.get(url);
} else if (url.contains('drive.google.com')) {
return GoogleDrive.get(url);
} else if (url.contains('fembed.com')) {
return FEmbedFiles.get(url);
} else if (url.contains('youtube.com') ||
url.contains('youtu.be') ||
url.contains('fb.com') ||
url.contains('facebook.com')) {
return SocialDownloader.get(url);
} else if (url.contains('www.mediafire.com')) {
return MediaFire.get(url);
} else if (url.contains('xnxx')) {
return XNXX.get(url);
} else if (url.contains('vk.com')) {
return VK.get(url);
} else {
List<DGDirectLinkModel> links = [];
links.add(DGDirectLinkModel(quality: 'Normal', link: url));
return links;
}
} else {
if (kDebugMode) {
print('Only support http and https');
}
List<DGDirectLinkModel> links = [];
links.add(DGDirectLinkModel(quality: 'Normal', link: url));
return links;
}
}