Changed project names
This commit is contained in:
parent
b4c4aa4010
commit
a29e57e66d
130 changed files with 501 additions and 504 deletions
|
|
@ -0,0 +1,52 @@
|
|||
using System;
|
||||
using System.ServiceProcess;
|
||||
|
||||
using JetBrains.Annotations;
|
||||
|
||||
using AmagnoVirtualPrinter.Agent.Core;
|
||||
|
||||
namespace AmagnoVirtualPrinter.Agent.Service
|
||||
{
|
||||
public partial class AmagnoVirtualPrinterService : ServiceBase
|
||||
{
|
||||
public const string PrinterServiceName = "AmagnoPrinterService";
|
||||
public const string PrinterDescription = "Handles virtual printers";
|
||||
|
||||
[NotNull]
|
||||
private readonly IAmagnoVirtualPrinterService _amagnoPrinterService;
|
||||
|
||||
public AmagnoVirtualPrinterService([NotNull]IAmagnoVirtualPrinterService amagnoVirtualPrinterService)
|
||||
{
|
||||
if (amagnoVirtualPrinterService == null)
|
||||
{
|
||||
throw new ArgumentNullException(nameof(amagnoVirtualPrinterService));
|
||||
}
|
||||
|
||||
InitializeComponent();
|
||||
|
||||
_amagnoPrinterService = amagnoVirtualPrinterService;
|
||||
}
|
||||
|
||||
protected override void OnStart(string[] args)
|
||||
{
|
||||
OnServiceStart();
|
||||
}
|
||||
|
||||
public void OnServiceStart()
|
||||
{
|
||||
// Insert additional code here to define processing.
|
||||
_amagnoPrinterService.Start();
|
||||
}
|
||||
|
||||
protected override void OnStop()
|
||||
{
|
||||
OnServiceStop();
|
||||
}
|
||||
|
||||
public void OnServiceStop()
|
||||
{
|
||||
// Insert additional code here to define processing.
|
||||
_amagnoPrinterService.Stop();
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue