PACS System 0.1.0
PACS DICOM system library
Loading...
Searching...
No Matches
kcenon::pacs::services::ups_watch_scp Class Referencefinal

UPS Watch SCP service for subscription and event notification. More...

#include <ups_watch_scp.h>

Inheritance diagram for kcenon::pacs::services::ups_watch_scp:
Inheritance graph
Collaboration diagram for kcenon::pacs::services::ups_watch_scp:
Collaboration graph

Public Member Functions

 ups_watch_scp (std::shared_ptr< di::ILogger > logger=nullptr)
 Construct UPS Watch SCP with optional logger.
 
 ~ups_watch_scp () override=default
 
void set_subscribe_handler (ups_subscribe_handler handler)
 
void set_unsubscribe_handler (ups_unsubscribe_handler handler)
 
void set_get_subscribers_handler (ups_get_subscribers_handler handler)
 
void set_event_callback (ups_event_callback callback)
 
std::vector< std::string > supported_sop_classes () const override
 Get the list of SOP Class UIDs supported by this service.
 
network::Result< std::monostate > handle_message (network::association &assoc, uint8_t context_id, const network::dimse::dimse_message &request) override
 Handle an incoming DIMSE message.
 
std::string_view service_name () const noexcept override
 Get the service name for logging/debugging.
 
void notify_state_change (const std::string &workitem_uid, const std::string &new_state)
 Notify subscribers of a workitem state change.
 
void notify_cancel_requested (const std::string &workitem_uid, const std::string &reason)
 Notify subscribers of a cancel request.
 
void notify_progress (const std::string &workitem_uid, int progress_percent)
 Notify subscribers of progress update.
 
size_t subscriptions_created () const noexcept
 
size_t subscriptions_removed () const noexcept
 
size_t events_sent () const noexcept
 
void reset_statistics () noexcept
 
- Public Member Functions inherited from kcenon::pacs::services::scp_service
 scp_service (std::shared_ptr< di::ILogger > logger=nullptr)
 Construct SCP service with optional logger.
 
virtual ~scp_service ()=default
 
 scp_service (const scp_service &)=delete
 
scp_serviceoperator= (const scp_service &)=delete
 
 scp_service (scp_service &&)=default
 
scp_serviceoperator= (scp_service &&)=default
 
void set_logger (std::shared_ptr< di::ILogger > logger)
 Set the logger instance.
 
const std::shared_ptr< di::ILogger > & logger () const noexcept
 Get the current logger instance.
 
bool supports_sop_class (std::string_view sop_class_uid) const
 Check if this service supports a specific SOP Class.
 

Private Member Functions

network::Result< std::monostate > handle_n_action (network::association &assoc, uint8_t context_id, const network::dimse::dimse_message &request)
 
network::Result< std::monostate > handle_subscribe (network::association &assoc, uint8_t context_id, uint16_t message_id, const std::string &sop_instance_uid)
 
network::Result< std::monostate > handle_unsubscribe (network::association &assoc, uint8_t context_id, uint16_t message_id, const std::string &sop_instance_uid)
 
network::Result< std::monostate > handle_suspend_global (network::association &assoc, uint8_t context_id, uint16_t message_id)
 
network::Result< std::monostate > send_n_action_response (network::association &assoc, uint8_t context_id, uint16_t message_id, const std::string &sop_instance_uid, uint16_t action_type_id, network::dimse::status_code status)
 
void dispatch_event (uint16_t event_type_id, const std::string &workitem_uid, const core::dicom_dataset &event_info)
 

Private Attributes

ups_subscribe_handler subscribe_handler_
 
ups_unsubscribe_handler unsubscribe_handler_
 
ups_get_subscribers_handler get_subscribers_handler_
 
ups_event_callback event_callback_
 
std::atomic< size_t > subscriptions_created_ {0}
 
std::atomic< size_t > subscriptions_removed_ {0}
 
std::atomic< size_t > events_sent_ {0}
 

Additional Inherited Members

- Protected Attributes inherited from kcenon::pacs::services::scp_service
std::shared_ptr< di::ILoggerlogger_
 Logger instance for service logging.
 

Detailed Description

UPS Watch SCP service for subscription and event notification.

The UPS Watch SCP handles subscribe/unsubscribe N-ACTION requests and provides event notification infrastructure. When workitem state changes occur (triggered externally, e.g., by UPS Push SCP), the Watch SCP notifies all relevant subscribers via the event callback.

UPS Watch Message Flow

Subscriber (SCU) UPS Watch SCP
| |
| N-ACTION-RQ (Subscribe, Type 3) |
| WorkitemUID: 1.2.3.4... |
|---------------------------------->|
| N-ACTION-RSP (Success) |
|<----------------------------------|
| |
| [Workitem state changes] |
| |
| N-EVENT-REPORT-RQ (Type 1) |
| State: COMPLETED |
|<----------------------------------|
| N-EVENT-REPORT-RSP |
|---------------------------------->|
| |
| N-ACTION-RQ (Unsubscribe, Type 4)|
|---------------------------------->|
| N-ACTION-RSP (Success) |
|<----------------------------------|

Definition at line 174 of file ups_watch_scp.h.

Constructor & Destructor Documentation

◆ ups_watch_scp()

kcenon::pacs::services::ups_watch_scp::ups_watch_scp ( std::shared_ptr< di::ILogger > logger = nullptr)
explicit

Construct UPS Watch SCP with optional logger.

Parameters
loggerLogger instance (nullptr uses null_logger)

Definition at line 21 of file ups_watch_scp.cpp.

22 : scp_service(std::move(logger)) {}
const std::shared_ptr< di::ILogger > & logger() const noexcept
Get the current logger instance.
Definition scp_service.h:93
scp_service(std::shared_ptr< di::ILogger > logger=nullptr)
Construct SCP service with optional logger.
Definition scp_service.h:64

◆ ~ups_watch_scp()

kcenon::pacs::services::ups_watch_scp::~ups_watch_scp ( )
overridedefault

Member Function Documentation

◆ dispatch_event()

void kcenon::pacs::services::ups_watch_scp::dispatch_event ( uint16_t event_type_id,
const std::string & workitem_uid,
const core::dicom_dataset & event_info )
private

Definition at line 361 of file ups_watch_scp.cpp.

364 {
365
367 return;
368 }
369
370 // Get subscribers for this workitem
371 auto subscribers_result = get_subscribers_handler_(workitem_uid);
372 if (subscribers_result.is_err()) {
373 logger_->warn("UPS Watch: Failed to get subscribers for " +
374 workitem_uid);
375 return;
376 }
377
378 const auto& subscribers = subscribers_result.value();
379
380 for (const auto& subscriber_ae : subscribers) {
381 event_callback_(subscriber_ae, event_type_id,
382 workitem_uid, event_info);
383 ++events_sent_;
384 }
385
386 if (!subscribers.empty()) {
387 logger_->info("UPS Watch: Dispatched event type " +
388 std::to_string(event_type_id) + " to " +
389 std::to_string(subscribers.size()) +
390 " subscribers for workitem " + workitem_uid);
391 }
392}
std::shared_ptr< di::ILogger > logger_
Logger instance for service logging.
ups_get_subscribers_handler get_subscribers_handler_

References event_callback_, events_sent_, get_subscribers_handler_, and kcenon::pacs::services::scp_service::logger_.

Referenced by notify_cancel_requested(), notify_progress(), and notify_state_change().

Here is the caller graph for this function:

◆ events_sent()

size_t kcenon::pacs::services::ups_watch_scp::events_sent ( ) const
nodiscardnoexcept

Definition at line 130 of file ups_watch_scp.cpp.

130 {
131 return events_sent_.load();
132}

References events_sent_.

◆ handle_message()

network::Result< std::monostate > kcenon::pacs::services::ups_watch_scp::handle_message ( network::association & assoc,
uint8_t context_id,
const network::dimse::dimse_message & request )
nodiscardoverridevirtual

Handle an incoming DIMSE message.

Processes the request and sends appropriate response(s) via the association.

Parameters
assocThe association on which the message was received
context_idThe presentation context ID for the message
requestThe incoming DIMSE request message
Returns
Success or error result

Implements kcenon::pacs::services::scp_service.

Definition at line 55 of file ups_watch_scp.cpp.

58 {
59
60 using namespace network::dimse;
61
62 if (request.command() != command_field::n_action_rq) {
65 "Expected N-ACTION-RQ but received " +
66 std::string(to_string(request.command())));
67 }
68
69 return handle_n_action(assoc, context_id, request);
70}
network::Result< std::monostate > handle_n_action(network::association &assoc, uint8_t context_id, const network::dimse::dimse_message &request)
constexpr int ups_unexpected_command
Definition result.h:210
auto to_string(mpps_status status) -> std::string_view
Convert mpps_status to DICOM string representation.
Definition mpps_scp.h:60
VoidResult pacs_void_error(int code, const std::string &message, const std::string &details="")
Create a PACS void error result.
Definition result.h:249

References kcenon::pacs::network::dimse::dimse_message::command(), handle_n_action(), kcenon::pacs::pacs_void_error(), kcenon::pacs::services::to_string(), and kcenon::pacs::error_codes::ups_unexpected_command.

Here is the call graph for this function:

◆ handle_n_action()

network::Result< std::monostate > kcenon::pacs::services::ups_watch_scp::handle_n_action ( network::association & assoc,
uint8_t context_id,
const network::dimse::dimse_message & request )
nodiscardprivate

Definition at line 144 of file ups_watch_scp.cpp.

147 {
148
149 using namespace network::dimse;
150
151 // Get Action Type ID
152 auto action_type = request.action_type_id();
153 if (!action_type.has_value()) {
156 "Missing Action Type ID in N-ACTION request");
157 }
158
159 // Get SOP Instance UID (workitem UID or global subscription UID)
160 auto sop_instance_uid = request.requested_sop_instance_uid();
161 if (sop_instance_uid.empty()) {
162 sop_instance_uid = request.affected_sop_instance_uid();
163 }
164
165 uint16_t action_id = action_type.value();
166 uint16_t message_id = request.message_id();
167
168 switch (action_id) {
170 return handle_subscribe(
171 assoc, context_id, message_id, sop_instance_uid);
172
174 return handle_unsubscribe(
175 assoc, context_id, message_id, sop_instance_uid);
176
179 assoc, context_id, message_id);
180
181 default:
183 assoc, context_id, message_id,
184 sop_instance_uid, action_id,
185 status_error_no_such_action_type);
186 }
187}
network::Result< std::monostate > handle_suspend_global(network::association &assoc, uint8_t context_id, uint16_t message_id)
network::Result< std::monostate > handle_subscribe(network::association &assoc, uint8_t context_id, uint16_t message_id, const std::string &sop_instance_uid)
network::Result< std::monostate > send_n_action_response(network::association &assoc, uint8_t context_id, uint16_t message_id, const std::string &sop_instance_uid, uint16_t action_type_id, network::dimse::status_code status)
network::Result< std::monostate > handle_unsubscribe(network::association &assoc, uint8_t context_id, uint16_t message_id, const std::string &sop_instance_uid)
constexpr dicom_tag message_id
Message ID.
constexpr dicom_tag sop_instance_uid
SOP Instance UID.
constexpr int ups_invalid_action_type
Definition result.h:214
constexpr uint16_t ups_watch_action_suspend_global
N-ACTION Type 5: Suspend Global Subscription (PS3.4 CC.2.3.5)
constexpr uint16_t ups_watch_action_unsubscribe
N-ACTION Type 4: Unsubscribe from Receiving UPS Event Reports (PS3.4 CC.2.3.4)
constexpr uint16_t ups_watch_action_subscribe
N-ACTION Type 3: Subscribe to Receive UPS Event Reports (PS3.4 CC.2.3.3)

References kcenon::pacs::network::dimse::dimse_message::action_type_id(), kcenon::pacs::network::dimse::dimse_message::affected_sop_instance_uid(), handle_subscribe(), handle_suspend_global(), handle_unsubscribe(), kcenon::pacs::network::dimse::dimse_message::message_id(), kcenon::pacs::pacs_void_error(), kcenon::pacs::network::dimse::dimse_message::requested_sop_instance_uid(), send_n_action_response(), kcenon::pacs::error_codes::ups_invalid_action_type, kcenon::pacs::services::ups_watch_action_subscribe, kcenon::pacs::services::ups_watch_action_suspend_global, and kcenon::pacs::services::ups_watch_action_unsubscribe.

Referenced by handle_message().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ handle_subscribe()

network::Result< std::monostate > kcenon::pacs::services::ups_watch_scp::handle_subscribe ( network::association & assoc,
uint8_t context_id,
uint16_t message_id,
const std::string & sop_instance_uid )
nodiscardprivate

Definition at line 193 of file ups_watch_scp.cpp.

197 {
198
199 using namespace network::dimse;
200
201 if (!subscribe_handler_) {
204 "No subscribe handler configured for UPS Watch SCP");
205 }
206
207 // Determine subscriber AE from the association
208 std::string subscriber_ae{assoc.calling_ae()};
209
210 // Determine if this is a global or workitem-specific subscription
211 std::string workitem_uid;
212 if (sop_instance_uid != ups_global_subscription_instance_uid) {
213 workitem_uid = sop_instance_uid;
214 }
215
216 // Deletion lock defaults to false (could be extracted from dataset)
217 bool deletion_lock = false;
218
219 logger_->debug("UPS Watch: Subscribe request from " + subscriber_ae +
220 (workitem_uid.empty() ? " (global)" :
221 " for workitem " + workitem_uid));
222
223 auto result = subscribe_handler_(subscriber_ae, workitem_uid, deletion_lock);
224 if (result.is_err()) {
226 assoc, context_id, message_id,
227 sop_instance_uid, ups_watch_action_subscribe,
228 status_error_unable_to_process);
229 }
230
232
233 logger_->info("UPS Watch: Subscription created for " + subscriber_ae);
234
236 assoc, context_id, message_id,
237 sop_instance_uid, ups_watch_action_subscribe,
238 status_success);
239}
std::atomic< size_t > subscriptions_created_
ups_subscribe_handler subscribe_handler_
constexpr int ups_handler_not_set
Definition result.h:209
constexpr std::string_view ups_global_subscription_instance_uid
UPS Global Subscription SOP Instance UID Used as the SOP Instance UID for global (non-workitem-specif...

References kcenon::pacs::network::association::calling_ae(), kcenon::pacs::services::scp_service::logger_, kcenon::pacs::pacs_void_error(), send_n_action_response(), subscribe_handler_, subscriptions_created_, kcenon::pacs::services::ups_global_subscription_instance_uid, kcenon::pacs::error_codes::ups_handler_not_set, and kcenon::pacs::services::ups_watch_action_subscribe.

Referenced by handle_n_action().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ handle_suspend_global()

network::Result< std::monostate > kcenon::pacs::services::ups_watch_scp::handle_suspend_global ( network::association & assoc,
uint8_t context_id,
uint16_t message_id )
nodiscardprivate

Definition at line 293 of file ups_watch_scp.cpp.

296 {
297
298 using namespace network::dimse;
299
303 "No unsubscribe handler configured for UPS Watch SCP");
304 }
305
306 std::string subscriber_ae{assoc.calling_ae()};
307
308 logger_->debug("UPS Watch: Suspend global subscription from " +
309 subscriber_ae);
310
311 // Suspend global = unsubscribe from global (empty workitem_uid)
312 auto result = unsubscribe_handler_(subscriber_ae, "");
313 if (result.is_err()) {
315 assoc, context_id, message_id,
318 status_error_unable_to_process);
319 }
320
322
323 logger_->info("UPS Watch: Global subscription suspended for " +
324 subscriber_ae);
325
327 assoc, context_id, message_id,
330 status_success);
331}
ups_unsubscribe_handler unsubscribe_handler_
std::atomic< size_t > subscriptions_removed_

References kcenon::pacs::network::association::calling_ae(), kcenon::pacs::services::scp_service::logger_, kcenon::pacs::pacs_void_error(), send_n_action_response(), subscriptions_removed_, unsubscribe_handler_, kcenon::pacs::services::ups_global_subscription_instance_uid, kcenon::pacs::error_codes::ups_handler_not_set, and kcenon::pacs::services::ups_watch_action_suspend_global.

Referenced by handle_n_action().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ handle_unsubscribe()

network::Result< std::monostate > kcenon::pacs::services::ups_watch_scp::handle_unsubscribe ( network::association & assoc,
uint8_t context_id,
uint16_t message_id,
const std::string & sop_instance_uid )
nodiscardprivate

Definition at line 245 of file ups_watch_scp.cpp.

249 {
250
251 using namespace network::dimse;
252
256 "No unsubscribe handler configured for UPS Watch SCP");
257 }
258
259 std::string subscriber_ae{assoc.calling_ae()};
260
261 // Determine if this is a global or workitem-specific unsubscription
262 std::string workitem_uid;
263 if (sop_instance_uid != ups_global_subscription_instance_uid) {
264 workitem_uid = sop_instance_uid;
265 }
266
267 logger_->debug("UPS Watch: Unsubscribe request from " + subscriber_ae +
268 (workitem_uid.empty() ? " (global)" :
269 " for workitem " + workitem_uid));
270
271 auto result = unsubscribe_handler_(subscriber_ae, workitem_uid);
272 if (result.is_err()) {
274 assoc, context_id, message_id,
275 sop_instance_uid, ups_watch_action_unsubscribe,
276 status_error_unable_to_process);
277 }
278
280
281 logger_->info("UPS Watch: Subscription removed for " + subscriber_ae);
282
284 assoc, context_id, message_id,
285 sop_instance_uid, ups_watch_action_unsubscribe,
286 status_success);
287}

References kcenon::pacs::network::association::calling_ae(), kcenon::pacs::services::scp_service::logger_, kcenon::pacs::pacs_void_error(), send_n_action_response(), subscriptions_removed_, unsubscribe_handler_, kcenon::pacs::services::ups_global_subscription_instance_uid, kcenon::pacs::error_codes::ups_handler_not_set, and kcenon::pacs::services::ups_watch_action_unsubscribe.

Referenced by handle_n_action().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ notify_cancel_requested()

void kcenon::pacs::services::ups_watch_scp::notify_cancel_requested ( const std::string & workitem_uid,
const std::string & reason )

Notify subscribers of a cancel request.

Parameters
workitem_uidThe workitem for which cancel was requested
reasonThe cancellation reason (may be empty)

Definition at line 92 of file ups_watch_scp.cpp.

94 {
95
96 core::dicom_dataset event_info;
97 if (!reason.empty()) {
98 event_info.set_string(
100 encoding::vr_type::LT, reason);
101 }
102
103 dispatch_event(ups_event_cancel_requested, workitem_uid, event_info);
104}
void dispatch_event(uint16_t event_type_id, const std::string &workitem_uid, const core::dicom_dataset &event_info)
@ LT
Long Text (10240 chars max)
constexpr core::dicom_tag reason_for_cancellation
Reason for Cancellation (0074,1238)
constexpr uint16_t ups_event_cancel_requested
Event Type 2: UPS Cancel Requested — performer should stop processing.

References dispatch_event(), kcenon::pacs::encoding::LT, kcenon::pacs::services::ups_tags::reason_for_cancellation, kcenon::pacs::core::dicom_dataset::set_string(), and kcenon::pacs::services::ups_event_cancel_requested.

Here is the call graph for this function:

◆ notify_progress()

void kcenon::pacs::services::ups_watch_scp::notify_progress ( const std::string & workitem_uid,
int progress_percent )

Notify subscribers of progress update.

Parameters
workitem_uidThe workitem that reported progress
progress_percentThe progress percentage (0-100)

Definition at line 106 of file ups_watch_scp.cpp.

108 {
109
110 core::dicom_dataset event_info;
111 event_info.set_string(
113 encoding::vr_type::DS, std::to_string(progress_percent));
114
115 dispatch_event(ups_event_progress_report, workitem_uid, event_info);
116}
@ DS
Decimal String (16 chars max)
constexpr core::dicom_tag procedure_step_progress
Procedure Step Progress (0074,1004)
constexpr uint16_t ups_event_progress_report
Event Type 3: UPS Progress Report — progress percentage update.

References dispatch_event(), kcenon::pacs::encoding::DS, kcenon::pacs::services::ups_tags::procedure_step_progress, kcenon::pacs::core::dicom_dataset::set_string(), and kcenon::pacs::services::ups_event_progress_report.

Here is the call graph for this function:

◆ notify_state_change()

void kcenon::pacs::services::ups_watch_scp::notify_state_change ( const std::string & workitem_uid,
const std::string & new_state )

Notify subscribers of a workitem state change.

Looks up subscribers for the given workitem and dispatches UPS State Report events via the event callback.

Parameters
workitem_uidThe workitem that changed state
new_stateThe new state string

Definition at line 80 of file ups_watch_scp.cpp.

82 {
83
84 core::dicom_dataset event_info;
85 event_info.set_string(
87 encoding::vr_type::CS, new_state);
88
89 dispatch_event(ups_event_state_report, workitem_uid, event_info);
90}
@ CS
Code String (16 chars max, uppercase + digits + space + underscore)
constexpr core::dicom_tag procedure_step_state
Procedure Step State (0074,1000)
constexpr uint16_t ups_event_state_report
Event Type 1: UPS State Report — workitem state changed.

References kcenon::pacs::encoding::CS, dispatch_event(), kcenon::pacs::services::ups_tags::procedure_step_state, kcenon::pacs::core::dicom_dataset::set_string(), and kcenon::pacs::services::ups_event_state_report.

Here is the call graph for this function:

◆ reset_statistics()

void kcenon::pacs::services::ups_watch_scp::reset_statistics ( )
noexcept

Definition at line 134 of file ups_watch_scp.cpp.

134 {
137 events_sent_ = 0;
138}

References events_sent_, subscriptions_created_, and subscriptions_removed_.

◆ send_n_action_response()

network::Result< std::monostate > kcenon::pacs::services::ups_watch_scp::send_n_action_response ( network::association & assoc,
uint8_t context_id,
uint16_t message_id,
const std::string & sop_instance_uid,
uint16_t action_type_id,
network::dimse::status_code status )
nodiscardprivate

Definition at line 337 of file ups_watch_scp.cpp.

343 {
344
345 using namespace network::dimse;
346
347 auto response = make_n_action_rsp(
348 message_id,
350 sop_instance_uid,
351 action_type_id,
352 status);
353
354 return assoc.send_dimse(context_id, response);
355}
constexpr std::string_view ups_watch_sop_class_uid
UPS Watch SOP Class UID (PS3.4 Table CC.2-1)

References kcenon::pacs::network::association::send_dimse(), and kcenon::pacs::services::ups_watch_sop_class_uid.

Referenced by handle_n_action(), handle_subscribe(), handle_suspend_global(), and handle_unsubscribe().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ service_name()

std::string_view kcenon::pacs::services::ups_watch_scp::service_name ( ) const
nodiscardoverridevirtualnoexcept

Get the service name for logging/debugging.

Returns
Human-readable service name

Implements kcenon::pacs::services::scp_service.

Definition at line 72 of file ups_watch_scp.cpp.

72 {
73 return "UPS Watch SCP";
74}

◆ set_event_callback()

void kcenon::pacs::services::ups_watch_scp::set_event_callback ( ups_event_callback callback)

Definition at line 41 of file ups_watch_scp.cpp.

41 {
42 event_callback_ = std::move(callback);
43}

References event_callback_.

◆ set_get_subscribers_handler()

void kcenon::pacs::services::ups_watch_scp::set_get_subscribers_handler ( ups_get_subscribers_handler handler)

Definition at line 36 of file ups_watch_scp.cpp.

37 {
38 get_subscribers_handler_ = std::move(handler);
39}

References get_subscribers_handler_.

◆ set_subscribe_handler()

void kcenon::pacs::services::ups_watch_scp::set_subscribe_handler ( ups_subscribe_handler handler)

Definition at line 28 of file ups_watch_scp.cpp.

28 {
29 subscribe_handler_ = std::move(handler);
30}

References subscribe_handler_.

◆ set_unsubscribe_handler()

void kcenon::pacs::services::ups_watch_scp::set_unsubscribe_handler ( ups_unsubscribe_handler handler)

Definition at line 32 of file ups_watch_scp.cpp.

32 {
33 unsubscribe_handler_ = std::move(handler);
34}

References unsubscribe_handler_.

◆ subscriptions_created()

size_t kcenon::pacs::services::ups_watch_scp::subscriptions_created ( ) const
nodiscardnoexcept

Definition at line 122 of file ups_watch_scp.cpp.

122 {
123 return subscriptions_created_.load();
124}

References subscriptions_created_.

◆ subscriptions_removed()

size_t kcenon::pacs::services::ups_watch_scp::subscriptions_removed ( ) const
nodiscardnoexcept

Definition at line 126 of file ups_watch_scp.cpp.

126 {
127 return subscriptions_removed_.load();
128}

References subscriptions_removed_.

◆ supported_sop_classes()

std::vector< std::string > kcenon::pacs::services::ups_watch_scp::supported_sop_classes ( ) const
nodiscardoverridevirtual

Get the list of SOP Class UIDs supported by this service.

Returns
Vector of SOP Class UIDs that this service can handle

Implements kcenon::pacs::services::scp_service.

Definition at line 49 of file ups_watch_scp.cpp.

49 {
50 return {
51 std::string(ups_watch_sop_class_uid)
52 };
53}

References kcenon::pacs::services::ups_watch_sop_class_uid.

Member Data Documentation

◆ event_callback_

ups_event_callback kcenon::pacs::services::ups_watch_scp::event_callback_
private

Definition at line 301 of file ups_watch_scp.h.

Referenced by dispatch_event(), and set_event_callback().

◆ events_sent_

std::atomic<size_t> kcenon::pacs::services::ups_watch_scp::events_sent_ {0}
private

Definition at line 305 of file ups_watch_scp.h.

305{0};

Referenced by dispatch_event(), events_sent(), and reset_statistics().

◆ get_subscribers_handler_

ups_get_subscribers_handler kcenon::pacs::services::ups_watch_scp::get_subscribers_handler_
private

Definition at line 300 of file ups_watch_scp.h.

Referenced by dispatch_event(), and set_get_subscribers_handler().

◆ subscribe_handler_

ups_subscribe_handler kcenon::pacs::services::ups_watch_scp::subscribe_handler_
private

Definition at line 298 of file ups_watch_scp.h.

Referenced by handle_subscribe(), and set_subscribe_handler().

◆ subscriptions_created_

std::atomic<size_t> kcenon::pacs::services::ups_watch_scp::subscriptions_created_ {0}
private

Definition at line 303 of file ups_watch_scp.h.

303{0};

Referenced by handle_subscribe(), reset_statistics(), and subscriptions_created().

◆ subscriptions_removed_

std::atomic<size_t> kcenon::pacs::services::ups_watch_scp::subscriptions_removed_ {0}
private

◆ unsubscribe_handler_

ups_unsubscribe_handler kcenon::pacs::services::ups_watch_scp::unsubscribe_handler_
private

The documentation for this class was generated from the following files: