Class Installer
The Installer class provides a single entrypoint for Package Installation.
Inheritance
Namespace: DotNetNuke.Services.Installer
Assembly: DotNetNuke.dll
Syntax
public class Installer : object
Constructors
| Improve this Doc View SourceInstaller(PackageInfo, String)
Initializes a new instance of the Installer class. This Constructor creates a new Installer instance from a PackageInfo object.
Declaration
public Installer(PackageInfo package, string physicalSitePath)
Parameters
Type | Name | Description |
---|---|---|
PackageInfo | package | The PackageInfo instance. |
System.String | physicalSitePath | The physical path to the root of the site. |
Installer(Stream, String, Boolean, Boolean)
Initializes a new instance of the Installer class. This Constructor creates a new Installer instance from a Stream and a string representing the physical path to the root of the site.
Declaration
public Installer(Stream inputStream, string physicalSitePath, bool loadManifest, bool deleteTemp)
Parameters
Type | Name | Description |
---|---|---|
Stream | inputStream | The Stream to use to create this InstallerInfo instance. |
System.String | physicalSitePath | The physical path to the root of the site. |
System.Boolean | loadManifest | Flag that determines whether the manifest will be loaded. |
System.Boolean | deleteTemp | Whether delete the temp folder. |
Installer(Stream, String, Boolean)
Initializes a new instance of the Installer class. This Constructor creates a new Installer instance from a Stream and a string representing the physical path to the root of the site.
Declaration
public Installer(Stream inputStream, string physicalSitePath, bool loadManifest)
Parameters
Type | Name | Description |
---|---|---|
Stream | inputStream | The Stream to use to create this InstallerInfo instance. |
System.String | physicalSitePath | The physical path to the root of the site. |
System.Boolean | loadManifest | Flag that determines whether the manifest will be loaded. |
Installer(String, String, Boolean)
Initializes a new instance of the Installer class.
Declaration
public Installer(string manifest, string physicalSitePath, bool loadManifest)
Parameters
Type | Name | Description |
---|---|---|
System.String | manifest | The install package manifest. |
System.String | physicalSitePath | The physical path to the site. |
System.Boolean | loadManifest | A value indicating whether to load the manifest. |
Installer(String, String, String, Boolean)
Initializes a new instance of the Installer class. This Constructor creates a new Installer instance from a string representing the physical path to the temporary install folder and a string representing the physical path to the root of the site.
Declaration
public Installer(string tempFolder, string manifest, string physicalSitePath, bool loadManifest)
Parameters
Type | Name | Description |
---|---|---|
System.String | tempFolder | The physical path to the zip file containg the package. |
System.String | manifest | The manifest filename. |
System.String | physicalSitePath | The physical path to the root of the site. |
System.Boolean | loadManifest | Flag that determines whether the manifest will be loaded. |
Properties
| Improve this Doc View SourceInstallerInfo
Gets the associated InstallerInfo object.
Declaration
public InstallerInfo InstallerInfo { get; }
Property Value
Type | Description |
---|---|
InstallerInfo | An InstallerInfo. |
IsValid
Gets a value indicating whether the associated InstallerInfo is valid.
Declaration
public bool IsValid { get; }
Property Value
Type | Description |
---|---|
System.Boolean | True - if valid, False if not. |
Packages
Gets a SortedList of Packages that are included in the Package Zip.
Declaration
public SortedList<int, PackageInstaller> Packages { get; }
Property Value
Type | Description |
---|---|
SortedList<System.Int32, PackageInstaller> | A SortedList(Of Integer, PackageInstaller). |
TempInstallFolder
Gets the installation temporary folder path.
Declaration
public string TempInstallFolder { get; }
Property Value
Type | Description |
---|---|
System.String | The installation temporory folder path. |
Methods
| Improve this Doc View SourceConvertLegacyNavigator(XPathNavigator, InstallerInfo)
Converts legacy manifest navigation to support old manifest format.
Declaration
public static XPathNavigator ConvertLegacyNavigator(XPathNavigator rootNav, InstallerInfo info)
Parameters
Type | Name | Description |
---|---|---|
XPathNavigator | rootNav | The root xml navigation path. |
InstallerInfo | info |
Returns
Type | Description |
---|---|
XPathNavigator | A new converted |
DeleteTempFolder()
Deletes the package temporary folder.
Declaration
public void DeleteTempFolder()
Install()
The Install method installs the feature.
Declaration
public bool Install()
Returns
Type | Description |
---|---|
System.Boolean | A value indicating whether the install succeeded. |
ReadManifest(Boolean)
The ReadManifest method reads the manifest file and parses it into packages.
Declaration
public void ReadManifest(bool deleteTemp)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | deleteTemp | A value indicating whether to delete the temporary folder. |
UnInstall(Boolean)
The UnInstall method uninstalls the feature.
Declaration
public bool UnInstall(bool deleteFiles)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | deleteFiles | A flag that indicates whether the files should be deleted. |
Returns
Type | Description |
---|---|
System.Boolean | A value indicating whether the uninstall succeeded. |