using System;
using System.Security.Cryptography;
using System.Text;

namespace IRaCIS.Core.Infrastructure
{
    public static class IdentifierHelper
    {
        private static MD5 md5 = MD5.Create();

        private static object lockObj = new object();

        public static Guid CreateGuid(params string[] parts)
        {
            lock (lockObj)
            {
                return new Guid(md5.ComputeHash(Encoding.UTF8.GetBytes(string.Concat(parts))));
            }

        }
    }
}
