public AssemblyInfo(AssemblyName assemblyName) { Name = assemblyName.Name; Version = assemblyName.Version.ToString(); RuntimeVersion = ""; Platform = assemblyName.ProcessorArchitecture.ToString(); CultureInfo = assemblyName.CultureInfo; PublicKeyToken = assemblyName.GetPublicKeyToken(); if (PublicKeyToken == null || PublicKeyToken.Length == 0) { PublicKeyTokenString = null; } else { PublicKeyTokenString = string.Join(string.Empty, PublicKeyToken.Select(b => b.ToString("X2"))); } }
private string PublicKeyTokenAsString() { return(PublicKeyToken != null ? string.Join(string.Empty, PublicKeyToken.Select(b => b.ToString("x2")).ToArray()) : string.Empty); }