Example #1
0
        internal Package(string name, string architecture, UInt64 version, string publicKeyToken, string productCode)
        {
            Name = name;
            Version = version;
            Architecture = architecture;
            PublicKeyToken = publicKeyToken;
            ProductCode = productCode;
            Dependencies.CollectionChanged += (x, y) => Changed();

            _canonicalName = new Lazy<string>(() => "{0}-{1}-{2}-{3}".format(Name, Version.UInt64VersiontoString(), Architecture, PublicKeyToken).ToLowerInvariant());
            _cosmeticName = new Lazy<string>(() => "{0}-{1}-{2}".format(Name, Version.UInt64VersiontoString(), Architecture).ToLowerInvariant());
            _generalName = new Lazy<string>(() => "{0}-{1}".format(Name, PublicKeyToken).ToLowerInvariant());

            Publisher = new Party() {
                Name = string.Empty,
                Url = string.Empty,
                Email = string.Empty
            };

            LoadCachedInfo();
        }