Exemplo n.º 1
0
        public String GetChecksum(string path, string algorithm)
        {
            string         fullPath = Project.GetFullPath(path);
            ChecksumHelper helper   = new ChecksumHelper(algorithm);

            return(helper.CalculateChecksum(fullPath));
        }
Exemplo n.º 2
0
        /// <summary>
        /// This is where the work is done
        /// </summary>
        protected override void ExecuteTask()
        {
            ChecksumHelper helper = new ChecksumHelper(Algorithm);

            foreach (String file in FileSet.FileNames)
            {
                string checksum = helper.CalculateChecksum(file);
                string outfile  = file + "." + FileExtension;

                WriteChecksum(outfile, checksum);
            }
        }