GDCM  2.2.0
gdcmServiceClassUser.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: GDCM (Grassroots DICOM). A DICOM library
4 
5  Copyright (c) 2006-2011 Mathieu Malaterre
6  All rights reserved.
7  See Copyright.txt or http://gdcm.sourceforge.net/Copyright.html for details.
8 
9  This software is distributed WITHOUT ANY WARRANTY; without even
10  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11  PURPOSE. See the above copyright notice for more information.
12 
13 =========================================================================*/
14 #ifndef GDCMSERVICECLASSUSER_H
15 #define GDCMSERVICECLASSUSER_H
16 
17 #include "gdcmSubject.h"
18 
20 #include "gdcmFile.h"
21 
22 #include "gdcmNetworkStateID.h" // EStateID
23 
24 namespace gdcm
25 {
26 class ServiceClassUserInternals;
27 class BaseRootQuery;
28 namespace network{
29 class ULEvent;
30 class ULConnection;
31 class ULConnectionCallback;
32 }
37 {
38 public:
44 
46  void SetHostname( const char *hostname );
47 
49  void SetPort( uint16_t port );
50 
52  void SetPortSCP( uint16_t portscp );
53 
55  void SetAETitle(const char *aetitle);
56  const char *GetAETitle() const;
57 
59  void SetCalledAETitle(const char *aetitle);
60  const char *GetCalledAETitle() const;
61 
63  void SetTimeout(time_t t);
64  time_t GetTimeout() const;
65 
69  bool InitializeConnection();
70 
72  void SetPresentationContexts(std::vector<PresentationContext> const & pcs);
73 
75  bool StartAssociation();
76 
78  bool StopAssociation();
79 
81  bool SendEcho();
82 
84  bool SendStore(const char *filename);
87  bool SendStore(File const &file);
89  bool SendStore(DataSet const &ds);
90 
92  bool SendFind(const BaseRootQuery* query, std::vector<DataSet> &retDatasets);
93 
95  bool SendMove(const BaseRootQuery* query, const char *outputdir);
97  bool SendMove(const BaseRootQuery* query, std::vector<DataSet> &retDatasets);
99  bool SendMove(const BaseRootQuery* query, std::vector<File> &retFile);
100 
101 private:
102  network::EStateID RunEventLoop(network::ULEvent& inEvent,
103  network::ULConnection* inWhichConnection,
104  network::ULConnectionCallback* inCallback, const bool& startWaiting);
105  network::EStateID RunMoveEventLoop(network::ULEvent& inEvent,
106  network::ULConnectionCallback* inCallback);
107 
108 private:
110  void operator=(const ServiceClassUser &);
111 
112 private:
113  ServiceClassUserInternals *Internals;
114 };
115 
116 } // end namespace gdcm
117 
118 #endif // GDCMSERVICECLASSUSER_H

Generated on Wed Jun 13 2012 20:40:37 for GDCM by doxygen 1.8.1
SourceForge.net Logo