Esempio n. 1
0
 public OptionsParser(IIpAddressProcessor ipOptions, IOperatingSystemProcessor operatingSystemProcessor, IHostNameProcessor hostNameProcessor, IScript script)
 {
     _ipOptions = ipOptions;
     _operatingSystemProcessor = operatingSystemProcessor;
     _hostNameProcessor        = hostNameProcessor;
     _script = script;
 }
Esempio n. 2
0
 public AggregateReportEnricher(IIpAddressProcessor ipAddressProcessor, IMessagePublisher publisher, IAggregateReportRecordEnrichedFactory aggregateReportRecordEnrichedFactory, IEnricherConfig enricherConfig, IOrganisationalDomainProvider organisationalDomainProvider, ILogger <AggregateReportEnricher> log)
 {
     _ipAddressProcessor = ipAddressProcessor;
     _publisher          = publisher;
     _aggregateReportRecordEnrichedFactory = aggregateReportRecordEnrichedFactory;
     _enricherConfig = enricherConfig;
     _organisationalDomainProvider = organisationalDomainProvider;
     _log = log;
 }
Esempio n. 3
0
 public void GetIPEndpoint(IIpAddressProcessor ipAddressProcessor)
 {
     Get["/ip"] = parameters =>
     {
         var ipAddress      = ipAddressProcessor.GetIPAddress();
         var ipAdressOutput = new MachineInformationResults
         {
             output = ipAddress
         };
         return(Response.AsJson(ipAdressOutput));
     };
 }
Esempio n. 4
0
 public void GetIPEndpoint(IIpAddressProcessor ipAddressProcessor)
 {
     Get["/ip"] = parameters =>
     {
         try
         {
             var ipAddress      = ipAddressProcessor.GetIPAddress();
             var ipAdressOutput = new MachineInformationResults
             {
                 result = ipAddress
             };
             return(Response.AsJson(ipAdressOutput));
         }
         catch (Exception e)
         {
             return(HttpStatusCode.InternalServerError);
         }
     };
 }
Esempio n. 5
0
 public IpEndpoint(IIpAddressProcessor ipAddressProcessor)
 {
     GetIPEndpoint(ipAddressProcessor);
 }