From 366ba5483d4700ab5cd28f0013cba06cf37227bf Mon Sep 17 00:00:00 2001 From: midttuna <162321757+midttuna@users.noreply.github.com> Date: Mon, 21 Oct 2024 09:04:41 +0300 Subject: [PATCH] add manipulation GetMetricDeterminationMode (#95) // Added manipulation GetMetricDeterminationMode # Checklist The following aspects have been respected by the author of this pull request, confirmed by both pull request assignee **and** reviewer: * Changelog update (necessity checked and entry added or not added respectively) * [x] Pull Request Assignee * [x] Reviewer * README update (necessity checked and entry added or not added respectively) * [x] Pull Request Assignee * [x] Reviewer --- CHANGELOG.md | 1 + src/t2iapi/metric/metric_responses.proto | 11 ++++++++++- src/t2iapi/metric/service.proto | 6 ++++++ src/t2iapi/metric/types.proto | 8 ++++++++ 4 files changed, 25 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 58dd6da..57382e9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added +- manipulation GetMetricDeterminationMode for metrics - manipulation PhysicallyDisconnectRemovableSubsystemAfterPhysicalConnectorProvided - manipulation SetActiveModeOfOperation for metrics - manipulation PhysicallyDisconnectRemovableSubsystemAfterSettingActivationStateOnOrStndBy diff --git a/src/t2iapi/metric/metric_responses.proto b/src/t2iapi/metric/metric_responses.proto index ba6b32e..9cce366 100644 --- a/src/t2iapi/metric/metric_responses.proto +++ b/src/t2iapi/metric/metric_responses.proto @@ -10,6 +10,7 @@ syntax = "proto3"; package t2iapi.metric; import "t2iapi/basic_responses.proto"; +import "t2iapi/metric/types.proto"; option java_package = "com.draeger.medical.t2iapi.metric"; option java_outer_classname = "MetricResponses"; @@ -31,4 +32,12 @@ message CalibrateMetricResponse { message IsComputerControlledResponse { BasicResponse status = 1; // the status of the rpc indicating whether or not it was successful bool answer = 2; // true if metric is computer-controlled, otherwise false -} \ No newline at end of file +} + +/* +Response indicating whether a metric is determined episodically or periodically + */ +message GetMetricDeterminationMode { + BasicResponse status = 1; // the status of the rpc indicating whether or not it was successful + MetricDeterminationMode answer = 2; // 0 - Episodically, 1 - Periodically +} diff --git a/src/t2iapi/metric/service.proto b/src/t2iapi/metric/service.proto index 5943b1e..7575b2a 100644 --- a/src/t2iapi/metric/service.proto +++ b/src/t2iapi/metric/service.proto @@ -120,4 +120,10 @@ service MetricService { */ rpc SetActiveModeOfOperation (BasicHandleRequest) returns (BasicResponse); + + /* + Requests if the metric with the given handle is determined episodically or periodically. + */ + rpc GetMetricDeterminationMode (BasicHandleRequest) + returns (t2iapi.metric.GetMetricDeterminationMode); } diff --git a/src/t2iapi/metric/types.proto b/src/t2iapi/metric/types.proto index 493220f..832e549 100644 --- a/src/t2iapi/metric/types.proto +++ b/src/t2iapi/metric/types.proto @@ -69,3 +69,11 @@ enum MetricStatus { METRIC_STATUS_DE_INITIALIZED_AND_NOT_PERFORMING_OR_APPLYING = 4; METRIC_STATUS_FAILED = 5; } + +/* +Represents whether a METRIC is determined episodically or periodically. + */ +enum MetricDeterminationMode { + METRIC_DETERMINATION_MODE_EPISODICALLY = 0; + METRIC_DETERMINATION_MODE_PERIODICALLY = 1; +}