template class ugcs::vsm::Request_context¶
Overview¶
Request execution context. More…
#include <request_context.h> template <bool is_processor> class Request_context: public ugcs::vsm::Request_container { public: // typedefs typedef std::shared_ptr<Request_context> Ptr; typedef std::weak_ptr<Request_context> Weak_ptr; // methods template <typename... Args> static Ptr Create(Args&&... args); virtual Type Get_type() const; Request_container(const std::string& name, Request_waiter::Ptr waiter = Request_waiter::Create()); }; // direct descendants class Android_serial_processor; class Cucs_processor; class File_processor; class Request_temp_completion_context; class Request_worker; class Service_discovery_processor; class Socket_processor; class Timer_processor;
Inherited Members¶
public: // typedefs typedef std::shared_ptr<Request_container> Ptr; typedef std::weak_ptr<Request_container> Weak_ptr; // enums enum Type; // classes class Request; class Request_waiter; // methods template <typename... Args> static Ptr Create(Args&&... args); virtual Type Get_type() const; bool Check_type(Type mask); void Submit_request(Request::Ptr request); void Submit_request_locked(Request::Ptr request, Request_waiter::Locker locker); int Process_requests(int requests_limit = 0); int Process_requests(std::unique_lock<std::mutex>& lock, int requests_limit = 0); void Set_waiter(Request_waiter::Ptr waiter); Request_waiter::Ptr Get_waiter() const; const std::string& Get_name(); void Enable(); void Disable(); bool Is_enabled() const;
Detailed Documentation¶
Request execution context.
Parameters:
is_processor |
Request processor if “true”, request completion context otherwise. |
Typedefs¶
typedef std::shared_ptr<Request_context> Ptr
Pointer type.
typedef std::weak_ptr<Request_context> Weak_ptr
Pointer type.
Methods¶
template <typename... Args> static Ptr Create(Args&&... args)
Create an instance.
virtual Type Get_type() const
Get this container type.
Request_container(const std::string& name, Request_waiter::Ptr waiter = Request_waiter::Create())
Constructor.