DCMTK Version 3.7.1
OFFIS DICOM Toolkit
Loading...
Searching...
No Matches
DcmQueryRetrieveSCP Class Reference

main class for Query/Retrieve Service Class Provider More...

Public Member Functions

 DcmQueryRetrieveSCP (const DcmQueryRetrieveConfig &config, const DcmQueryRetrieveOptions &options, const DcmQueryRetrieveDatabaseHandleFactory &factory, const DcmAssociationConfiguration &associationConfiguration, DcmTLSOptions &tlsOptions)
 constructor
virtual ~DcmQueryRetrieveSCP ()
 destructor
OFCondition waitForAssociation (T_ASC_Network *theNet)
 wait for incoming A-ASSOCIATE requests, perform association negotiation and serve the requests.
void setDatabaseFlags (OFBool dbCheckFindIdentifier, OFBool dbCheckMoveIdentifier)
 set database flags
void cleanChildren ()
 clean up terminated child processes.

Static Public Member Functions

static OFBool isCommandAllowedForAbstractSyntax (T_DIMSE_Command command, const char *abstractSyntax)
 check whether a DIMSE command is permitted for the given abstract syntax.

Private Member Functions

 DcmQueryRetrieveSCP (const DcmQueryRetrieveSCP &other)
 private undefined copy constructor
DcmQueryRetrieveSCP & operator= (const DcmQueryRetrieveSCP &other)
 private undefined assignment operator
OFCondition negotiateAssociation (T_ASC_Association *assoc)
 perform association negotiation for an incoming A-ASSOCIATE request based on the SCP configuration and option flags.

Static Private Member Functions

static OFBool checkPresentationContextForCommand (T_ASC_Association *assoc, T_DIMSE_Command command, T_ASC_PresentationContextID presID)
 check whether the DIMSE command received on the given presentation context may be processed, i.e.

Private Attributes

const DcmQueryRetrieveConfig * config_
 configuration facility
DcmQueryRetrieveProcessTable processtable_
 child process table, only used in multi-processing mode
OFBool dbCheckFindIdentifier_
 flag for database interface: check C-FIND identifier
OFBool dbCheckMoveIdentifier_
 flag for database interface: check C-MOVE identifier
const DcmQueryRetrieveDatabaseHandleFactory & factory_
 factory object used to create database handles
const DcmQueryRetrieveOptions & options_
 SCP configuration options.
const DcmAssociationConfiguration & associationConfiguration_
 Association configuration profiles read from configuration file.
DcmTLSOptions & tlsOptions_
 reference to object managing the TLS options

Detailed Description

main class for Query/Retrieve Service Class Provider

Constructor & Destructor Documentation

◆ DcmQueryRetrieveSCP()

DcmQueryRetrieveSCP::DcmQueryRetrieveSCP ( const DcmQueryRetrieveConfig & config,
const DcmQueryRetrieveOptions & options,
const DcmQueryRetrieveDatabaseHandleFactory & factory,
const DcmAssociationConfiguration & associationConfiguration,
DcmTLSOptions & tlsOptions )

constructor

Parameters
configSCP configuration facility
optionsSCP configuration options
factoryfactory object used to create database handles
objectmanaging the TLS options for network connections

Referenced by DcmQueryRetrieveSCP(), and operator=().

Member Function Documentation

◆ checkPresentationContextForCommand()

OFBool DcmQueryRetrieveSCP::checkPresentationContextForCommand ( T_ASC_Association * assoc,
T_DIMSE_Command command,
T_ASC_PresentationContextID presID )
staticprivate

check whether the DIMSE command received on the given presentation context may be processed, i.e.

whether it matches the abstract syntax that was negotiated for that presentation context.

Parameters
assocassociation on which the message was received
commandDIMSE command field of the received message
presIDpresentation context ID on which the message was received
Returns
OFTrue if the command may be processed, OFFalse otherwise

◆ isCommandAllowedForAbstractSyntax()

OFBool DcmQueryRetrieveSCP::isCommandAllowedForAbstractSyntax ( T_DIMSE_Command command,
const char * abstractSyntax )
static

check whether a DIMSE command is permitted for the given abstract syntax.

DICOM PS3.7 requires that a DIMSE message is only sent on a presentation context whose abstract syntax supports the corresponding DIMSE service. The DIMSE layer itself does not enforce this, i.e. the Service Class Provider has to check the combination of command and abstract syntax before acting upon a message. Otherwise a peer could, for example, send a C-STORE request on a Verification presentation context and thus bypass the access control that is implemented by refusing storage presentation contexts during association negotiation.

Parameters
commandDIMSE command field of the received message
abstractSyntaxabstract syntax (SOP Class UID) that was negotiated for the presentation context on which the message was received. May be NULL, in which case OFFalse is returned.
Returns
OFTrue if the command may be processed on the given abstract syntax, OFFalse otherwise

◆ negotiateAssociation()

OFCondition DcmQueryRetrieveSCP::negotiateAssociation ( T_ASC_Association * assoc)
private

perform association negotiation for an incoming A-ASSOCIATE request based on the SCP configuration and option flags.

No A-ASSOCIATE response is generated, this is left to the caller.

Parameters
associncoming association
Returns
EC_Normal if successful, an error code otherwise

◆ setDatabaseFlags()

void DcmQueryRetrieveSCP::setDatabaseFlags ( OFBool dbCheckFindIdentifier,
OFBool dbCheckMoveIdentifier )

set database flags

Parameters
dbCheckFindIdentifierflag indicating that a check should be performed for C-FIND requests
dbCheckMoveIdentifierflag indicating that a check should be performed for C-MOVE requests

◆ waitForAssociation()

OFCondition DcmQueryRetrieveSCP::waitForAssociation ( T_ASC_Network * theNet)

wait for incoming A-ASSOCIATE requests, perform association negotiation and serve the requests.

May fork child processes depending on availability of the fork() system function and configuration options.

Parameters
theNetnetwork structure for listen socket
Returns
EC_Normal if successful, an error code otherwise

The documentation for this class was generated from the following file:


Generated on for DCMTK Version 3.7.1 by Doxygen 1.18.0