Class DefaultDicomServerFactory
- Namespace
- FellowOakDicom.Network
- Assembly
- fo-dicom.core.dll
public class DefaultDicomServerFactory : IDicomServerFactory
- Inheritance
-
DefaultDicomServerFactory
- Implements
- Inherited Members
- Extension Methods
Constructors
DefaultDicomServerFactory(IServiceScopeFactory, IDicomServerRegistry, IOptions<DicomServiceOptions>, IOptions<DicomServerOptions>)
public DefaultDicomServerFactory(IServiceScopeFactory serviceScopeFactory, IDicomServerRegistry dicomServerRegistry, IOptions<DicomServiceOptions> defaultServiceOptions, IOptions<DicomServerOptions> defaultServerOptions)
Parameters
serviceScopeFactory
IServiceScopeFactorydicomServerRegistry
IDicomServerRegistrydefaultServiceOptions
IOptions<DicomServiceOptions>defaultServerOptions
IOptions<DicomServerOptions>
Methods
Create<T>(int, ITlsAcceptor, Encoding, ILogger, object, Action<DicomServerOptions>)
Creates a DICOM server object.
public IDicomServer Create<T>(int port, ITlsAcceptor tlsAcceptor = null, Encoding fallbackEncoding = null, ILogger logger = null, object userState = null, Action<DicomServerOptions> configure = null) where T : DicomService, IDicomServiceProvider
Parameters
port
intPort to listen to.
tlsAcceptor
ITlsAcceptorHandler to accept authenticated connections.
fallbackEncoding
EncodingFallback encoding.
logger
ILoggerLogger, if null default logger will be applied.
userState
objectOptional parameters
configure
Action<DicomServerOptions>Configures the service options of the newly created DICOM server
Returns
- IDicomServer
An instance of DicomServer<T>, that starts listening for connections in the background.
Type Parameters
T
DICOM service that the server should manage.
Create<T>(string, int, ITlsAcceptor, Encoding, ILogger, object, Action<DicomServerOptions>)
Creates a DICOM server object.
public IDicomServer Create<T>(string ipAddress, int port, ITlsAcceptor tlsAcceptor = null, Encoding fallbackEncoding = null, ILogger logger = null, object userState = null, Action<DicomServerOptions> configure = null) where T : DicomService, IDicomServiceProvider
Parameters
ipAddress
stringIP address(es) to listen to. Value
applies default, IPv4Any.null
port
intPort to listen to.
tlsAcceptor
ITlsAcceptorHandler to accept authenticated connections.
fallbackEncoding
EncodingFallback encoding.
logger
ILoggerLogger, if null default logger will be applied.
userState
objectOptional parameters.
configure
Action<DicomServerOptions>Configures the service options of the newly created DICOM server
Returns
- IDicomServer
An instance of DicomServer<T>, that starts listening for connections in the background.
Type Parameters
T
DICOM service that the server should manage.
Create<TServiceProvider, TServer>(string, int, object, ITlsAcceptor, Encoding, ILogger, Action<DicomServerOptions>)
Creates a DICOM server object.
public virtual IDicomServer Create<TServiceProvider, TServer>(string ipAddress, int port, object userState = null, ITlsAcceptor tlsAcceptor = null, Encoding fallbackEncoding = null, ILogger logger = null, Action<DicomServerOptions> configure = null) where TServiceProvider : DicomService, IDicomServiceProvider where TServer : IDicomServer<TServiceProvider>
Parameters
ipAddress
stringIP address(es) to listen to. Value
applies default, IPv4Any.null
port
intPort to listen to.
userState
objectOptional parameters
tlsAcceptor
ITlsAcceptorHandler to accept authenticated connections.
fallbackEncoding
EncodingFallback encoding.
logger
ILoggerLogger, if null default logger will be applied.
configure
Action<DicomServerOptions>Configures the service options of the newly created DICOM server
Returns
- IDicomServer
An instance of
TServer
, that starts listening for connections in the background.
Type Parameters
TServiceProvider
TServer
Concrete DICOM server type to be returned.