Indexes DICOM images located in local directory into an Sql database.
More...
#include <Libs/DICOM/Core/ctkDICOMIndexer.h>
|
Q_INVOKABLE bool | addDicomdir (ctkDICOMDatabase &database, const QString &directoryName, const QString &destinationDirectoryName="") |
| Adds directory to database by using DICOMDIR and optionally copies files to destinationDirectory. Scan the directory using Dcmtk and populate the database with all the DICOM images accordingly. More...
|
|
Q_INVOKABLE void | addDirectory (ctkDICOMDatabase &database, const QString &directoryName, const QString &destinationDirectoryName="", bool includeHidden=true) |
| Adds directory to database and optionally copies files to destinationDirectory. More...
|
|
Q_INVOKABLE void | addFile (ctkDICOMDatabase &database, const QString filePath, const QString &destinationDirectoryName="") |
| Adds a file to database and optionally copies the file to destinationDirectory. More...
|
|
Q_INVOKABLE void | addListOfFiles (ctkDICOMDatabase &database, const QStringList &listOfFiles, const QString &destinationDirectoryName="") |
| Adds a QStringList containing the file path to database and optionally copies files to destinationDirectory. More...
|
|
| ctkDICOMIndexer (QObject *parent=0) |
|
Q_INVOKABLE void | endIndexing () |
|
Q_INVOKABLE void | refreshDatabase (ctkDICOMDatabase &database, const QString &directoryName) |
|
Q_INVOKABLE void | startIndexing (ctkDICOMDatabase &database) |
|
Q_INVOKABLE void | waitForImportFinished () |
| Deprecated - no op. More...
|
|
virtual | ~ctkDICOMIndexer () |
|
|
QScopedPointer< ctkDICOMIndexerPrivate > | d_ptr |
|
Indexes DICOM images located in local directory into an Sql database.
Definition at line 37 of file ctkDICOMIndexer.h.
◆ ctkDICOMIndexer()
ctkDICOMIndexer::ctkDICOMIndexer |
( |
QObject * |
parent = 0 | ) |
|
|
explicit |
◆ ~ctkDICOMIndexer()
virtual ctkDICOMIndexer::~ctkDICOMIndexer |
( |
| ) |
|
|
virtual |
◆ addDicomdir()
Q_INVOKABLE bool ctkDICOMIndexer::addDicomdir |
( |
ctkDICOMDatabase & |
database, |
|
|
const QString & |
directoryName, |
|
|
const QString & |
destinationDirectoryName = "" |
|
) |
| |
Adds directory to database by using DICOMDIR and optionally copies files to destinationDirectory. Scan the directory using Dcmtk and populate the database with all the DICOM images accordingly.
- Returns
- Returns false if there was an error while processing the DICOMDIR file.
◆ addDirectory()
Q_INVOKABLE void ctkDICOMIndexer::addDirectory |
( |
ctkDICOMDatabase & |
database, |
|
|
const QString & |
directoryName, |
|
|
const QString & |
destinationDirectoryName = "" , |
|
|
bool |
includeHidden = true |
|
) |
| |
Adds directory to database and optionally copies files to destinationDirectory.
Scan the directory using Dcmtk and populate the database with all the DICOM images accordingly.
If includeHidden is set to false then hidden files and folders are not added. DICOM folders may be created based on series or study name, which sometimes start with a . character, therefore it is advisable to include hidden files and folders.
◆ addFile()
Q_INVOKABLE void ctkDICOMIndexer::addFile |
( |
ctkDICOMDatabase & |
database, |
|
|
const QString |
filePath, |
|
|
const QString & |
destinationDirectoryName = "" |
|
) |
| |
Adds a file to database and optionally copies the file to destinationDirectory.
Scan the file using Dcmtk and populate the database with all the DICOM fields accordingly.
◆ addListOfFiles()
Q_INVOKABLE void ctkDICOMIndexer::addListOfFiles |
( |
ctkDICOMDatabase & |
database, |
|
|
const QStringList & |
listOfFiles, |
|
|
const QString & |
destinationDirectoryName = "" |
|
) |
| |
Adds a QStringList containing the file path to database and optionally copies files to destinationDirectory.
Scan the directory using Dcmtk and populate the database with all the DICOM images accordingly.
◆ cancel
void ctkDICOMIndexer::cancel |
( |
| ) |
|
|
slot |
◆ endIndexing()
Q_INVOKABLE void ctkDICOMIndexer::endIndexing |
( |
| ) |
|
Call this method after batch insertion is completed, and only if startIndexing() was called before batch insertion was started.
◆ foundFilesToIndex
void ctkDICOMIndexer::foundFilesToIndex |
( |
int |
| ) |
|
|
signal |
◆ indexingComplete
void ctkDICOMIndexer::indexingComplete |
( |
| ) |
|
|
signal |
◆ indexingFileNumber
void ctkDICOMIndexer::indexingFileNumber |
( |
int |
| ) |
|
|
signal |
◆ indexingFilePath
void ctkDICOMIndexer::indexingFilePath |
( |
QString |
| ) |
|
|
signal |
◆ progress
void ctkDICOMIndexer::progress |
( |
int |
| ) |
|
|
signal |
◆ refreshDatabase()
Q_INVOKABLE void ctkDICOMIndexer::refreshDatabase |
( |
ctkDICOMDatabase & |
database, |
|
|
const QString & |
directoryName |
|
) |
| |
◆ startIndexing()
Call this before performing multiple add...() calls in one batch to slightly increase indexing performance and to make only a single indexingComplete() signal emitted for multiple add...() operations.
If startIndexing() is called before a batch of insertions, then endIndexing() method must be called after the insertions are completed.
It is recommended to use ScopedIndexing helper class to call startIndexing and endIndexing automatically.
◆ waitForImportFinished()
Q_INVOKABLE void ctkDICOMIndexer::waitForImportFinished |
( |
| ) |
|
Deprecated - no op.
- Deprecated:
- Previously ensured that the QFuture threads have all finished indexing before returning control.
◆ d_ptr
QScopedPointer<ctkDICOMIndexerPrivate> ctkDICOMIndexer::d_ptr |
|
protected |
The documentation for this class was generated from the following file: