예제 #1
0
        private void CalculateDownloadLinkIdentifier()
        {
            if (string.IsNullOrEmpty(DownloadLink))
            {
                DownloadLinkIdentifier = string.Empty;
                return;
            }

            var splittedByPath = DownloadLink.Split(new[] { @"/" }, StringSplitOptions.RemoveEmptyEntries);
            var linkIdentifier = splittedByPath.Last();

            DownloadLinkIdentifier = linkIdentifier;
        }
예제 #2
0
        private bool GetId()
        {
            try
            {
                VideoId = (DownloadLink.Split('/'))[8];
                return true;
            }

            catch (Exception e)
            {
                Console.WriteLine(e.Message);
                return false;
            }
            
        }