Esempio n. 1
0
 public WindowsPackage(DismPackage pkg)
 {
     this._packageName  = pkg.PackageName;
     this._packageState = pkg.PackageState;
     this._releaseType  = pkg.ReleaseType;
     this._installTime  = pkg.InstallTime.ToDateTime();
 }
Esempio n. 2
0
 public WindowsFeature(DismFeatureInfo feature)
 {
     this._featureName      = feature.FeatureName;
     this._featureState     = feature.FeatureState;
     this._displayName      = feature.DisplayName;
     this._description      = feature.Description;
     this._restartRequired  = feature.RestartRequired;
     this._customProperties = Utilites.PtrToArray <DismCustomProperty>(
         feature.CustomProperty,
         feature.CustomPropertyCount
         ).ToDictionary(
         f => string.Format("{0}\\{1}", f.Path, f.Name),
         f => f.Value
         );
 }
Esempio n. 3
0
 public WindowsPackage(DismPackageInfo pkg)
 {
     this._packageName        = pkg.PackageName;
     this._packageState       = pkg.PackageState;
     this._releaseType        = pkg.ReleaseType;
     this._installTime        = pkg.InstallTime.ToDateTime();
     this._applicable         = pkg.Applicable;
     this._copyright          = pkg.Copyright;
     this._company            = pkg.Company;
     this._creationTime       = pkg.CreationTime.ToDateTime();
     this._displayName        = pkg.DisplayName;
     this._description        = pkg.Description;
     this._installClient      = pkg.InstallClient;
     this._installPackageName = pkg.InstallPackageName;
     this._lastUpdatedTime    = pkg.LastUpdateTime.ToDateTime();
     this._productName        = pkg.ProductName;
     this._productVersion     = pkg.ProductVersion;
     this._restartRequired    = pkg.RestartRequired;
     this._fullyOffline       = pkg.FullyOffline;
     this._supportInformation = pkg.SupportInformation;
     this._customProperties   =
         Utilites.PtrToArray <DismCustomProperty>(
             pkg.CustomProperty,
             pkg.CustomPropertyCount
             ).ToDictionary(
             p => string.Format("{0}\\{1}", p.Path, p.Name),
             p => p.Value
             );
     this._features = new Collection <WindowsFeature>(
         Utilites.PtrToArray <DismFeature>(
             pkg.Feature,
             pkg.FeatureCount
             )
         .Select(f => new WindowsFeature(f))
         .ToList()
         );
 }
Esempio n. 4
0
 public WindowsFeature(DismFeature feature)
 {
     this._featureName  = feature.FeatureName;
     this._featureState = feature.State;
 }