代码拉取完成,页面将自动刷新
unit Quick.Core.Extensions.Service.Abstractions;
interface
uses
System.SysUtils,
Quick.Core.Logging.Abstractions,
Quick.Core.Extensions.Hosting;
type
TSvcInitializeEvent = procedure of object;
TSvcAnonMethod = reference to procedure;
TSvcRemoveEvent = procedure of object;
IHostService = interface(IHost)
['{79251D22-01C3-44EF-8E8A-4C2CAC7DA510}']
procedure Start;
procedure Stop;
procedure Install;
procedure Remove;
function CheckParams : Boolean;
function IsRunningAsService : Boolean;
end;
THostService = class(TInterfacedObject,IHostService)
private
fLogger : ILogger;
fOnExecute: TSvcAnonMethod;
fWaitForKeyOnExit: Boolean;
fOnStop: TSvcAnonMethod;
fOnStart: TSvcAnonMethod;
fOnInitialize: TSvcInitializeEvent;
fServiceName: string;
fPassword: string;
fUser: string;
fDescription: string;
public
property ServiceName : string read fServiceName write fServiceName;
property User : string read fUser write fUser;
property Password : string read fPassword write fPassword;
property Description : string read fDescription write fDescription;
property OnInitialize : TSvcInitializeEvent read fOnInitialize write fOnInitialize;
property OnStart : TSvcAnonMethod read fOnStart write fOnStart;
property OnStop : TSvcAnonMethod read fOnStop write fOnStop;
property OnExecute : TSvcAnonMethod read fOnExecute write fOnExecute;
property WaitForKeyOnExit : Boolean read fWaitForKeyOnExit write fWaitForKeyOnExit;
property Logger : ILogger read fLogger write fLogger;
procedure Start; virtual; abstract;
procedure Stop; virtual; abstract;
procedure Install; virtual; abstract;
procedure Remove; virtual; abstract;
function CheckParams : Boolean; virtual; abstract;
function IsRunningAsService : Boolean; virtual; abstract;
end;
implementation
end.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。