This commit is contained in:
2026-02-09 15:37:45 -06:00
parent e33a68ac51
commit 9635b84c3e
501 changed files with 106873 additions and 0 deletions

View File

@@ -0,0 +1,43 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Zebra.Sdk.Printer.Discovery;
namespace ScaBox30
{
//CLASE ZEBRA PARA LA BUSQUEDA DE IMPRESORAS EN LA RED
class NetworkDiscoveryHandler : DiscoveryHandler
{
private bool discoveryComplete = false;
public List<DiscoveredPrinter> printers = new List<DiscoveredPrinter>();
public void DiscoveryError(string message)
{
Console.WriteLine($"An error occurred during discovery: {message}.");
discoveryComplete = true;
}
public void DiscoveryFinished()
{
foreach (DiscoveredPrinter printer in printers)
{
Console.WriteLine(printer);
}
Console.WriteLine($"Discovered {printers.Count} Link-OS(TM) printers.");
discoveryComplete = true;
}
public void FoundPrinter(DiscoveredPrinter printer)
{
printers.Add(printer);
}
public bool DiscoveryComplete
{
get => discoveryComplete;
}
}
}