Writes service application information to the registry. This method is meant to be used by installation tools, which call the appropriate methods automatically.
Assembly: System.ServiceProcess (in System.ServiceProcess.dll)
Normally, you do not call the methods on ServiceProcessInstaller within your code; they are generally called only by the install utility. The install utility automatically calls the method during the installation process. It backs out failures, if necessary, by calling Rollback on all previously installed components. This method passes the installation to the base class Installer.Install method.
Normally, you will not call the methods on ServiceInstaller within your code; they are generally called only by the install utility. The install utility automatically calls the and ServiceInstaller.Install methods during the installation process. It backs out failures, if necessary, by calling Rollback (or ServiceInstaller.Rollback) on all previously installed components
An application's install routine maintains information automatically about the components already installed, using the project installer's Installer.Context. This state information, passed into as the stateSaver parameter, is continuously updated as the ServiceProcessInstaller instance and each ServiceInstaller instance is installed by the utility. It is usually unnecessary for your code to modify this state information explicitly.