Class ScanServer
Allows scanning devices to be shared across the network. Clients can connect by using Driver.Escl when scanning.
public class ScanServer : IDisposable
- Inheritance
-
ScanServer
- Implements
- Inherited Members
Constructors
ScanServer(ScanningContext, IEsclServer)
public ScanServer(ScanningContext scanningContext, IEsclServer esclServer)
Parameters
scanningContext
ScanningContextesclServer
IEsclServer
Properties
Certificate
The certificate to be used for TLS connections to the server. If not specified, a self-signed certificate will be generated when the server starts (unless prevented by the security policy).
public X509Certificate2? Certificate { get; set; }
Property Value
InstanceId
A unique ID that is used to help derive the UUIDs for shared scanners. If you expect to have multiple shared scanners with the same name/model on the same network it may be useful to set this to a unique value.
public Guid InstanceId { get; set; }
Property Value
SecurityPolicy
The security policy to use for the ESCL server.
public EsclSecurityPolicy SecurityPolicy { get; set; }
Property Value
- EsclSecurityPolicy
Methods
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
public void Dispose()
RegisterDevice(ScanDevice, string?, int, int)
public void RegisterDevice(ScanDevice device, string? displayName = null, int port = 0, int tlsPort = 0)
Parameters
device
ScanDevicedisplayName
stringport
inttlsPort
int
SetDefaultIcon(IMemoryImage)
public void SetDefaultIcon(IMemoryImage icon)
Parameters
icon
IMemoryImage
SetDefaultIcon(byte[])
public void SetDefaultIcon(byte[] iconPng)
Parameters
iconPng
byte[]
Start()
public Task Start()
Returns
Stop()
public Task Stop()
Returns
UnregisterDevice(ScanDevice, string?)
public void UnregisterDevice(ScanDevice device, string? displayName = null)
Parameters
device
ScanDevicedisplayName
string