Exemplo n.º 1
0
        protected override void DeserializeElement(System.Xml.XmlReader reader, bool serializeCollectionKey)
        {
            string installerType = reader.GetAttribute("type");

            if (string.IsNullOrEmpty(installerType))
            {
                installerType = InstallerType.msi.ToString();
            }
            InstallerType type = (InstallerType)Enum.Parse(typeof(InstallerType), installerType);

            switch (type)
            {
            case InstallerType.noop:
                _config = new NoopInstallerConfig(_destinationPath, _copyMethod);
                break;

            case InstallerType.dni:
                _config = new DniInstallerConfig(_destinationPath, _copyMethod);
                break;

            case InstallerType.exe:
                _config = new ExeInstallerConfig(_destinationPath, _copyMethod);
                break;

            case InstallerType.msi:
            default:
                _config = new MsiInstallerConfig(_destinationPath, _copyMethod);
                break;
            }

            _config.ProxyDeserializeElement(reader, serializeCollectionKey);
        }
Exemplo n.º 2
0
 public Instance(
     string logpath,
     bool simulationOnly,
     RemoteInstallConfig config,
     VMWareMappedVirtualMachine vm,
     VirtualMachineConfig vmConfig,
     InstallerConfig installerConfig,
     SnapshotConfig snapshotConfig)
 {
     _logpath         = logpath;
     _simulationOnly  = simulationOnly;
     _config          = config;
     _vm              = vm;
     _vmConfig        = vmConfig;
     _installerConfig = installerConfig;
     _snapshotConfig  = snapshotConfig;
 }