using System;
|
using System.Collections.Generic;
|
using System.Linq;
|
using System.Text;
|
using System.Threading.Tasks;
|
using Topshelf;
|
using Yw.Server;
|
|
namespace IStation.TopShelf
|
{
|
/// <summary>
|
///
|
/// </summary>
|
public class Service : ServiceControl
|
{
|
private readonly SocketJobHelper _jobHelper = new SocketJobHelper();
|
|
/// <summary>
|
///
|
/// </summary>
|
public bool Start(HostControl hostControl)
|
{
|
_ = _jobHelper.StartJob();
|
return true;
|
}
|
|
/// <summary>
|
///
|
/// </summary>
|
public bool Stop(HostControl hostControl)
|
{
|
_ = _jobHelper.CancelJob();
|
return true;
|
}
|
|
|
}
|
}
|