ctkDICOMRetrieve.h 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. /*=========================================================================
  2. Library: CTK
  3. Copyright (c) Kitware Inc.
  4. Licensed under the Apache License, Version 2.0 (the "License");
  5. you may not use this file except in compliance with the License.
  6. You may obtain a copy of the License at
  7. http://www.commontk.org/LICENSE
  8. Unless required by applicable law or agreed to in writing, software
  9. distributed under the License is distributed on an "AS IS" BASIS,
  10. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  11. See the License for the specific language governing permissions and
  12. limitations under the License.
  13. =========================================================================*/
  14. #ifndef __ctkDICOMRetrieve_h
  15. #define __ctkDICOMRetrieve_h
  16. // Qt includes
  17. #include <QObject>
  18. #include <QDir>
  19. #include <QSharedPointer>
  20. #include "ctkDICOMCoreExport.h"
  21. // CTK Core includes
  22. #include "ctkDICOMDatabase.h"
  23. class ctkDICOMRetrievePrivate;
  24. class CTK_DICOM_CORE_EXPORT ctkDICOMRetrieve : public QObject
  25. {
  26. Q_OBJECT
  27. Q_PROPERTY(QString callingAETitle READ callingAETitle WRITE setCallingAETitle);
  28. Q_PROPERTY(QString calledAETitle READ calledAETitle WRITE setCallingAETitle);
  29. Q_PROPERTY(QString host READ host WRITE setHost);
  30. Q_PROPERTY(int callingPort READ callingPort WRITE setCallingPort);
  31. Q_PROPERTY(int calledPort READ calledPort WRITE setCalledPort);
  32. Q_PROPERTY(QString moveDestinationAETitle READ moveDestinationAETitle WRITE setMoveDestinationAETitle)
  33. public:
  34. explicit ctkDICOMRetrieve();
  35. virtual ~ctkDICOMRetrieve();
  36. /// Set methods for connectivity
  37. /// CTK_AE
  38. void setCallingAETitle( const QString& callingAETitle );
  39. QString callingAETitle() const;
  40. /// CTK_AE
  41. void setCalledAETitle( const QString& calledAETitle );
  42. QString calledAETitle() const;
  43. /// localhost
  44. void setHost( const QString& host );
  45. QString host() const;
  46. /// [0, 65365] 11113
  47. void setCallingPort( int port );
  48. int callingPort() const;
  49. /// [0, 65365] 11112
  50. void setCalledPort( int port );
  51. int calledPort() const;
  52. /// Typically CTK_CLIENT_AE
  53. void setMoveDestinationAETitle( const QString& moveDestinationAETitle );
  54. QString moveDestinationAETitle() const;
  55. /// method for database
  56. void setRetrieveDatabase(QSharedPointer<ctkDICOMDatabase> dicomDatabase);
  57. QSharedPointer<ctkDICOMDatabase> retrieveDatabase()const;
  58. // Could be a slot...
  59. bool retrieveSeries( const QString& seriesInstanceUID );
  60. bool retrieveStudy( const QString& studyInstanceUID );
  61. protected:
  62. QScopedPointer<ctkDICOMRetrievePrivate> d_ptr;
  63. private:
  64. void retrieve( QDir directory );
  65. Q_DECLARE_PRIVATE(ctkDICOMRetrieve);
  66. Q_DISABLE_COPY(ctkDICOMRetrieve);
  67. };
  68. #endif