odil
SCP.h
1 /*************************************************************************
2  * odil - Copyright (C) Universite de Strasbourg
3  * Distributed under the terms of the CeCILL-B license, as published by
4  * the CEA-CNRS-INRIA. Refer to the LICENSE file or to
5  * http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
6  * for details.
7  ************************************************************************/
8 
9 #ifndef _f4680d8c_18a8_4317_956d_3ae238cb39cc
10 #define _f4680d8c_18a8_4317_956d_3ae238cb39cc
11 
12 #include "odil/Association.h"
13 #include "odil/DataSet.h"
14 #include "odil/message/Message.h"
15 #include "odil/message/Request.h"
16 
17 namespace odil
18 {
19 
21 class SCP
22 {
23 public:
26  {
27  public:
28  virtual ~DataSetGenerator() =0;
29 
30  virtual void initialize(message::Request const & request) =0;
31 
32  virtual bool done() const =0;
33  virtual void next() =0;
34 
35  virtual DataSet get() const =0;
36  };
37 
39  SCP(Association & association);
40 
42  virtual ~SCP();
43 
45  void receive_and_process();
46 
48  virtual void operator()(message::Message const & message) =0;
49 protected:
50  Association & _association;
51 };
52 
53 }
54 
55 #endif // _f4680d8c_18a8_4317_956d_3ae238cb39cc
virtual void operator()(message::Message const &message)=0
Process a message.
SCP(Association &association)
Create a Service Class Provider.
Definition: SCP.cpp:26
Definition: Association.cpp:39
Base class for all Service Class Providers.
Definition: SCP.h:21
Abstract base class for SCP returning multiple data sets.
Definition: SCP.h:25
void receive_and_process()
Receive and process a message.
Definition: SCP.cpp:40
DICOM Data set.
Definition: DataSet.h:66
Association.
Definition: Association.h:29
virtual ~SCP()
Destructor.
Definition: SCP.cpp:33