36
39
GinkgoNoServerFoundException() throw() : GNC::GCS::IException(_Std("Server not found"), "DICOM", false) {}
45
WLConfig( const WLConfig& o);
46
WLConfig& operator=(const WLConfig& o);
52
std::string abortTemplate;
53
bool useCompletedMessage;
54
std::string completedTemplate;
55
bool useInProgressMessage;
56
std::string inProgressTemplate;
39
59
class DicomServer {
42
inline DicomServer(const std::string& ID, const std::string& AET, const std::string& HostName, int port, int Lossy, bool isDefault, int PDU, bool useTLS, const std::string& pacsUser, const std::string& pacsPass, bool useMove, bool retrSeries, bool reuseConnection, bool verify, const std::string& cert, const std::string& key, const std::string& defaultCharset) {
45
this->HostName = HostName;
48
this->isDefault = isDefault;
51
this->reuseConnection = reuseConnection;
52
retrieveSeries = retrSeries;
53
retrieveWithMove = useMove;
54
this->useTLS = useTLS;
55
this->pacsUser = pacsUser;
56
this->pacsPass = pacsPass;
57
this->verifyCredentials = verify;
58
this->certificate = cert;
59
this->privateKey = key;
60
this->defaultCharset = defaultCharset;
63
inline DicomServer( const DicomServer& o) {
67
inline ~DicomServer() { }
69
DicomServer& operator=(const DicomServer& o)
73
this->HostName = o.HostName;
75
this->Lossy = o.Lossy;
76
this->isDefault = o.isDefault;
78
this->useTLS = o.useTLS;
79
this->pacsUser = o.pacsUser;
80
this->pacsPass = o.pacsPass;
81
this->retrieveWithMove = o.retrieveWithMove;
82
this->reuseConnection = o.reuseConnection;
83
this->retrieveSeries = o.retrieveSeries;
84
this->verifyCredentials = o.verifyCredentials;
85
this->certificate = o.certificate;
86
this->privateKey = o.privateKey;
87
this->defaultCharset = o.defaultCharset;
91
const std::string& GetID()
96
const std::string& GetAET()
101
const std::string& GetHostName()
131
const std::string& GetPACSUser()
136
const std::string& GetPACSPass()
141
bool GetRetrieveWithMove()
143
return retrieveWithMove;
146
bool GetRetrieveSeries()
148
return retrieveSeries;
151
bool GetRetrieveWithGet()
153
return !retrieveWithMove;
156
bool GetReuseConnection()
158
return reuseConnection;
161
bool GetverifyCredentials()
163
return verifyCredentials;
166
const std::string& GetCertificate()
171
const std::string& GetPrivateKey()
176
const std::string& GetDefaultCharset()
178
return defaultCharset;
61
typedef enum TRetrieveMethod {
66
/* Constructor with all parameters*/
67
DicomServer(const std::string& ID, const std::string& AET, const std::string& HostName, int port, int Lossy, bool isDefault, int PDU, bool useTLS, const std::string& pacsUser, const std::string& pacsPass, TRetrieveMethod retrieveMethod, const std::string& wadoURI, bool retrSeries, bool reuseConnection, bool verify, const std::string& cert, const std::string& key, const std::string& defaultCharset) ;
69
/**local server constructor*/
70
DicomServer(const std::string& ID, const std::string& AET, const std::string& HostName, int port, int PDU) ;
76
DicomServer( const DicomServer& o);
80
DicomServer& operator=(const DicomServer& o);
82
const std::string& GetID();
84
const std::string& GetAET();
86
const std::string& GetHostName();
98
const std::string& GetPACSUser();
100
const std::string& GetPACSPass();
102
TRetrieveMethod GetRetrieveMethod();
104
bool GetRetrieveSeries();
106
bool GetReuseConnection();
108
bool GetverifyCredentials();
110
const std::string& GetCertificate();
112
const std::string& GetPrivateKey();
114
const std::string& GetDefaultCharset();
116
const std::string& GetWADOURI() ;
118
WLConfig& GetWlConfig() ;
198
140
std::string defaultCharset;
201
class EXTAPI DicomServerHolder {
204
DicomServerHolder* next;
206
DicomServerHolder(const std::string& ID, const std::string& AET, const std::string& HostName, int Port, int Lossy, bool isDefault, int PDU, bool useTLS, const std::string& pacsUser, const std::string& pacsPass, bool useMove, bool retrSeries, bool reuseConnection, bool verify, const std::string& cert, const std::string& key, const std::string& defaultCharset) :
207
server(ID, AET, HostName, Port, Lossy, isDefault, PDU, useTLS, pacsUser, pacsPass, useMove, retrSeries, reuseConnection, verify, cert, key, defaultCharset) {
210
~DicomServerHolder() {}
213
class EXTAPI DicomServerList {
143
class EXTAPI DicomServerList: public GNC::GCS::ILockable {
145
typedef std::list<GNC::GCS::Ptr<DicomServer> > TServerList;
146
typedef std::map<std::string, GNC::GCS::Ptr<DicomServer> > TServerMap;
215
148
static DicomServerList* Instance();
216
149
static void FreeInstance();
218
151
void AddServer(const DicomServer& server, bool isDefault);
219
152
bool TieneServer(const std::string& ID);
220
DicomServer* GetLocalServer();
221
DicomServer* GetServer(const std::string& ID);
222
DicomServerHolder* GetList();
223
DicomServer* GetDefaultServer();
153
const GNC::GCS::Ptr<DicomServer>& GetLocalServer();
154
const GNC::GCS::Ptr<DicomServer>& GetServer(const std::string& ID);
155
const GNC::GCS::Ptr<DicomServer>& GetDefaultServer();
224
156
void SetDefaultServer(const std::string& ID);
225
DicomServer* GetFirst();
226
DicomServer* GetLast();
158
TServerList GetServerList();
230
162
DicomServerList();
231
163
~DicomServerList();
232
DicomServerHolder* serverHolders;
233
DicomServerHolder* lastInsertedHolder;
234
DicomServer* localServer;
164
TServerMap ServerMap;
165
GNC::GCS::Ptr<DicomServer> LocalServer;
237
168
static DicomServerList *m_pInstance;