ifw-ccf  2.0.0
recWaitRequest.hpp
Go to the documentation of this file.
1 
5 #ifndef CCF_CONTROL_REC_WAIT_REQ_HPP_
6 #define CCF_CONTROL_REC_WAIT_REQ_HPP_
7 
8 #include <rad/mal/request.hpp>
9 
10 #include <Recif.hpp>
11 
12 #include <ccf/common/base.hpp>
13 
14 namespace ccf::control {
15 
20  public:
21 
23  RecWaitRequest(const std::string& rec_id,
24  rad::cii::Request<std::shared_ptr<recif::RecWaitStatus>,
25  std::shared_ptr<recif::RecWaitSpec>>* rec_req);
26 
27  virtual ~RecWaitRequest();
28 
30  rad::cii::Request<std::shared_ptr<recif::RecWaitStatus>, std::shared_ptr<recif::RecWaitSpec>>& GetReq();
31 
33  double GetReqTime() const;
34 
36  std::string GetRecId() const;
37 
39  void SetResponseSent();
40 
42  bool GetResponseSent() const;
43 
45  double GetResponseSentTime() const;
46 
47  private:
48  std::string m_rec_id;
49  double m_req_time;
50  rad::cii::Request<std::shared_ptr<recif::RecWaitStatus>, std::shared_ptr<recif::RecWaitSpec>>* m_rec_req;
51  bool m_response_sent;
52  double m_respone_time;
53  };
54 
55 } // namespace ccf::control
56 
57 #endif // CCF_CONTROL_REC_WAIT_REQ_HPP_
ccf::control::RecWaitRequest
Record Wait Request class, allocated when a client submits a RecWait Request.
Definition: recWaitRequest.hpp:19
ccf::control::RecWaitRequest::GetResponseSentTime
double GetResponseSentTime() const
Get the time for sending the response.
Definition: recWaitRequest.cpp:57
ccf::control::RecWaitRequest::GetReqTime
double GetReqTime() const
Get the time for when the RecWait Request was received. Used to handle the timeout specified for the ...
Definition: recWaitRequest.cpp:36
ccf::control::RecWaitRequest::GetResponseSent
bool GetResponseSent() const
Return true if a response to the associated RecWait Request has been sent.
Definition: recWaitRequest.cpp:52
ccf::control::RecWaitRequest::GetRecId
std::string GetRecId() const
Return the Recording ID of the associated Recording Session.
Definition: recWaitRequest.cpp:41
ccf::control::RecWaitRequest::~RecWaitRequest
virtual ~RecWaitRequest()
Definition: recWaitRequest.cpp:23
base.hpp
ccf::control::RecWaitRequest::SetResponseSent
void SetResponseSent()
Set flag indicating that a response to the associated RecWait Request has been sent.
Definition: recWaitRequest.cpp:46
ccf::control::RecWaitRequest::GetReq
rad::cii::Request< std::shared_ptr< recif::RecWaitStatus >, std::shared_ptr< recif::RecWaitSpec > > & GetReq()
Return reference to the RecWait Request handle used to send the response.
Definition: recWaitRequest.cpp:31
ccf::control::RecWaitRequest::RecWaitRequest
RecWaitRequest(const std::string &rec_id, rad::cii::Request< std::shared_ptr< recif::RecWaitStatus >, std::shared_ptr< recif::RecWaitSpec >> *rec_req)
Constructor registering the Record ID and reference to the RecWait Request handle to be able to send ...
Definition: recWaitRequest.cpp:11
ccf::control
Definition: acqThread.cpp:10