Пример #1
0
        /// <exception cref="System.InvalidOperationException">Thrown when either Download Link or Output path is empty</exception>
        public CompletionResult Download(DownloadInfo info)
        {
            Reporter = info.DownloadReporter;

            if (string.IsNullOrEmpty(info.DownloadLink))
            {
                throw new InvalidOperationException("Download Link cannot be empty");
            }

            if (string.IsNullOrEmpty(info.OutputPath))
            {
                throw new InvalidOperationException("Output Path cannot be empty");
            }

            return(DownloadImpDefault(info));
        }
Пример #2
0
 protected abstract CompletionResult DownloadImpDefault(DownloadInfo info);